]> Git Repo - uclibc-ng.git/commitdiff
buildsys: allow the toolchain to search its dirs for kernel headers
authorMike Frysinger <[email protected]>
Sat, 26 Jan 2013 18:44:47 +0000 (13:44 -0500)
committerMike Frysinger <[email protected]>
Sat, 26 Jan 2013 18:46:55 +0000 (13:46 -0500)
Setting KERNEL_HEADERS up to the exact path all the time is a pita,
especially when the toolchain is often times already configured to
do the right thing.  So if the user has set that to "", don't force
any specific paths.

Signed-off-by: Mike Frysinger <[email protected]>
extra/Configs/Config.in.arch
extra/scripts/gen_bits_syscall_h.sh

index e97786b810eb93e4407faf1c01370ba06e51df9a..6d93433dc3139b3ecc706e795ba31c846e7bdc51 100644 (file)
@@ -192,7 +192,7 @@ config UCLIBC_HAS_LONG_DOUBLE_MATH
 
 config KERNEL_HEADERS
        string "Linux kernel header location"
-       default "/usr/include"
+       default ""
        help
          The kernel source you use to compile with should be the same
          as the Linux kernel you run your apps on.  uClibc doesn't even
@@ -203,6 +203,8 @@ config KERNEL_HEADERS
          but then run on Linux 2.0.x, lchown will be compiled into uClibc,
          but won't work at all.  You have been warned.
 
+         If you don't set this, we'll assume the toolchain can find them.
+
 config UCLIBC_UCLINUX_BROKEN_MUNMAP
        bool
        depends on !ARCH_USE_MMU
index f6353baa2f61fab8f7147de139ef68ed4a346446..4d42f69491b9a9a2feb7ee4283407dec6f157d93 100755 (executable)
 #
 # Warning!!! This does _no_ error checking!!!
 
-INCLUDE_OPTS="-nostdinc -I${KERNEL_HEADERS}"
+if [ "${KERNEL_HEADERS:-/}" != "/" ] ; then
+  INCLUDE_OPTS="-nostdinc -I${KERNEL_HEADERS}"
+else
+  # Let the toolchain use its configure paths.
+  INCLUDE_OPTS=
+fi
 
 case $CC in
 *icc*) CC_SYSNUM_ARGS="-dM" ;;
This page took 0.029149 seconds and 4 git commands to generate.