bug-gnulib
[Top][All Lists]
Advanced

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

test-simple-atomic.c compilation error on Solaris


From: Tom G. Christensen
Subject: test-simple-atomic.c compilation error on Solaris
Date: Thu, 18 Mar 2021 20:41:27 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.0

Hello,

The test-simple-atomic test is failing to build on Solaris (tested 10 and older).

Here's the error from Solaris 10:

make[3]: Entering directory `/export/home/tgc/tmp/daily_build/gnulib/000-gnulib-simple-363497c93/gltests'
depbase=`echo test-simple-atomic.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
/usr/tgcware/gcc9/bin/gcc -DHAVE_CONFIG_H -DEXEEXT=\"\" -I. -I.. -DGNULIB_STRICT_CHECKING=1 -DIN_GNULIB_TESTS=1 -I. -I. -I.. -I./.. -I../gllib -I./../gllib -I/usr/tgcware/include -D_REENTRANT -g -O2 -MT test-simple-atomic.o -MD -MP -MF $depbase.Tpo -c -o test-simple-atomic.o test-simple-atomic.c &&\
mv -f $depbase.Tpo $depbase.Po
In file included from ../gllib/unistd.h:40,
                 from ../gllib/stdlib.h:100,
                 from ../gllib/glthread/thread.h:74,
                 from test-simple-atomic.c:43:
/usr/include/unistd.h:542:23: error: macro "yield" passed 1 arguments, but takes just 0
  542 | extern void yield(void);
      |                       ^
test-simple-atomic.c:38: note: macro "yield" defined here
   38 | # define yield() gl_thread_yield ()
      |
make[3]: *** [test-simple-atomic.o] Error 1
make[3]: Target `check-am' not remade because of errors.


It needs <unistd.h> before defining the macro.
Same issue as 617bc96d54db37c138bafb1872056de4453a248b.

-tgc



reply via email to

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