2 sysdep_routines
+= errno-loc
5 ifeq ($(subdir
),assert
)
6 CFLAGS-assert.c
+= -DFATAL_PREPARE_INCLUDE
='<fatal-prepare.h>'
7 CFLAGS-assert-perr.c
+= -DFATAL_PREPARE_INCLUDE
='<fatal-prepare.h>'
10 ifeq ($(subdir
),malloc
)
11 CFLAGS-malloc.c
+= -DMORECORE_CLEARS
=2
15 sysdep_routines
+= sysctl clone llseek umount umount2 readahead \
16 setfsuid setfsgid makedev
18 CFLAGS-gethostid.c
= -fexceptions
20 sysdep_headers
+= sys
/mount.h sys
/acct.h sys
/sysctl.h \
21 sys
/klog.h sys
/kdaemon.h \
22 sys
/user.h sys
/procfs.h sys
/prctl.h \
23 sys
/kd.h sys
/soundcard.h sys
/vt.h \
24 sys
/quota.h sys
/fsuid.h \
25 scsi
/sg.h scsi
/scsi.h scsi
/scsi_ioctl.h sys
/pci.h \
26 sys
/ultrasound.h sys
/raw.h sys
/personality.h sys
/epoll.h \
29 install-others
+= $(inst_includedir
)/bits
/syscall.h
31 # Generate the list of SYS_* macros for the system calls (__NR_* macros).
32 # For bi-arch platforms, the CPU/Makefile defines {32,64}bit-predefine and
33 # we generate a file that uses <bits/wordsize.h>.
34 $(objpfx
)syscall-
%.h
$(objpfx
)syscall-
%.d
: ..
/sysdeps
/unix
/sysv
/linux
/sys
/syscall.h
35 $(make-target-directory
)
37 echo
'/* Generated at libc build time from kernel syscall list. */';\
39 echo
'#ifndef _SYSCALL_H'; \
40 echo
'# error "Never use <bits/syscall.h> directly; include <sys/syscall.h> instead."'; \
43 $(CC
) -E
-MD
-MP
-MF
$(@
:.h
=.d
)-t1
-MT
'$(@:.d=.h) $(@:.h=.d)' \
44 -x c
$(sysincludes
) $< $(addprefix -U
,$(64bit-predefine
)) \
45 $(addprefix -D
,$(32bit-predefine
)) -D_LIBC
-dM | \
46 sed
-n
's@^#define __NR_\([^ ]*\) .*$$@#define SYS_\1 __NR_\1@p' | \
47 LC_ALL
=C
sort > $(@
:.d
=.h
).new32
; \
48 $(CC
) -E
-MD
-MP
-MF
$(@
:.h
=.d
)-t2
-MT
'$(@:.d=.h) $(@:.h=.d)' \
49 -x c
$(sysincludes
) $< $(addprefix -U
,$(32bit-predefine
)) \
50 $(addprefix -D
,$(64bit-predefine
)) -D_LIBC
-dM | \
51 sed
-n
's@^#define __NR_\([^ ]*\) .*$$@#define SYS_\1 __NR_\1@p' | \
52 LC_ALL
=C
sort > $(@
:.d
=.h
).new64
; \
53 if cmp
-s
$(@
:.d
=.h
).new32
$(@
:.d
=.h
).new64
; then \
54 cat
$(@
:.d
=.h
).new32
; \
56 echo
'#include <bits/wordsize.h>'; \
58 LC_ALL
=C comm
-12 $(@
:.d
=.h
).new32
$(@
:.d
=.h
).new64
; \
59 echo
'#if __WORDSIZE == 64'; \
60 LC_ALL
=C comm
-13 $(@
:.d
=.h
).new32
$(@
:.d
=.h
).new64
; \
62 LC_ALL
=C comm
-23 $(@
:.d
=.h
).new32
$(@
:.d
=.h
).new64
; \
65 rm -f
$(@
:.d
=.h
).new32
$(@
:.d
=.h
).new64
; \
67 mv
-f
$(@
:.d
=.h
).new
$(@
:.d
=.h
)
69 sed
$(sed-remove-objpfx
) $(@
:.h
=.d
)-t1
$(@
:.h
=.d
)-t2
> $(@
:.h
=.d
)-t3
71 cat
$(@
:.h
=.d
)-t1
$(@
:.h
=.d
)-t2
> $(@
:.h
=.d
)-t3
73 rm -f
$(@
:.h
=.d
)-t1
$(@
:.h
=.d
)-t2
74 mv
-f
$(@
:.h
=.d
)-t3
$(@
:.h
=.d
)
76 $(inst_includedir
)/bits
/syscall.h
: $(objpfx
)syscall-list.h
$(+force)
77 $(make-target-directory
)
78 if
test -r
$@
&& cmp
-s
$< $@
; \
79 then echo
'bits/syscall.h unchanged'; \
80 else $(INSTALL_DATA
) $< $@
; fi
83 # Get the generated list of dependencies (probably /usr/include/asm/unistd.h).
84 -include $(objpfx
)syscall-list.d
86 generated
+= syscall-list.h syscall-list.d
90 sysdep_headers
+= sys
/timex.h
92 sysdep_routines
+= ntp_gettime
95 ifeq ($(subdir
),socket
)
96 sysdep_headers
+= net
/if_ppp.h net
/ppp-comp.h \
97 net
/ppp_defs.h net
/if_arp.h net
/route.h net
/ethernet.h \
98 net
/if_slip.h net
/if_packet.h net
/if_shaper.h
99 sysdep_routines
+= cmsg_nxthdr sa_len
102 ifeq ($(subdir
),sunrpc
)
103 sysdep_headers
+= nfs
/nfs.h
106 ifeq ($(subdir
),termios
)
107 sysdep_headers
+= termio.h
110 ifeq ($(subdir
),stdio-common
)
111 # Just disable the auto generation in sysdeps/generic
112 inhibit-siglist
:= yes
115 ifeq ($(subdir
),posix
)
116 sysdep_headers
+= bits
/initspin.h
118 sysdep_routines
+= exit-thread
121 ifeq ($(subdir
),inet
)
122 sysdep_headers
+= netinet
/if_fddi.h netinet
/if_tr.h \
123 netipx
/ipx.h netash
/ash.h netax25
/ax25.h netatalk
/at.h \
124 netrom
/netrom.h netpacket
/packet.h netrose
/rose.h \
128 # Don't compile the ctype glue code, since there is no old non-GNU C library.
131 ifeq ($(subdir
),dirent
)
132 sysdep_routines
+= getdirentries getdirentries64
136 CFLAGS-ypclnt.c
= -DUSE_BINDINGDIR
=1
140 sysdep_routines
+= xstatconv internal_statvfs internal_statvfs64
144 sysdep-rtld-routines
+= dl-brk dl-sbrk
146 CPPFLAGS-lddlibc4
+= -DNOT_IN_libc
150 CFLAGS-mq_send.c
+= -fexceptions
151 CFLAGS-mq_receive.c
+= -fexceptions
154 ifeq ($(subdir
),nscd
)
155 CFLAGS-connections.c
+= -DHAVE_EPOLL
156 CFLAGS-gai.c
+= -DNEED_NETLINK