150476Speter# $FreeBSD$
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.
10169524Sdeischen
11169648Sdeischen.include <bsd.own.mk>
12169648Sdeischen
13174092SbrooksSHLIB=kse
14195767SkensmithSHLIB_MAJOR= 4
15113658SdeischenCFLAGS+=-DPTHREAD_KERNEL
16103388SminiCFLAGS+=-I${.CURDIR}/../libc/include -I${.CURDIR}/thread \
1794797Sobrien	-I${.CURDIR}/../../include
18209118SimpCFLAGS+=-I${.CURDIR}/arch/${MACHINE_CPUARCH}/include
19113658SdeischenCFLAGS+=-I${.CURDIR}/sys
20115399SkanCFLAGS+=-I${.CURDIR}/../../libexec/rtld-elf
21209118SimpCFLAGS+=-I${.CURDIR}/../../libexec/rtld-elf/${MACHINE_CPUARCH}
22115399SkanCFLAGS+=-fno-builtin
2336831Sjb
24172491Sobrien# Uncomment this if you want libkse to contain debug information for
2536831Sjb# thread locking.
26113786SdeischenCFLAGS+=-D_LOCK_DEBUG
27174112SdeischenWARNS?=3
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
33156774Sdeischen# Enable extra internal consistancy checks.
34156774SdeischenCFLAGS+=-D_PTHREADS_INVARIANTS -Wall
35115399Skan
36176055SdesVERSION_DEF=${.CURDIR}/../libc/Versions.def
37176056SdesSYMBOL_MAPS=${.CURDIR}/kse.map
38156774Sdeischen
39136910SruPRECIOUSLIB=
4013546Sjulian
41234412Spluknet.PATH: ${.CURDIR}/arch/${MACHINE_CPUARCH}/${MACHINE_CPUARCH}
42209118Simp
43209118Simp.include "${.CURDIR}/arch/${MACHINE_CPUARCH}/Makefile.inc"
44116705Smarcel.include "${.CURDIR}/support/Makefile.inc"
45116705Smarcel.include "${.CURDIR}/sys/Makefile.inc"
46103388Smini.include "${.CURDIR}/thread/Makefile.inc"
4713546Sjulian
4813546Sjulian.include <bsd.lib.mk>
49