[Top][All Lists]

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

Re: [Bug-wget] flock is not available on solaris 10 (at least sparc)

From: Tim Ruehsen
Subject: Re: [Bug-wget] flock is not available on solaris 10 (at least sparc)
Date: Tue, 15 Dec 2015 16:39:02 +0100
User-agent: KMail/4.14.10 (Linux/4.3.0-1-amd64; KDE/4.14.14; x86_64; ; )

On Tuesday 15 December 2015 21:55:53 Kiyoshi KANAZAWA wrote:
> 2. about #error "Compiler or options invalid for pre-UNIX 03 X/Open
> applications" This error may depends on compilers.
> Both of  "solarisstudio12.4"  &  "gcc-4.8.5" can build wget-1.17.1 without
> errors.
> But I once experienced the similar problem when trying to compile
> "sam2p-0.49.2". At that time, gcc-4.4.7 passed, but gcc-4.8.* stopped with
> this error and I had to set "-D_XPG6" as optional cc flags.
> ./configure of wget checks compiler to accept ISO C89, such as
> "checking for gcc -O3 option to accept ISO C89... none needed".
> If "-std=c89" is required for some versions of gcc, shouldn't it set in
> configure ?

You could try to insert AC_PROG_CC_C89 after AC_PROG_CC. AFAIK, it will add -
std=c89 but only if needed (if the compiler does not support C89 without it).

autoreconf && ./configure && make clean && make
to see if the problem still occurs.

Setting CFLAGS directly in configure.ac is not recommended, AFAIK. Maybe just 
a set of compilers understands -std=c89 !? Also, setting -std=c89 might be 
helpful or not, depending of the compiler and version. Nobody is going to 
waste time working on such a list/table.

Maybe we should ask the gnulib people, why flock() isn't emulated on Solaris 
when -std=c89 is missing !? I could simply be a bug...

Also, we could replace flock() by some fcntl() code. But then, that is what 
gnulib should do for us.


reply via email to

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