Makefile revision 125230
150476Speter# $FreeBSD: head/lib/libkse/Makefile 125230 2004-01-30 12:13:17Z deischen $
213546Sjulian#
394797Sobrien# All library objects contain FreeBSD revision strings by default; they may be
413546Sjulian# excluded as a space-saving measure.  To produce a library that does
594797Sobrien# not contain these strings, add -DSTRIP_FBSDID (see <sys/cdefs.h>) to CFLAGS
694797Sobrien# below.  Note, there are no IDs for syscall stubs whose sources are generated.
794797Sobrien# To included legacy CSRG sccsid strings, add -DLIBC_SCCS and -DSYSLIBC_SCCS
894797Sobrien# (for system call stubs) to CFLAGS below.  -DSYSLIBC_SCCS affects just the
994797Sobrien# system call stubs.
10125230Sdeischen.if ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH} == "sparc64"
11113996SdeischenLIB=kse
12125230Sdeischen.else
13125230SdeischenLIB=pthread
14125230Sdeischen.endif
15107687SdeischenSHLIB_MAJOR= 1
16113658SdeischenCFLAGS+=-DPTHREAD_KERNEL
17103388SminiCFLAGS+=-I${.CURDIR}/../libc/include -I${.CURDIR}/thread \
1894797Sobrien	-I${.CURDIR}/../../include
19113658SdeischenCFLAGS+=-I${.CURDIR}/arch/${MACHINE_ARCH}/include
20113658SdeischenCFLAGS+=-I${.CURDIR}/sys
21115399SkanCFLAGS+=-I${.CURDIR}/../../libexec/rtld-elf
22115399SkanCFLAGS+=-fno-builtin
2336831Sjb
24103412Smini# Uncomment this if you want libpthread to contain debug information for
2536831Sjb# thread locking.
26113786SdeischenCFLAGS+=-D_LOCK_DEBUG
27113786Sdeischen#CFLAGS+= -g
2836831Sjb
29117706Sdavidxu# Uncomment this if you want to build a 1:1 threading mode library
30117706Sdavidxu# however it is no longer strictly conformed to POSIX
31117706Sdavidxu# CFLAGS+=-DSYSTEM_SCOPE_ONLY
32117706Sdavidxu
33117125SruLDFLAGS= -Wl,--version-script=${.CURDIR}/pthread.map
34115399Skan
3553812Salfred# enable extra internal consistancy checks
36113658SdeischenCFLAGS+=-D_PTHREADS_INVARIANTS -Wall
3753812Salfred
3813546SjulianPRECIOUSLIB=	yes
3913546Sjulian
40116705Smarcel.include "${.CURDIR}/arch/${MACHINE_ARCH}/Makefile.inc"
41116705Smarcel.include "${.CURDIR}/support/Makefile.inc"
42116705Smarcel.include "${.CURDIR}/sys/Makefile.inc"
43103388Smini.include "${.CURDIR}/thread/Makefile.inc"
4413546Sjulian
45120533Smarcel.if !defined(NOLIBC_R)
46120533Smarcel.if ${MACHINE_ARCH} == "ia64"
47120533SmarcelSYMLINKS+=lib${LIB}.a ${LIBDIR}/libc_r.a
48120533Smarcel.if !defined(NOPIC)
49120533SmarcelSYMLINKS+=lib${LIB}.so ${SHLIBDIR}/libc_r.so
50120533Smarcel.endif
51120533Smarcel.if !defined(NOPROFILE)
52120533SmarcelSYMLINKS+=lib${LIB}_p.a ${LIBDIR}/libc_r_p.a
53120533Smarcel.endif
54120533Smarcel.endif
55120533Smarcel.endif
56120533Smarcel
5713546Sjulian.include <bsd.lib.mk>
58