From: Bruno Haible Date: Mon, 3 Jun 2024 10:43:06 +0000 (+0200) Subject: mtx tests: Fix a possible link error. X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=6d4be46eab8c916d08ce95ef1d931ba845fc3110;p=gnulib.git mtx tests: Fix a possible link error. * modules/mtx-tests (Files): Add m4/semaphore.m4. (configure.ac): Require gl_SEMAPHORE. (Makefile.am): Link test-mtx with @LIB_SEMAPHORE@. --- diff --git a/ChangeLog b/ChangeLog index 9cf965bd48..7f574d38a6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2024-06-03 Bruno Haible + + mtx tests: Fix a possible link error. + * modules/mtx-tests (Files): Add m4/semaphore.m4. + (configure.ac): Require gl_SEMAPHORE. + (Makefile.am): Link test-mtx with @LIB_SEMAPHORE@. + 2024-06-03 Bruno Haible pthread-mutex, pthread-rwlock: Fix a compilation error. diff --git a/modules/mtx-tests b/modules/mtx-tests index 063a56d67f..323d392087 100644 --- a/modules/mtx-tests +++ b/modules/mtx-tests @@ -2,6 +2,7 @@ Files: tests/test-mtx.c tests/atomic-int-isoc.h tests/macros.h +m4/semaphore.m4 Depends-on: thrd @@ -12,8 +13,9 @@ random configure.ac: AC_CHECK_HEADERS_ONCE([semaphore.h]) AC_CHECK_DECLS_ONCE([alarm]) +AC_REQUIRE([gl_SEMAPHORE]) Makefile.am: TESTS += test-mtx check_PROGRAMS += test-mtx -test_mtx_LDADD = $(LDADD) @LIBSTDTHREAD@ @LIBTHREAD@ +test_mtx_LDADD = $(LDADD) @LIBSTDTHREAD@ @LIBTHREAD@ @LIB_SEMAPHORE@