Le mardi 11 octobre 2005 à 11:50 +0200, Jean Bréfort a écrit : > Le mardi 11 octobre 2005 à 11:44 +0300, Tommi Hassinen a écrit : > > I have made the RC2 for download here: > > > > http://www.uku.fi/~thassine/tmp/mopac7-1.10rc2.tgz > > It compiles fine with gcc-3.4.4 at least :-) It did not configure on a machine with gcc-4.0.1 and libf2c but without libg2c. The reason is that libf2c needs the MAIN__ symbol and this is not provided by the current AC_CHECK_LIB test. It works if the test is: saved_flags=$CFLAGS CFLAGS="-Dmain=MAIN__" # Here is a check whether we have libf2c or libg2c (Jean Brefort). # If libf2c is present, it is used and both the library and the executable is built. # If only libg2c is present, then only the library is built and the executable is not built. have_f2c="no" AC_CHECK_LIB([f2c], [main], [have_f2c="yes"; CFLAGS=$saved_flags], [# If not found, try -lg2c: CFLAGS=$saved_flags; AC_CHECK_LIB([g2c], [main], , # Still not found, drop out: AC_MSG_ERROR([Cannot find either f2c or g2c library])] ) ) I have tested this solution with gcc-4.0.1 and f2c and with gcc-3.4.4 and either f2c or g2c. It works in all cases. Cheers, Jean