* test case build errors
@ 2019-01-01 21:13 Tom G. Christensen
2019-01-04 19:32 ` Bruno Haible
0 siblings, 1 reply; 3+ messages in thread
From: Tom G. Christensen @ 2019-01-01 21:13 UTC (permalink / raw)
To: bug-gnulib
Hello,
A number of test cases currently fail to build on platforms that depend
on libintl for gettext functions.
From Solaris 9/x86:
gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
test-array_map test-array_map.o ../gllib/libgnu.a -lm -lm -lm
-lm -lm -lm
Undefined first referenced
symbol in file
libintl_gettext ../gllib/libgnu.a(xalloc-die.o)
ld: fatal: Symbol referencing errors. No output written to test-array_map
collect2: error: ld returned 1 exit status
make[4]: *** [test-array_map] Error 1
gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
test-array_set test-array_set.o ../gllib/libgnu.a -lm -lm -lm
-lm -lm -lm
Undefined first referenced
symbol in file
libintl_gettext ../gllib/libgnu.a(xalloc-die.o)
ld: fatal: Symbol referencing errors. No output written to test-array_set
collect2: error: ld returned 1 exit status
make[4]: *** [test-array_set] Error 1
gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
test-bitset test-bitset.o ../gllib/libgnu.a -lm -lm -lm -lm -
lm -lm
Undefined first referenced
symbol in file
libintl_gettext ../gllib/libgnu.a(stats.o)
ld: fatal: Symbol referencing errors. No output written to test-bitset
collect2: error: ld returned 1 exit status
make[4]: *** [test-bitset] Error 1
gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
test-hash_map test-hash_map.o ../gllib/libgnu.a -lm -lm -lm -l
m -lm -lm
Undefined first referenced
symbol in file
libintl_gettext ../gllib/libgnu.a(xalloc-die.o)
ld: fatal: Symbol referencing errors. No output written to test-hash_map
collect2: error: ld returned 1 exit status
make[4]: *** [test-hash_map] Error 1
gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
test-hash_set test-hash_set.o ../gllib/libgnu.a -lm -lm -lm -lm
-lm -lm
Undefined first referenced
symbol in file
libintl_gettext ../gllib/libgnu.a(xalloc-die.o)
ld: fatal: Symbol referencing errors. No output written to test-hash_set
collect2: error: ld returned 1 exit status
make[4]: *** [test-hash_set] Error 1
gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
test-linkedhash_map test-linkedhash_map.o ../gllib/libgnu.a -lm -lm
-lm -lm -lm -lm
Undefined first referenced
symbol in file
libintl_gettext ../gllib/libgnu.a(xalloc-die.o)
ld: fatal: Symbol referencing errors. No output written to
test-linkedhash_map
collect2: error: ld returned 1 exit status
make[4]: *** [test-linkedhash_map] Error 1
gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
test-linkedhash_set test-linkedhash_set.o ../gllib/libgnu.a -lm -lm
-lm -lm -lm -lm
Undefined first referenced
symbol in file
libintl_gettext ../gllib/libgnu.a(xalloc-die.o)
ld: fatal: Symbol referencing errors. No output written to
test-linkedhash_set
collect2: error: ld returned 1 exit status
make[4]: *** [test-linkedhash_set] Error 1
-tgc
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: test case build errors
2019-01-01 21:13 test case build errors Tom G. Christensen
@ 2019-01-04 19:32 ` Bruno Haible
2019-01-05 14:54 ` Tom G. Christensen
0 siblings, 1 reply; 3+ messages in thread
From: Bruno Haible @ 2019-01-04 19:32 UTC (permalink / raw)
To: bug-gnulib
Hi,
Tom G. Christensen wrote:
> A number of test cases currently fail to build on platforms that depend
> on libintl for gettext functions.
>
> From Solaris 9/x86:
>
> gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
> test-array_map test-array_map.o ../gllib/libgnu.a -lm -lm -lm
> -lm -lm -lm
> Undefined first referenced
> symbol in file
> libintl_gettext ../gllib/libgnu.a(xalloc-die.o)
> ld: fatal: Symbol referencing errors. No output written to test-array_map
> collect2: error: ld returned 1 exit status
> make[4]: *** [test-array_map] Error 1
>
> gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
> test-array_set test-array_set.o ../gllib/libgnu.a -lm -lm -lm
> -lm -lm -lm
> Undefined first referenced
> symbol in file
> libintl_gettext ../gllib/libgnu.a(xalloc-die.o)
> ld: fatal: Symbol referencing errors. No output written to test-array_set
> collect2: error: ld returned 1 exit status
> make[4]: *** [test-array_set] Error 1
>
> gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
> test-bitset test-bitset.o ../gllib/libgnu.a -lm -lm -lm -lm -
> lm -lm
> Undefined first referenced
> symbol in file
> libintl_gettext ../gllib/libgnu.a(stats.o)
> ld: fatal: Symbol referencing errors. No output written to test-bitset
> collect2: error: ld returned 1 exit status
> make[4]: *** [test-bitset] Error 1
>
> gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
> test-hash_map test-hash_map.o ../gllib/libgnu.a -lm -lm -lm -l
> m -lm -lm
> Undefined first referenced
> symbol in file
> libintl_gettext ../gllib/libgnu.a(xalloc-die.o)
> ld: fatal: Symbol referencing errors. No output written to test-hash_map
> collect2: error: ld returned 1 exit status
> make[4]: *** [test-hash_map] Error 1
>
> gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
> test-hash_set test-hash_set.o ../gllib/libgnu.a -lm -lm -lm -lm
> -lm -lm
> Undefined first referenced
> symbol in file
> libintl_gettext ../gllib/libgnu.a(xalloc-die.o)
> ld: fatal: Symbol referencing errors. No output written to test-hash_set
> collect2: error: ld returned 1 exit status
> make[4]: *** [test-hash_set] Error 1
>
> gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
> test-linkedhash_map test-linkedhash_map.o ../gllib/libgnu.a -lm -lm
> -lm -lm -lm -lm
> Undefined first referenced
> symbol in file
> libintl_gettext ../gllib/libgnu.a(xalloc-die.o)
> ld: fatal: Symbol referencing errors. No output written to
> test-linkedhash_map
> collect2: error: ld returned 1 exit status
> make[4]: *** [test-linkedhash_map] Error 1
>
> gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib -R/usr/tgcware/lib -o
> test-linkedhash_set test-linkedhash_set.o ../gllib/libgnu.a -lm -lm
> -lm -lm -lm -lm
> Undefined first referenced
> symbol in file
> libintl_gettext ../gllib/libgnu.a(xalloc-die.o)
> ld: fatal: Symbol referencing errors. No output written to
> test-linkedhash_set
> collect2: error: ld returned 1 exit status
> make[4]: *** [test-linkedhash_set] Error 1
Thanks for the report. Indeed, these modules need to link against libintl:
$ ./gnulib-tool --extract-recursive-link-directive bitset
$(LTLIBINTL) when linking with libtool, $(LIBINTL) otherwise
$ ./gnulib-tool --extract-recursive-link-directive array-map-tests
$(LTLIBINTL) when linking with libtool, $(LIBINTL) otherwise
$ ./gnulib-tool --extract-recursive-link-directive array-set-tests
$(LTLIBINTL) when linking with libtool, $(LIBINTL) otherwise
$ ./gnulib-tool --extract-recursive-link-directive hash-map-tests
$(LTLIBINTL) when linking with libtool, $(LIBINTL) otherwise
$ ./gnulib-tool --extract-recursive-link-directive hash-set-tests
$(LTLIBINTL) when linking with libtool, $(LIBINTL) otherwise
$ ./gnulib-tool --extract-recursive-link-directive linkedhash-map-tests
$(LTLIBINTL) when linking with libtool, $(LIBINTL) otherwise
$ ./gnulib-tool --extract-recursive-link-directive linkedhash-set-tests
$(LTLIBINTL) when linking with libtool, $(LIBINTL) otherwise
Fixed as follows.
2019-01-04 Bruno Haible <bruno@clisp.org>
Fix link errors in unit tests.
Reported by Tom G. Christensen <tgc@jupiterrise.com>.
* modules/bitset-tests (Makefile.am): Link test-bitset against libintl.
* modules/array-map-tests (Makefile.am): Link test-array_map against
libintl.
* modules/array-set-tests (Makefile.am): Link test-array_set against
libintl.
* modules/hash-map-tests (Makefile.am): Link test-hash_map against
libintl.
* modules/hash-set-tests (Makefile.am): Link test-hash_set against
libintl.
* modules/linkedhash-map-tests (Makefile.am): Link test-linkedhash_map
against libintl.
* modules/linkedhash-set-tests (Makefile.am): Link test-linkedhash_set
against libintl.
diff --git a/modules/array-map-tests b/modules/array-map-tests
index 7dbcd73..15907eb 100644
--- a/modules/array-map-tests
+++ b/modules/array-map-tests
@@ -12,3 +12,4 @@ configure.ac:
Makefile.am:
TESTS += test-array_map
check_PROGRAMS += test-array_map
+test_array_map_LDADD = $(LDADD) @LIBINTL@
diff --git a/modules/array-set-tests b/modules/array-set-tests
index 13149f5..86b6aaa 100644
--- a/modules/array-set-tests
+++ b/modules/array-set-tests
@@ -12,3 +12,4 @@ configure.ac:
Makefile.am:
TESTS += test-array_set
check_PROGRAMS += test-array_set
+test_array_set_LDADD = $(LDADD) @LIBINTL@
diff --git a/modules/bitset-tests b/modules/bitset-tests
index 4a7b8b3..f9a0f90 100644
--- a/modules/bitset-tests
+++ b/modules/bitset-tests
@@ -9,3 +9,4 @@ configure.ac:
Makefile.am:
TESTS += test-bitset
check_PROGRAMS += test-bitset
+test_bitset_LDADD = $(LDADD) @LIBINTL@
diff --git a/modules/hash-map-tests b/modules/hash-map-tests
index 693a026..1554055 100644
--- a/modules/hash-map-tests
+++ b/modules/hash-map-tests
@@ -11,3 +11,4 @@ configure.ac:
Makefile.am:
TESTS += test-hash_map
check_PROGRAMS += test-hash_map
+test_hash_map_LDADD = $(LDADD) @LIBINTL@
diff --git a/modules/hash-set-tests b/modules/hash-set-tests
index c98898c..8da90f7 100644
--- a/modules/hash-set-tests
+++ b/modules/hash-set-tests
@@ -11,3 +11,4 @@ configure.ac:
Makefile.am:
TESTS += test-hash_set
check_PROGRAMS += test-hash_set
+test_hash_set_LDADD = $(LDADD) @LIBINTL@
diff --git a/modules/linkedhash-map-tests b/modules/linkedhash-map-tests
index a21dad3..5b13ea1 100644
--- a/modules/linkedhash-map-tests
+++ b/modules/linkedhash-map-tests
@@ -11,3 +11,4 @@ configure.ac:
Makefile.am:
TESTS += test-linkedhash_map
check_PROGRAMS += test-linkedhash_map
+test_linkedhash_map_LDADD = $(LDADD) @LIBINTL@
diff --git a/modules/linkedhash-set-tests b/modules/linkedhash-set-tests
index a22c9e0..06c1cba 100644
--- a/modules/linkedhash-set-tests
+++ b/modules/linkedhash-set-tests
@@ -11,3 +11,4 @@ configure.ac:
Makefile.am:
TESTS += test-linkedhash_set
check_PROGRAMS += test-linkedhash_set
+test_linkedhash_set_LDADD = $(LDADD) @LIBINTL@
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: test case build errors
2019-01-04 19:32 ` Bruno Haible
@ 2019-01-05 14:54 ` Tom G. Christensen
0 siblings, 0 replies; 3+ messages in thread
From: Tom G. Christensen @ 2019-01-05 14:54 UTC (permalink / raw)
To: Bruno Haible, bug-gnulib
On 04/01/19 20:32, Bruno Haible wrote:
> Fixed as follows.
>
> 2019-01-04 Bruno Haible <bruno@clisp.org>
>
> Fix link errors in unit tests.
> Reported by Tom G. Christensen <tgc@jupiterrise.com>.
> * modules/bitset-tests (Makefile.am): Link test-bitset against libintl.
> * modules/array-map-tests (Makefile.am): Link test-array_map against
> libintl.
> * modules/array-set-tests (Makefile.am): Link test-array_set against
> libintl.
> * modules/hash-map-tests (Makefile.am): Link test-hash_map against
> libintl.
> * modules/hash-set-tests (Makefile.am): Link test-hash_set against
> libintl.
> * modules/linkedhash-map-tests (Makefile.am): Link test-linkedhash_map
> against libintl.
> * modules/linkedhash-set-tests (Makefile.am): Link test-linkedhash_set
> against libintl.
>
Thank you.
I can confirm that the above unit tests now build again on Solaris 2.6,
7, 8 and 9.
-tgc
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-01-05 14:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-01 21:13 test case build errors Tom G. Christensen
2019-01-04 19:32 ` Bruno Haible
2019-01-05 14:54 ` Tom G. Christensen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).