On Tue, 16 Oct 2007, Micah Cowan wrote:

> I may take liberties with the Make environment, and assume the presence
> of a GNU toolset, though I'll try to avoid that where it's possible.

 Well, the issue has been resolved one way or another with many GNU 
packages, including the core ones such as GCC, which generally try to be 
as much portable as possible.  It is always worth investigating what 
others have done and copying the good examples.  Please also note the 
autoconf manual has chapters on shell and make portability issues which 
provide examples how to do many things in a reliable way.

> In cases like this, printf is much more portable (in behavior) than
> echo, but not as dependable (on fairly old systems) for presence;
> however, it's not a difficult tool to obtain, and I wouldn't mind making
> it a prerequisite for Wget (on Unix systems, at any rate). In a pinch,
> one could write an included tool (such as an "echo" command that does
> precisely what we expect) to help with building. But basically, if it's
> been in POSIX a good while, I'll probably expect it to be available for
> the Unix build.

 You better avoid the hassle of compiling any code to be run on the build 
system by any measures unless absolutely necessary or you risk falling 
down into a hole of horrible traps and riddles once you start 
cross-compiling.

  Maciej

Reply via email to