[Ipopt-tickets] [Ipopt] #76: Ipopt fails unit test when versions of gcc and gfortran don't match
Ipopt
coin-trac at coin-or.org
Fri May 16 17:11:16 EDT 2008
#76: Ipopt fails unit test when versions of gcc and gfortran don't match
------------------------------+---------------------------------------------
Reporter: tkr | Owner: ipopt-team
Type: defect | Status: new
Priority: normal | Component: Ipopt
Version: 3.3 (C++ Version) | Severity: normal
Keywords: |
------------------------------+---------------------------------------------
I built Ipopt on a Linux box where the version of gfortran and gcc did not
match:
shark: ~> gfortran --version
GNU Fortran (Debian 4.3-20080202-1) 4.3.0 20080202 (experimental) [trunk
revision 132072]
shark: ~> gcc --version
gcc (GCC) 4.2.3 (Debian 4.2.3-1)
You would think this could not happen when using package management under
Linux, but in fact, the dependencies are such that it can happen even if
you are using something like apt to do automatic updates. In this case,
the Ipopt unit test will fail because when trying to link C++ code to
Fortran code, configure adds "-lstdc++" to the link line, but the version
of the stdc++ library associated with gfortran is not present in this
case, so you end up with the error
cd test; make test
make[1]: Entering directory `/home/ted/CoinAll-1.1/build/Ipopt/test'
/bin/sh ../../libtool --tag=F77 --mode=link gfortran -I`echo
../../../Ipopt/test/../src/Interfaces` -O3 -fomit-frame-pointer -pipe -o
hs071_f hs071_f.o ../src/Interfaces/libipopt.la -lblas -lm -ldl -lstdc++
-lm -ldl
gfortran -I../../../Ipopt/test/../src/Interfaces -O3 -fomit-frame-pointer
-pipe -o .libs/hs071_f hs071_f.o ../src/Interfaces/.libs/libipopt.so
-lblas -lstdc++ -lm -ldl -Wl,--rpath -Wl,/home/ted/CoinAll-1.1/build/lib
/usr/bin/ld: cannot find -lstdc++
collect2: ld returned 1 exit status
make[1]: *** [hs071_f] Error 1
make[1]: Leaving directory `/home/ted/CoinAll-1.1/build/Ipopt/test'
make: *** [unitTest] Error 2
--
Ticket URL: <https://projects.coin-or.org/Ipopt/ticket/76>
Ipopt <http://projects.coin-or.org/Ipopt>
Interior-point optimizer for nonlinear programs.
More information about the Ipopt-tickets
mailing list