diff options
author | Roland McGrath <roland@gnu.org> | 2003-05-28 21:05:12 +0000 |
---|---|---|
committer | Roland McGrath <roland@gnu.org> | 2003-05-28 21:05:12 +0000 |
commit | 7cd72ad38093e584cb143ac6e4b1453dee5f7ac7 (patch) | |
tree | da182882630e13b7f8c1e9b05fcd3cb1fe68bf48 /sysdeps/unix/sysv/linux/Makefile | |
parent | d49c05e00f2b50f7a3e81f13803bdb34bd1970f7 (diff) | |
download | glibc-7cd72ad38093e584cb143ac6e4b1453dee5f7ac7.tar.gz glibc-7cd72ad38093e584cb143ac6e4b1453dee5f7ac7.tar.xz glibc-7cd72ad38093e584cb143ac6e4b1453dee5f7ac7.zip |
2003-05-11 Andreas Schwab <schwab@suse.de>
* Makerules: Always use -MP together with -MD. (sed-remove-dotot): Substitute $(..) also at start of line. ($(stdio_lim:h=st)): Use -MD instead of SUNPRO_DEPENDENCIES. Generated defines with a single compiler call. Use $(sed-remove-dotdot). * mach/Makefile ($(objpfx)mach-syscalls.mk): Use -MD instead of DEPENDENCIES_OUTPUT, and use $(sed-remove-objpfx). * sysdeps/unix/sysv/linux/Makefile ($(objpfx)syscall-%.h): Use -MD instead of SUNPRO_DEPENDENCIES, and use $(sed-remove-objpfx). * sysdeps/unix/sysv/linux/mips/Makefile ($(objpfx)syscall-%.h): Likewise.
Diffstat (limited to 'sysdeps/unix/sysv/linux/Makefile')
-rw-r--r-- | sysdeps/unix/sysv/linux/Makefile | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/sysdeps/unix/sysv/linux/Makefile b/sysdeps/unix/sysv/linux/Makefile index d402dd16da..90671e404e 100644 --- a/sysdeps/unix/sysv/linux/Makefile +++ b/sysdeps/unix/sysv/linux/Makefile @@ -30,7 +30,6 @@ install-others += $(inst_includedir)/bits/syscall.h # we generate a file that uses <bits/wordsize.h>. $(objpfx)syscall-%.h $(objpfx)syscall-%.d: ../sysdeps/unix/sysv/linux/sys/syscall.h $(make-target-directory) - rm -f $(@:.h=.d)-t { \ echo '/* Generated at libc build time from kernel syscall list. */';\ echo ''; \ @@ -38,14 +37,14 @@ $(objpfx)syscall-%.h $(objpfx)syscall-%.d: ../sysdeps/unix/sysv/linux/sys/syscal echo '# error "Never use <bits/syscall.h> directly; include <sys/syscall.h> instead."'; \ echo '#endif'; \ echo ''; \ - SUNPRO_DEPENDENCIES='$(@:.h=.d)-t $@' \ - $(CC) -E -x c $(sysincludes) $< $(addprefix -U,$(64bit-predefine)) \ - $(addprefix -D,$(32bit-predefine)) -D_LIBC -dM | \ + $(CC) -E -MD -MP -MF $(@:.h=.d)-t1 -MT '$(@:.d=.h) $(@:.h=.d)' \ + -x c $(sysincludes) $< $(addprefix -U,$(64bit-predefine)) \ + $(addprefix -D,$(32bit-predefine)) -D_LIBC -dM | \ sed -n 's@^#define __NR_\([^ ]*\) .*$$@#define SYS_\1 __NR_\1@p' | \ LC_ALL=C sort > $(@:.d=.h).new32; \ - SUNPRO_DEPENDENCIES='$(@:.h=.d)-t $@' \ - $(CC) -E -x c $(sysincludes) $< $(addprefix -U,$(32bit-predefine)) \ - $(addprefix -D,$(64bit-predefine)) -D_LIBC -dM | \ + $(CC) -E -MD -MP -MF $(@:.h=.d)-t2 -MT '$(@:.d=.h) $(@:.h=.d)' \ + -x c $(sysincludes) $< $(addprefix -U,$(32bit-predefine)) \ + $(addprefix -D,$(64bit-predefine)) -D_LIBC -dM | \ sed -n 's@^#define __NR_\([^ ]*\) .*$$@#define SYS_\1 __NR_\1@p' | \ LC_ALL=C sort > $(@:.d=.h).new64; \ if cmp -s $(@:.d=.h).new32 $(@:.d=.h).new64; then \ @@ -63,12 +62,13 @@ $(objpfx)syscall-%.h $(objpfx)syscall-%.d: ../sysdeps/unix/sysv/linux/sys/syscal rm -f $(@:.d=.h).new32 $(@:.d=.h).new64; \ } > $(@:.d=.h).new mv -f $(@:.d=.h).new $(@:.d=.h) - sed < $(@:.h=.d)-t > $(@:.h=.d)-t2 \ - -e 's,$(subst .,\.,$@),$(patsubst $(objpfx)%,$$(objpfx)%,\ - $(@:.d=.h) $(@:.h=.d)),' - rm -f $(@:.h=.d)-t - mv -f $(@:.h=.d)-t2 $(@:.h=.d) - +ifneq (,$(objpfx)) + sed $(sed-remove-objpfx) $(@:.h=.d)-t1 $(@:.h=.d)-t2 > $(@:.h=.d)-t3 +else + cat $(@:.h=.d)-t1 $(@:.h=.d)-t2 > $(@:.h=.d)-t3 +endif + rm -f $(@:.h=.d)-t1 $(@:.h=.d)-t2 + mv -f $(@:.h=.d)-t3 $(@:.h=.d) $(inst_includedir)/bits/syscall.h: $(objpfx)syscall-list.h $(+force) $(make-target-directory) |