svn commit: r365531 - in head/cad/spice: . files

John Marino freebsd.contact at marino.st
Thu Aug 21 10:10:24 UTC 2014


On 8/21/2014 12:02, Tijl Coosemans wrote:
> On Thu, 21 Aug 2014 10:31:54 +0200 John Marino wrote:
>> On 8/21/2014 08:03, Hiroki Sato wrote:
>>> -	(cd ${CONFIG}/obj/bin && ${BSD_INSTALL_PROGRAM} \
>>> -		spice3 nutmeg sconvert help proc2mod multidec \
>>> -		${DESTDIR}${PREFIX}/bin)
>>> +	cd FreeBSD/obj/bin && \
>>> +		${BSD_INSTALL_PROGRAM} \
>>> +		    spice3 nutmeg sconvert help proc2mod multidec \
>>> +		    ${DESTDIR}${PREFIX}/bin
>>
>> I am so confused.
>> Half the people say we have to wrap compound commands in parenthesis and
>> the other half remove them.
>>
>> Does anyone have a definite answer?
>> Personally I've never seen the need but I was told not having them can
>> break -j multijob support.
> 
> With -j bmake runs the entire target as one script, which means cd
> changes the directory for all commands that follow.  Without -j each
> command runs as a separate script and cd has no effect on the next
> command.  To make sure there is no difference in behaviour between the
> two modes it is best to wrap cd && prog in parenthesis, such that it
> always runs in its own subshell.  It is also best to use && instead of ;
> because normally you don't want to run the second command if the first
> one fails.

Okay thanks.  So I had this right and hrs shouldn't have removed the
parenthesis.

Is this documented in PHB anywhere?  If it were simply made a rule then
there is no confusion at all.

John


More information about the svn-ports-all mailing list