xref: /freebsd/lib/libc/tests/tls/Makefile (revision eacae6dc66aa881c102f11e2003174eea7e8af74)
12f121787SEnji Cooper# $FreeBSD$
22f121787SEnji Cooper
32f121787SEnji Cooper.include <bsd.own.mk>
42f121787SEnji Cooper
52f121787SEnji Cooper.if !defined(NO_PIC)
62f121787SEnji CooperSUBDIR+=	dso
72f121787SEnji Cooper.endif
82f121787SEnji Cooper
92f121787SEnji Cooper# TODO: doesn't link properly (for some odd reason it's trying to link in
102f121787SEnji Cooper#       libatf.so)
112f121787SEnji Cooper#NETBSD_ATF_TESTS_C=	tls_static_test
122f121787SEnji Cooper.if !defined(NO_PIC)
132f121787SEnji CooperNETBSD_ATF_TESTS_C+=	tls_dlopen_test
142f121787SEnji CooperNETBSD_ATF_TESTS_C+=	tls_dynamic_test
152f121787SEnji Cooper.endif
162f121787SEnji Cooper
172f121787SEnji Cooper.include "../Makefile.netbsd-tests"
182f121787SEnji Cooper
192f121787SEnji CooperDSODIR=		${.OBJDIR}/../tls_dso
202f121787SEnji Cooper
21*eacae6dcSBryan DreweryLIBADD.tls_static_test+=	pthread
222f121787SEnji CooperLDFLAGS.tls_static_test+=	-static
232f121787SEnji CooperSRCS.tls_static_test=		t_tls_static.c t_tls_static_helper.c
242f121787SEnji Cooper
25*eacae6dcSBryan DreweryDPADD.tls_dynamic_test+=	${DSODIR}/libh_tls_dynamic.so
26*eacae6dcSBryan DreweryLDADD.tls_dynamic_test+=	-lh_tls_dynamic
272f121787SEnji CooperLDFLAGS.tls_dynamic_test+=	-Wl,-rpath,${TESTSDIR} -L${DSODIR}
28*eacae6dcSBryan DreweryLIBADD.tls_dynamic_test+=	pthread
292f121787SEnji Cooper
30*eacae6dcSBryan DreweryLIBADD.tls_dlopen_test+=	pthread
312f121787SEnji CooperLDFLAGS.tls_dlopen_test+=	-Wl,-rpath,${TESTSDIR} -Wl,-export-dynamic
322f121787SEnji Cooper
332f121787SEnji Cooper.include <bsd.test.mk>
34