bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

pthread-mutex-tests, pthread-rwlock-tests: Fix link errors on HP-UX


From: Bruno Haible
Subject: pthread-mutex-tests, pthread-rwlock-tests: Fix link errors on HP-UX
Date: Tue, 11 Feb 2020 04:00:44 +0100
User-agent: KMail/5.1.3 (Linux/4.4.0-171-generic; KDE/5.18.0; x86_64; ; )

On HP-UX 11.31 / ia64, I'm seeing these link errors:

cc +DD64 -AC99 -D_HPUX_SOURCE -D_XOPEN_SOURCE=600  -g  
-L/home/haible/prefix-hpux113ia64-64-cc/lib -o test-pthread-mutex 
test-pthread-mutex.o libtests.a ../gllib/libgnu.a libtests.a  -lpthread
ld: Unsatisfied symbol "sem_trywait" in file test-pthread-mutex.o
ld: Unsatisfied symbol "sem_init" in file test-pthread-mutex.o
ld: Unsatisfied symbol "sem_post" in file test-pthread-mutex.o
3 errors.
gmake[4]: *** [test-pthread-mutex] Error 1

cc +DD64 -AC99 -D_HPUX_SOURCE -D_XOPEN_SOURCE=600  -g  
-L/home/haible/prefix-hpux113ia64-64-cc/lib -o test-pthread-rwlock 
test-pthread-rwlock.o libtests.a ../gllib/libgnu.a libtests.a  -lpthread
ld: Unsatisfied symbol "sem_trywait" in file test-pthread-rwlock.o
ld: Unsatisfied symbol "sem_init" in file test-pthread-rwlock.o
ld: Unsatisfied symbol "sem_post" in file test-pthread-rwlock.o
3 errors.
gmake[4]: *** [test-pthread-rwlock] Error 1

This patch fixes them.


2020-02-10  Bruno Haible  <address@hidden>

        pthread-mutex-tests, pthread-rwlock-tests: Fix link errors on HP-UX.
        * modules/pthread-mutex-tests (Makefile.am): Link test-pthread-mutex
        with $(LIB_SEMAPHORE).
        * modules/pthread-rwlock-tests (Makefile.am): Link test-pthread-rwlock
        with $(LIB_SEMAPHORE).

diff --git a/modules/pthread-mutex-tests b/modules/pthread-mutex-tests
index eb6ec7b..12d386e 100644
--- a/modules/pthread-mutex-tests
+++ b/modules/pthread-mutex-tests
@@ -11,4 +11,4 @@ configure.ac:
 Makefile.am:
 TESTS += test-pthread-mutex
 check_PROGRAMS += test-pthread-mutex
-test_pthread_mutex_LDADD = $(LDADD) @LIBPMULTITHREAD@ @LIB_SCHED_YIELD@
+test_pthread_mutex_LDADD = $(LDADD) @LIBPMULTITHREAD@ @LIB_SCHED_YIELD@ 
@LIB_SEMAPHORE@
diff --git a/modules/pthread-rwlock-tests b/modules/pthread-rwlock-tests
index 7f35198..340ebf0 100644
--- a/modules/pthread-rwlock-tests
+++ b/modules/pthread-rwlock-tests
@@ -12,4 +12,4 @@ configure.ac:
 Makefile.am:
 TESTS += test-pthread-rwlock
 check_PROGRAMS += test-pthread-rwlock
-test_pthread_rwlock_LDADD = $(LDADD) @LIBPMULTITHREAD@ @LIB_SCHED_YIELD@
+test_pthread_rwlock_LDADD = $(LDADD) @LIBPMULTITHREAD@ @LIB_SCHED_YIELD@ 
@LIB_SEMAPHORE@




reply via email to

[Prev in Thread] Current Thread [Next in Thread]