code-saturne / code_saturne

code_saturne public mirror
https://www.code-saturne.org
GNU General Public License v2.0
223 stars 82 forks source link

tests: linker error in libple.so / undefined reference to `libintl_dgettext' #24

Closed thierry-FreeBSD closed 5 years ago

thierry-FreeBSD commented 5 years ago

Trying to run `make check' fails with the following error:

cc -DHAVE_CONFIG_H -I. -I..  -I../src -DMPICH_SKIP_MPICXX -I/usr/local/include -I/usr/local/include/libxml2 -DLIBICONV_PLUG -DNDEBUG  -std=c99 -funsigned-char -Wall -Wshadow -Wpointer-arith -Wmissing-prototypes -Wuninitialized -Wunused -O2 -pipe  -DLIBICONV_PLUG -fstack-protector -fno-strict-aliasing  -MT ple_coupling_test-ple_coupling_test.o -MD -MP -MF .deps/ple_coupling_test-ple_coupling_test.Tpo -c -o ple_coupling_test-ple_coupling_test.o `test -f 'ple_coupling_test.c' || echo './'`ple_coupling_test.c
mv -f .deps/ple_coupling_test-ple_coupling_test.Tpo .deps/ple_coupling_test-ple_coupling_test.Po
/bin/sh ../libtool  --tag=CC   --mode=link cc  -std=c99 -funsigned-char -Wall -Wshadow -Wpointer-arith -Wmissing-prototypes -Wuninitialized -Wunused -O2 -pipe  -DLIBICONV_PLUG -fstack-protector -fno-strict-aliasing   -Wl,-rpath=/usr/local/lib/gcc7  -L/usr/local/lib/gcc7 -B/usr/local/bin -fstack-protector  -O -o ple_coupling_test ple_coupling_test-ple_coupling_test.o ../src/libple.la -lmpich -lopa -lmpl -lrt  -lm -lm
libtool: link: cc -std=c99 -funsigned-char -Wall -Wshadow -Wpointer-arith -Wmissing-prototypes -Wuninitialized -Wunused -O2 -pipe -DLIBICONV_PLUG -fstack-protector -fno-strict-aliasing -Wl,-rpath=/usr/local/lib/gcc7 -B/usr/local/bin -fstack-protector -O -o .libs/ple_coupling_test ple_coupling_test-ple_coupling_test.o  -L/usr/local/lib/gcc7 ../src/.libs/libple.so -lmpich -lopa -lmpl -lrt -lm -Wl,-rpath -Wl,/usr/local/lib
../src/.libs/libple.so: undefined reference to `libintl_dgettext'
cc: error: linker command failed with exit code 1 (use -v to see invocation)
gmake[5]: *** [Makefile:423: ple_coupling_test] Error 1

The attached patch fixes the issue. patch-libple_tests_Makefile.am.txt