Hi Bruno,
Bruno Haible <[email protected]> writes:
> Andy Wingo wrote:
>> > $LIBDIR/pkgconfig/guile-2.0.pc contains a line such as
>> >
>> > Cflags: -I${pkgincludedir}/2.0 -Wall -I$LIBUNISTRING_PREFIX/include
>> > -pthread -I$GC_PREFIX/include
>>
>> The template is:
>>
>> Cflags: -I${pkgincludedir}/@GUILE_EFFECTIVE_VERSION@ @GUILE_CFLAGS@
>> @BDW_GC_CFLAGS@
>> ...
>> And in configure.ac I have:
>>
>> GUILE_CFLAGS="$CPPFLAGS $PTHREAD_CFLAGS"
[...]
> You can extract the -I options from $CPPFLAGS; this would be OK since all
> compilers support -I.
That’s probably the right thing to do.
However, why do you have -Wall in CPPFLAGS, instead of CFLAGS, in the
first place? :-)
> For the PTHREAD_CFLAGS it is more tricky: On most platforms you can use
> "-lpthread" instead of "-pthread", and all compilers support -l options.
> But on OSF/1, the options for using threads are compiler dependent:
> * -pthread for cc,
> * -lpthread for gcc.
This and more, as Ken mentioned, so I’d leave it as is for now.
Thanks,
Ludo’.