ports/64037 and the alleged && -> ; failure from March 2002
eikemeier at fillmore-labs.com
Sat Mar 13 03:01:40 PST 2004
Matthias Andree wrote:
> On Sat, 13 Mar 2004, Oliver Eikemeier wrote:
>>I don't agree with the arguments, but I don't understand
>>- Switch from ; to && in order to not hide cd errors or run the make
>> the wrong directory.
>>either. Both give
>> cd: can't cd to /nonexistent
>> *** Error code 2
>>and stop the build, or do you do use make -i regularly?
> Is it guaranteed that make will always under all circumstances run the
> shell with the "-e" flag? And if it does, does GNU make from the ports
> do that as well? The '&&' variant will do The Right Thing® with and
> without the -e flag passed down the /bin/sh, whereas a 'cd /nonexistent ;
> rm -rf * .??*' will happily erase the current working directory if
> /nonexistent is non-existent and the shell is run without -e.
make will run the shell with -e unless the line starts with `-' or `-i'
GNU make is not used for ports Makefiles, only for the ones in the
distribution, and you don't want to Patch Them All(tm), do you?
Finally I'm not sure if simply ignoring the following command is the
right thing to do. I can construct an example where this is fatal too,
but IMHO all such examples would be pathological.
More information about the freebsd-ports