[m-dev.] More build system patches

Peter Hawkins peter at hawkins.emu.id.au
Sun Jul 18 14:12:25 AEST 2004


Hi...

Attached are three more patches against the mercury build system.

configure.in.patch:
It turns out that s390 systems can report themselves as s390-ibm-linux-gnu or 
s390x-ibm-linux-gnu, so I changed the pattern in the s390 test to just s390*.

Makefile.patch:
If you run make all or make install from the top-level mercury directory and 
the build fails, the exit status of make will not reflect that. This is 
because the makefile contains targets like this:

all:
	$(MMAKE) all 2>&1 | tee make_all.log

Since the exit status of a pipeline in the bourne shell is the exit status of 
the last command in the pipe, the outermost make will not notice if the mmake 
invocation fails (instead, it will see that the exit status of 'tee' was 0 
and assume the command succeeded). This was causing the debian build scripts 
to report success when the build in fact failed.

Accordingly, this patch contains a rather disgusting hack to work around this. 
(If you could assume that the shell in use was bash, then you could use 
${PIPESTATUS[0]} to obtain the exit status of the mmake command, but that's 
not POSIX compliant).

runtime-Mmakefile.patch:
ia64-regs.h should be installed as well.


Would it be possible to change the default grade for building the compiler to 
hlc.gc? hlc.gc is more portable than the LLDS grades as well as giving 
reasonably good performance.

At the moment for the debian packages I am forced to rebuild the mercury 
source packages using grade hlc.gc for the precompiled C files.

=)
Peter


-------------- next part --------------
A non-text attachment was scrubbed...
Name: configure.in.patch
Type: text/x-diff
Size: 383 bytes
Desc: not available
URL: <http://lists.mercurylang.org/archives/developers/attachments/20040718/82dd8b90/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: runtime-Mmakefile.patch
Type: text/x-diff
Size: 386 bytes
Desc: not available
URL: <http://lists.mercurylang.org/archives/developers/attachments/20040718/82dd8b90/attachment-0001.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Makefile.patch
Type: text/x-makefile
Size: 1674 bytes
Desc: not available
URL: <http://lists.mercurylang.org/archives/developers/attachments/20040718/82dd8b90/attachment.bin>


More information about the developers mailing list