diff options
| author | Daniel Glöckner <daniel-gl@gmx.net> | 2008-09-05 21:08:22 +0200 |
|---|---|---|
| committer | grischka <grischka> | 2008-09-12 22:22:58 +0200 |
| commit | 256f6e6200be1a73cbf663938213778624436cad (patch) | |
| tree | 4a17d991045978d8f6f92f5cb1b09082206c6235 /configure | |
| parent | e8039673ad530fb5c268cf560ba0d2df95ec2fca (diff) | |
| download | tinycc-256f6e6200be1a73cbf663938213778624436cad.tar.gz tinycc-256f6e6200be1a73cbf663938213778624436cad.tar.bz2 | |
A prefix for default library/include search paths
This patch is useful for cross compilers. Without this patch tcc
tries to use the host's libraries, crt*.o and include files.
The patch prepends a string to all default paths. The string can
be passed to configure with --sysroot=string.
Daniel
Diffstat (limited to 'configure')
| -rwxr-xr-x | configure | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -26,6 +26,7 @@ libdir="" tccdir="" includedir="" mandir="" +sysroot="" cross_prefix="" cc="gcc" host_cc="gcc" @@ -102,6 +103,8 @@ for opt do ;; --mandir=*) mandir=`echo $opt | cut -d '=' -f 2` ;; + --sysroot=*) sysroot=`echo $opt | cut -d '=' -f 2` + ;; --source-path=*) source_path=`echo $opt | cut -d '=' -f 2` ;; --cross-prefix=*) cross_prefix=`echo $opt | cut -d '=' -f 2` @@ -218,6 +221,7 @@ echo "" echo "Advanced options (experts only):" echo " --source-path=PATH path of source code [$source_path]" echo " --cross-prefix=PREFIX use PREFIX for compile tools [$cross_prefix]" +echo " --sysroot=PREFIX prepend PREFIX to library/include paths []" echo " --cc=CC use C compiler CC [$cc]" echo " --make=MAKE use specified make [$make]" echo "" @@ -267,6 +271,7 @@ echo "Library directory $libdir" echo "Include directory $includedir" echo "Manual directory $mandir" echo "Doc directory $docdir" +echo "Target root prefix $sysroot" echo "Source path $source_path" echo "C compiler $cc" echo "make $make" @@ -287,6 +292,7 @@ echo "libdir=$libdir" >> config.mak echo "includedir=$includedir" >> config.mak echo "mandir=$mandir" >> config.mak echo "docdir=$docdir" >> config.mak +echo "#define CONFIG_SYSROOT \"$sysroot\"" >> $TMPH echo "#define CONFIG_TCCDIR \"$tccdir\"" >> $TMPH echo "MAKE=$make" >> config.mak echo "CC=$cc" >> config.mak |
