Last week I wrote: > strerror_l: Add tests. > * tests/test-strerror_l.c: New file. > * modules/strerror_l-tests: New file.
This test has a link error on macOS, FreeBSD, OpenBSD, Cygwin: cc -Wno-error -g -O2 -L/usr/local/lib -o test-strerror_l test-strerror_l.o libtests.a ../gllib/libgnu.a libtests.a ../gllib/libgnu.a libtests.a -lbacktrace -lm -lm -lm -lm -lm -lm -lm -lm -lm -lm -lm ld: error: undefined symbol: libintl_dgettext >>> referenced by xalloc-die.c:34 (../../gllib/xalloc-die.c:34) >>> xalloc-die.o:(xalloc_die) in archive ../gllib/libgnu.a >>> referenced by error.c:208 (../../gllib/error.c:208) >>> error.o:(error_tail) in archive ../gllib/libgnu.a cc: error: linker command failed with exit code 1 (use -v to see invocation) *** Error code 1 This patch should fix it. 2025-02-24 Bruno Haible <br...@clisp.org> strerror_l tests: Fix link error. * modules/strerror_l-tests (Makefile.am): Link the test program with LIBINTL. diff --git a/modules/strerror_l-tests b/modules/strerror_l-tests index 356788852e..98138e90ff 100644 --- a/modules/strerror_l-tests +++ b/modules/strerror_l-tests @@ -13,4 +13,4 @@ configure.ac: Makefile.am: TESTS += test-strerror_l check_PROGRAMS += test-strerror_l -test_strerror_l_LDADD = $(LDADD) $(GETLOCALENAME_L_LIB) +test_strerror_l_LDADD = $(LDADD) @LIBINTL@ $(GETLOCALENAME_L_LIB)