[m-dev.] diff: update configure.in to work with MSVC

Peter Ross petdr at cs.mu.OZ.AU
Thu Jun 22 23:29:35 AEST 2000


Hi,


===================================================================


Estimated hours taken: 0.5

configure.in:
    When testing for a usable mercury compiler, strip any carriage
    returns from the output string.
    If compiling under Windows use hlc.gc for the default grade and
    don't build the libraries in any other grades (as those grades aren't
    supported yet).


Index: configure.in
===================================================================
RCS file: /home/mercury1/repository/mercury/configure.in,v
retrieving revision 1.209
diff -u -r1.209 configure.in
--- configure.in	2000/06/16 16:37:02	1.209
+++ configure.in	2000/06/22 13:24:04
@@ -104,7 +104,7 @@
 	 	 echo $BOOTSTRAP_MC conftest >&AC_FD_CC 2>&1 &&
 	 	 $BOOTSTRAP_MC --high-level-code conftest \
 		 	</dev/null >&AC_FD_CC 2>&1 &&
-		 test "`./conftest 2>&1`" = "Hello, world"
+		 test "`./conftest 2>&1 | tr -d '\015'`" = "Hello, world"
 	then
 		AC_MSG_RESULT(yes)
 	else
@@ -1651,7 +1651,11 @@
 	if test $mercury_cv_gcc_model_reg = yes; then
 		BEST_GRADE=reg
 	else
-		BEST_GRADE=none
+		if test $ac_microsoft = yes; then
+			BEST_GRADE=hlc
+		else
+			BEST_GRADE=none
+		fi
 	fi
 fi
 
@@ -1766,9 +1770,16 @@
 # add `hlc' (--high-level-code, i.e. MLDS back-end) grade
 LIBGRADES="$LIBGRADES hlc.gc"
 
+# If we are using the MS compiler currently the only interesting grade
+# is hlc.gc, which is what we install by default.
+if test $ac_microsoft = yes; then
+	LIBGRADES=
+fi
+
 # remove GRADE from LIBGRADES
 LIBGRADES=` echo " $LIBGRADES " | sed "s/ $GRADE / /" `
 MERCURY_MSG("using \`LIBGRADES=$LIBGRADES' as the set of library grades to install")
+
 AC_SUBST(LIBGRADES)
 #-----------------------------------------------------------------------------#
 #

--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to:       mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions:          mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------



More information about the developers mailing list