Discussion:
test-rwlock1 build error on Solaris
(too old to reply)
Tom G. Christensen
2017-02-01 19:42:54 UTC
Permalink
Raw Message
Hello,

Building a full gnulib snapshot on Solaris is currently failing for me.

The error looks like this on Solaris 9:
/usr/tgcware/gcc49/bin/gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib
-R/usr/tgcware/lib -o test-rwlock1 test-rwlock1.o ../gllib/libgnu.a
-lpthread -lm -lm -lm -lm -lm -l
m
Undefined first referenced
symbol in file
sched_yield test-rwlock1.o
ld: fatal: Symbol referencing errors. No output written to test-rwlock1
collect2: error: ld returned 1 exit status
make[4]: *** [test-rwlock1] Error 1

It looks like just a missing @YIELD_LIB@ in modules/lock-tests.

-tgc
Bruno Haible
2017-02-01 21:49:02 UTC
Permalink
Raw Message
Hello Tom,
Post by Tom G. Christensen
/usr/tgcware/gcc49/bin/gcc -std=gnu11 -g -O2 -L/usr/tgcware/lib
-R/usr/tgcware/lib -o test-rwlock1 test-rwlock1.o ../gllib/libgnu.a
-lpthread -lm -lm -lm -lm -lm -l
m
Undefined first referenced
symbol in file
sched_yield test-rwlock1.o
ld: fatal: Symbol referencing errors. No output written to test-rwlock1
collect2: error: ld returned 1 exit status
make[4]: *** [test-rwlock1] Error 1
You're right, absolutely. Fixed:


2017-02-01 Bruno Haible <***@clisp.org>

lock tests: Fix link error.
* modules/lock-tests (test_rwlock1_LDADD): Add @***@.
Reported by Tom G. Christensen <***@jupiterrise.com>.

diff --git a/modules/lock-tests b/modules/lock-tests
index b42740c..b7f1a73 100644
--- a/modules/lock-tests
+++ b/modules/lock-tests
@@ -12,5 +12,5 @@ configure.ac:
Makefile.am:
TESTS += test-rwlock1 test-lock
check_PROGRAMS += test-rwlock1 test-lock
-test_rwlock1_LDADD = $(LDADD) @LIBMULTITHREAD@
+test_rwlock1_LDADD = $(LDADD) @LIBMULTITHREAD@ @YIELD_LIB@
test_lock_LDADD = $(LDADD) @LIBMULTITHREAD@ @YIELD_LIB@
Tom G. Christensen
2017-02-02 05:45:29 UTC
Permalink
Raw Message
Post by Bruno Haible
lock tests: Fix link error.
Thank you.

To confirm I made a testdir with just the lock-tests and it builds fine
on Solaris 9 and all the tests pass.

-tgc

Loading...