diff options
author | Mike Frysinger <vapier@gentoo.org> | 2006-12-11 00:52:12 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2006-12-11 00:52:12 +0000 |
commit | 257678943161eba72051cbbe6c3cbefd63924cd8 (patch) | |
tree | 44f90e850e302f3fa5e17f7fcdf17c986b4350b9 /extra/scripts/gen_bits_syscall_h.sh | |
parent | 08c9e9e978882a46433e8b07699e3a9d6254e821 (diff) |
kill off the need for fix_includes.sh by utilizing KERNEL_SOURCE directly
Diffstat (limited to 'extra/scripts/gen_bits_syscall_h.sh')
-rwxr-xr-x | extra/scripts/gen_bits_syscall_h.sh | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/extra/scripts/gen_bits_syscall_h.sh b/extra/scripts/gen_bits_syscall_h.sh index 6a791be34..0ba444007 100755 --- a/extra/scripts/gen_bits_syscall_h.sh +++ b/extra/scripts/gen_bits_syscall_h.sh @@ -14,16 +14,16 @@ # # Warning!!! This does _no_ error checking!!! -UNISTD_H_PATH=$top_builddir/include/asm/unistd.h -INCLUDE_OPTS="-I$top_builddir/include" +INCLUDE_OPTS="-nostdinc -I${KERNEL_SOURCE}" case $CC in *icc*) CC_SYSNUM_ARGS="-dM" ;; *) CC_SYSNUM_ARGS="-dN" ;; esac -( echo "#include \"$UNISTD_H_PATH\"" ; - $CC -E $CC_SYSNUM_ARGS $INCLUDE_OPTS $UNISTD_H_PATH | +( echo "#include <asm/unistd.h>"; + echo "#include <asm/unistd.h>" | + $CC -E $CC_SYSNUM_ARGS $INCLUDE_OPTS - | sed -ne 's/^[ ]*#define[ ]*__NR_\([A-Za-z0-9_]*\).*/UCLIBC_\1 __NR_\1/gp' \ -e 's/^[ ]*#undef[ ]*__NR_\([A-Za-z0-9_]*\).*/UNDEFUCLIBC_\1 __NR_\1/gp' # needed to strip out any kernel-internal defines ) | |