auctex-devel
[Top][All Lists]
Advanced

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

Re: [AUCTeX-devel] Re: [AUCTeX-diffs] Changes to auctex/Makefile.in


From: David Kastrup
Subject: Re: [AUCTeX-devel] Re: [AUCTeX-diffs] Changes to auctex/Makefile.in
Date: Thu, 09 Jun 2005 17:10:36 +0200
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

Ralf Angeli <address@hidden> writes:

> * David Kastrup (2005-06-09) writes:
>
>> Ralf Angeli <address@hidden> writes:
>>
>>> +DESCEND=if test -n "$(subdirs)"; then OLDPWD="`pwd`";for i in 
>>> ""$(subdirs);do cd $$i;echo "Descending into `pwd`";$(MAKE) 
>>> 'DESTDIR=$(DESTDIR)' PACKAGE=$(PACKAGE) $@ || exit $$?;cd $$OLDPWD;echo 
>>> "Ascending into $$OLDPWD";done;fi
>>>  
>>
>> One note here: avoid "if" in Makefile rules, rather use the
>> short-circuit operators || and &&.  The reason is that not all Bourne
>> shells return "success" for "if false", causing "make" to bomb out.
>
> I guess the something like the following should work.
>
> DESCEND=test -n "$(subdirs)" && (OLDPWD="`pwd`";for i in ""$(subdirs);do cd 
> $$i;echo "Descending into `pwd`";$(MAKE) 'DESTDIR=$(DESTDIR)' 
> PACKAGE=$(PACKAGE) $@ || exit $$?;cd $$OLDPWD;echo "Ascending into 
> $$OLDPWD";done)

No, the other way round.

test -z "$(subdirs)" || (...

Same problem: the exit code.

>> The alternative is to put in
>>
>> else :
>>
>> at the end.  Yes, this is idiotic.
>
> "else :"?  Never heard of that.

: is a noop in the Bourne Shell.

See
(info "(autoconf)Limitations of Builtins")
which will make your stomach turn...


-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum




reply via email to

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