[m-rev.] Fix configure deleting C files when no bootstrap compiler exists

Keri Harris keri at gentoo.org
Mon Jan 8 05:02:24 AEDT 2007


The configure script will always check whether C files need to be rebuilt. 
From configure.in:


3831	if test "$BOOTSTRAP_MC" = ""; then
3832		BOOTSTRAP_MC=mmc
3833	fi


4298	if test "$BOOTSTRAP_MC" != "" ; then
4299	    MERCURY_MSG("checking whether any C files need to be rebuilt...")
...
4331	    rm -f confscratch $to_delete
4332	fi


This will cause problems if there is no Mercury compiler to bootstrap with.


Index: configure.in
===================================================================
RCS file: /home/mercury1/repository/mercury/configure.in,v
retrieving revision 1.482
diff -u -B -r1.482 configure.in
--- configure.in	22 Dec 2006 08:31:17 -0000	1.482
+++ configure.in	7 Jan 2007 17:56:32 -0000
@@ -3828,16 +3828,6 @@
 	AC_DEFINE(MR_USE_DLLS)
 fi
 
#-----------------------------------------------------------------------------#
-if test "$BOOTSTRAP_MC" = ""; then
-	BOOTSTRAP_MC=mmc
-fi
-BOOTSTRAP_MC_COMPILER="$BOOTSTRAP_MC"
-BOOTSTRAP_MC_ARGS="$HAVE_BOXED_FLOATS --conf-low-tag-bits 
$LOW_TAG_BITS --bits-per-word $BITS_PER_WORD --bytes-per-word 
$BYTES_PER_WORD"
-BOOTSTRAP_MC="$BOOTSTRAP_MC_COMPILER $BOOTSTRAP_MC_ARGS"
-AC_SUBST(BOOTSTRAP_MC_COMPILER)
-AC_SUBST(BOOTSTRAP_MC_ARGS)
-AC_SUBST(BOOTSTRAP_MC)
-#-----------------------------------------------------------------------------#
 
 # The following allows us to share some subroutines between the
 # `ml' and `mgnuc' scripts.
@@ -4330,6 +4320,16 @@
     fi
     rm -f confscratch $to_delete
 fi
+#-----------------------------------------------------------------------------#
+if test "$BOOTSTRAP_MC" = ""; then
+	BOOTSTRAP_MC=mmc
+fi
+BOOTSTRAP_MC_COMPILER="$BOOTSTRAP_MC"
+BOOTSTRAP_MC_ARGS="$HAVE_BOXED_FLOATS --conf-low-tag-bits 
$LOW_TAG_BITS --bits-per-word $BITS_PER_WORD --bytes-per-word 
$BYTES_PER_WORD"
+BOOTSTRAP_MC="$BOOTSTRAP_MC_COMPILER $BOOTSTRAP_MC_ARGS"
+AC_SUBST(BOOTSTRAP_MC_COMPILER)
+AC_SUBST(BOOTSTRAP_MC_ARGS)
+AC_SUBST(BOOTSTRAP_MC)
 
#-----------------------------------------------------------------------------#
 
 AC_MSG_CHECKING(for C shell executable)


Keri

-- 
Keri Harris - Gentoo Developer
Public Key:
http://pgp.mit.edu:11371/pks/lookup?op=get&search=0xA128F5ED
Key fingerprint = 1690 30DA 4950 E710 A871 07D7 AF04 BFB6 A138 F5ED
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.mercurylang.org/archives/reviews/attachments/20070108/43c38a50/attachment.sig>


More information about the reviews mailing list