diff options
| author | Thomas Preud'homme <thomas.preudhomme@celest.fr> | 2011-07-05 10:47:32 +0200 |
|---|---|---|
| committer | Thomas Preud'homme <thomas.preudhomme@celest.fr> | 2011-07-05 23:49:53 +0200 |
| commit | 38de06e334f26f744cccccea3a06c0c743edfaa0 (patch) | |
| tree | 8b2390d8db632fe018028751856963f2ffa33a6e | |
| parent | 31ca000d72bc48060f205d94bfffc25ffe5fd18d (diff) | |
| download | tinycc-38de06e334f26f744cccccea3a06c0c743edfaa0.tar.gz tinycc-38de06e334f26f744cccccea3a06c0c743edfaa0.tar.bz2 | |
Fix commit 31ca000d
* CONFIG_TCC_*LDDIR should not be exported if no --*lddir option is used.
* Don't write a : at the beginning of extralddir
| -rwxr-xr-x | configure | 10 |
1 files changed, 7 insertions, 3 deletions
@@ -112,7 +112,7 @@ for opt do ;; --lddir=*) lddir=`echo $opt | cut -d '=' -f 2` ;; - --extralddir=*) extralddir="$extralddir:`echo $opt | cut -d '=' -f 2`" + --extralddir=*) extralddir="${extralddir:+:}`echo $opt | cut -d '=' -f 2`" ;; --includedir=*) includedir=`echo $opt | cut -d '=' -f 2` ;; @@ -366,9 +366,13 @@ echo "docdir=\$(DESTDIR)$docdir" >> config.mak echo "#define CONFIG_SYSROOT \"$sysroot\"" >> $TMPH echo "#ifndef CONFIG_TCCDIR" >> $TMPH echo "#define CONFIG_TCCDIR \"$tccdir\"" >> $TMPH -echo "#define CONFIG_TCC_LDDIR \"$lddir\"" >> $TMPH -echo "#define CONFIG_TCC_EXTRA_LDDIR \"$extralddir\"" >> $TMPH echo "#endif" >> $TMPH +if test -n "$lddir" ; then + echo "#define CONFIG_TCC_LDDIR \"$lddir\"" >> $TMPH +fi +if test -n "$extralddir" ; then + echo "#define CONFIG_TCC_EXTRA_LDDIR \"$extralddir\"" >> $TMPH +fi echo "CC=$cc" >> config.mak echo "GCC_MAJOR=$gcc_major" >> config.mak echo "#define GCC_MAJOR $gcc_major" >> $TMPH |
