autoconf
[Top][All Lists]
Advanced

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

AC_FUNC_SETVBUF_REVERSED in cross-compilation


From: Paul D. Smith
Subject: AC_FUNC_SETVBUF_REVERSED in cross-compilation
Date: 08 May 2002 12:47:51 -0400
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2

Hi all;

I notice that the AC_FUNC_SETVBUF_REVERSED macro has no option for how
it behaves during cross-compilation.

I understand that choosing one or the other default behavior is
problematic, but I'd really like to allow GNU make to be cross-compiled
(it seems like a very important prerequisite to the build suite!) and
GNU make uses this macro.

I have a partial solution, which is that the code uses setlinebuf() in
preference to setvbuf() if the former exists, so I can mirror that in
the configure.in file: not check for setvbuf() if setlinebuf() was
found.

For those cross-compiled systems which don't have setlinebuf(), I would
prefer that the configuration succeed and one of two things: either I
would just not run the setvbuf() function at all (it's only a safety
measure, after all), or I would assume the arguments were _not_ reversed
in a cross-compiled environment (the systems where it is reversed are
very old and surely must be rare these days: even more rare to
cross-compile with one as a target!)

I can't think of a "nice" way to do the former, though; setting
SETVBUF_REVERSED to some other value than 1 in a cross-compiled
environment, or maybe defining another macro altogether?  None of these
appeal to me.

Anyone else have any good ideas?

-- 
-------------------------------------------------------------------------------
 Paul D. Smith <address@hidden>          Find some GNU make tips at:
 http://www.gnu.org                      http://www.paulandlesley.org/gmake/
 "Please remain calm...I may be mad, but I am a professional." --Mad Scientist



reply via email to

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