Hi Collin,

> Here is the sys_un module as promised + typical C/C++ header checks.

The continuous integration detected a compilation failure on
Ubuntu 22.04, with clang 18 as compiler:

clang++ -DHAVE_CONFIG_H -DEXEEXT=\"\" -DEXEEXT=\"\" -I. -I../../gltests -I..  
-DGNULIB_STRICT_CHECKING=1 -DIN_GNULIB_TESTS=1 -I. -I../../gltests -I.. 
-I../../gltests/.. -I../gllib -I../../gltests/../gllib -Wall 
-DCONTINUE_AFTER_ASSERT  -Wno-error -g -O2 -MT test-sys_un-c++.o -MD -MP -MF 
$depbase.Tpo -c -o test-sys_un-c++.o ../../gltests/test-sys_un-c++.cc &&\
mv -f $depbase.Tpo $depbase.Po
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:809:20: error: declaration of 'memchr' has a different 
language linkage
  809 | _GL_CXXALIASWARN1 (memchr, void *,
      |                    ^
/usr/include/string.h:78:1: note: previous definition is here
   78 | memchr (void *__s, int __c, size_t __n) __THROW
      | ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:812:20: error: declaration of 'memchr' has a different 
language linkage
  812 | _GL_CXXALIASWARN1 (memchr, void const *,
      |                    ^
/usr/include/string.h:84:1: note: previous definition is here
   84 | memchr (const void *__s, int __c, size_t __n) __THROW
      | ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:914:20: error: declaration of 'memrchr' has a different 
language linkage
  914 | _GL_CXXALIASWARN1 (memrchr, void *,
      |                    ^
/usr/include/string.h:110:20: note: previous declaration is here
  110 | extern "C++" void *memrchr (void *__s, int __c, size_t __n)
      |                    ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:917:20: error: declaration of 'memrchr' has a different 
language linkage
  917 | _GL_CXXALIASWARN1 (memrchr, void const *,
      |                    ^
/usr/include/string.h:112:26: note: previous declaration is here
  112 | extern "C++" const void *memrchr (const void *__s, int __c, size_t __n)
      |                          ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:976:20: error: declaration of 'rawmemchr' has a different 
language linkage
  976 | _GL_CXXALIASWARN1 (rawmemchr, void *,
      |                    ^
/usr/include/string.h:99:20: note: previous declaration is here
   99 | extern "C++" void *rawmemchr (void *__s, int __c)
      |                    ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:979:20: error: declaration of 'rawmemchr' has a different 
language linkage
  979 | _GL_CXXALIASWARN1 (rawmemchr, void const *,
      |                    ^
/usr/include/string.h:101:26: note: previous declaration is here
  101 | extern "C++" const void *rawmemchr (const void *__s, int __c)
      |                          ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:1101:20: error: declaration of 'strchrnul' has a different 
language linkage
 1101 | _GL_CXXALIASWARN1 (strchrnul, char *,
      |                    ^
/usr/include/string.h:261:20: note: previous declaration is here
  261 | extern "C++" char *strchrnul (char *__s, int __c)
      |                    ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:1104:20: error: declaration of 'strchrnul' has a different 
language linkage
 1104 | _GL_CXXALIASWARN1 (strchrnul, char const *,
      |                    ^
/usr/include/string.h:263:26: note: previous declaration is here
  263 | extern "C++" const char *strchrnul (const char *__s, int __c)
      |                          ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:1340:20: error: declaration of 'strpbrk' has a different 
language linkage
 1340 | _GL_CXXALIASWARN1 (strpbrk, char *,
      |                    ^
/usr/include/string.h:290:1: note: previous definition is here
  290 | strpbrk (char *__s, const char *__accept) __THROW
      | ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:1343:20: error: declaration of 'strpbrk' has a different 
language linkage
 1343 | _GL_CXXALIASWARN1 (strpbrk, char const *,
      |                    ^
/usr/include/string.h:296:1: note: previous definition is here
  296 | strpbrk (const char *__s, const char *__accept) __THROW
      | ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:1452:20: error: declaration of 'strstr' has a different 
language linkage
 1452 | _GL_CXXALIASWARN1 (strstr, char *,
      |                    ^
/usr/include/string.h:317:1: note: previous definition is here
  317 | strstr (char *__haystack, const char *__needle) __THROW
      | ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:1455:20: error: declaration of 'strstr' has a different 
language linkage
 1455 | _GL_CXXALIASWARN1 (strstr, const char *,
      |                    ^
/usr/include/string.h:323:1: note: previous definition is here
  323 | strstr (const char *__haystack, const char *__needle) __THROW
      | ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:1505:20: error: declaration of 'strcasestr' has a different 
language linkage
 1505 | _GL_CXXALIASWARN1 (strcasestr, char *,
      |                    ^
/usr/include/string.h:354:20: note: previous declaration is here
  354 | extern "C++" char *strcasestr (char *__haystack, const char *__needle)
      |                    ^
In file included from ../../gltests/test-sys_un-c++.cc:24:
In file included from /usr/include/x86_64-linux-gnu/sys/un.h:37:
../gllib/string.h:1508:20: error: declaration of 'strcasestr' has a different 
language linkage
 1508 | _GL_CXXALIASWARN1 (strcasestr, const char *,
      |                    ^
/usr/include/string.h:356:26: note: previous declaration is here
  356 | extern "C++" const char *strcasestr (const char *__haystack,
      |                          ^
14 errors generated.
make[4]: *** [Makefile:27296: test-sys_un-c++.o] Error 1
make[4]: Leaving directory '/work/testdir-all/build/gltests'


Can you please find a workaround?

Bruno




Reply via email to