unavoidable(?) warning from newlib header

Ti Strga wearyofallthiscrap@gmail.com
Thu Mar 20 22:39:00 GMT 2008

I'm surprised that I didn't find more people complaining about this,
which makes me think that either I'm doing something wrong with my
build, or I'm not using Google correctly.

We're using newlib 1.15 on cygwin, targeting a vanilla powerpc-elf
platform with a cross compiler.  Any time we include pthread.h, we get

warning: #warning "Add pthread_atfork() prototype"

The code in that header surrounding the warning is checking for whether
we're using RTEMS, but no other checks are done.  We're not running
RTEMS, and I don't care for lying to the preprocessor and saying that we
are.  Is there some way of avoiding the noise?

(We don't plan on using pthread_atfork in our product anytime soon, but
if we ever do, I know we can also get a declaration from unistd.h.  Do
we really need to be warned on every source file?)

Thanks for any tips,

More information about the Newlib mailing list