This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: [PATCH, committed] Update Automake files


Hello Jan-Benedict,

> Hi!
> 
> This patch updates the files taken from Automake.  Committed.
> 
> MfG, JBG


the updated version of "missing" will confuse the gmp-4.3.2 configure
script if it is installed in-tree with "contrib/download_prerequisites"
and flex is not installed:

...
checking readline detected... no
checking for bison... (cached) /home/ed/gnu/gcc-5-20141116/missing bison -y
checking for flex... (cached) /home/ed/gnu/gcc-5-20141116/missing flex
checking lex output file root... configure: error: cannot find output from /home/ed/gnu/gcc-5-20141116/missing flex; giving up
make[3]: *** [config.status] Error 1
make[3]: Leaving directory `/home/ed/gnu/gcc-build-arm-linux-gnueabihf/gmp'
make[2]: *** [all-stage1-gmp] Error 2
make[2]: Leaving directory `/home/ed/gnu/gcc-build-arm-linux-gnueabihf'
make[1]: *** [stage1-bubble] Error 2
make[1]: Leaving directory `/home/ed/gnu/gcc-build-arm-linux-gnueabihf'
make: *** [all] Error 2

previous version of missing flex produced a dummy lex.yy.c,
as does the version in the gmp package, but unfortunately it is
overwritten by the "missing" script in the gcc tree.

That's probably just not a supported configuration anymore,
but all previous GCC releases worked without a installed flex tool.

Maybe the problem goes away if a newer version of gmp is used,
or if the "missing flex" is not passed down to the gmp configure script,
somehow.  Actually, it is not really needed by gmp at all.
I tried to add this hunk from the old version and it made, the gmp configure
script worked again:

--- missing.orig	2014-11-16 14:07:13.000000000 +0000
+++ missing	2014-11-19 15:01:57.168967538 +0000
@@ -172,6 +172,21 @@
       echo "You should only need it if you modified a '.l' file."
       echo "You may want to install the Fast Lexical Analyzer package:"
       echo "<$flex_URL>"
+      rm -f lex.yy.c
+      if test $# -ne 1; then
+        eval LASTARG="\${$#}"
+        case $LASTARG in
+        *.l)
+          SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'`
+          if test -f "$SRCFILE"; then
+              cp "$SRCFILE" lex.yy.c
+          fi
+        ;;
+        esac
+      fi
+      if test ! -f lex.yy.c; then
+          echo 'main() { return 0; }'>lex.yy.c
+      fi
       ;;
     help2man*)
       echo "You should only need it if you modified a dependency" \



What do you think?


Regards,
Bernd.
 		 	   		  

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]