[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: fnmatch: Overcome wchar_t limitations
|
From: |
Bruno Haible |
|
Subject: |
Re: fnmatch: Overcome wchar_t limitations |
|
Date: |
Thu, 27 Jul 2023 23:14:20 +0200 |
> This patch caused link errors on mingw, with libunistring installed:
And similarly a few link errors on MSVC, with libunistring installed:
libgnu.a(fnmatch.obj) : error LNK2019: unresolved external symbol u32_chr
referenced in function internal_fnwmatch
libgnu.a(fnmatch.obj) : error LNK2019: unresolved external symbol u32_strlen
referenced in function ext_wmatch
libgnu.a(fnmatch.obj) : error LNK2019: unresolved external symbol u32_strcat
referenced in function ext_wmatch
...
test-fnmatch-h-c++.exe : fatal error LNK1120: 12 unresolved externals
make[4]: *** [Makefile:18134: test-fnmatch-h-c++.exe] Error 2
libgnu.a(fnmatch.obj) : error LNK2019: unresolved external symbol u32_chr
referenced in function internal_fnwmatch
libgnu.a(fnmatch.obj) : error LNK2019: unresolved external symbol u32_strlen
referenced in function ext_wmatch
libgnu.a(fnmatch.obj) : error LNK2019: unresolved external symbol u32_strcat
referenced in function ext_wmatch
...
test-glob-h-c++.exe : fatal error LNK1120: 12 unresolved externals
make[4]: *** [Makefile:18526: test-glob-h-c++.exe] Error 2
This patch fixes it.
2023-07-27 Bruno Haible <bruno@clisp.org>
fnmatch-h, glob-h tests: Fix link errors (regression 2023-07-24).
* modules/fnmatch-h-c++-tests (Makefile.am): Link test-fnmatch-h-c++
with $(LIBUNISTRING).
* modules/glob-h-c++-tests (Makefile.am): Link test-glob-h-c++ with
$(LIBUNISTRING).
diff --git a/modules/fnmatch-h-c++-tests b/modules/fnmatch-h-c++-tests
index eedd075d23..9051215f6c 100644
--- a/modules/fnmatch-h-c++-tests
+++ b/modules/fnmatch-h-c++-tests
@@ -15,5 +15,5 @@ if ANSICXX
TESTS += test-fnmatch-h-c++
check_PROGRAMS += test-fnmatch-h-c++
test_fnmatch_h_c___SOURCES = test-fnmatch-h-c++.cc
-test_fnmatch_h_c___LDADD = $(LDADD) $(MBRTOWC_LIB)
+test_fnmatch_h_c___LDADD = $(LDADD) $(LIBUNISTRING) $(MBRTOWC_LIB)
endif
diff --git a/modules/glob-h-c++-tests b/modules/glob-h-c++-tests
index 965f53f186..2a80a3d4b1 100644
--- a/modules/glob-h-c++-tests
+++ b/modules/glob-h-c++-tests
@@ -15,5 +15,5 @@ if ANSICXX
TESTS += test-glob-h-c++
check_PROGRAMS += test-glob-h-c++
test_glob_h_c___SOURCES = test-glob-h-c++.cc
-test_glob_h_c___LDADD = $(LDADD) $(LIBINTL) $(CLOCK_TIME_LIB) $(MBRTOWC_LIB)
+test_glob_h_c___LDADD = $(LDADD) $(LIBUNISTRING) $(LIBINTL) $(CLOCK_TIME_LIB)
$(MBRTOWC_LIB)
endif