[longomatch] Allow manually set compiler to support 2.0 or 4.0



commit 6f2e71cd7801a42d29cb7c11dc050ce198246d13
Author: Iain Lane <laney debian org>
Date:   Sun Jun 26 18:04:10 2011 +0100

    Allow manually set compiler to support 2.0 or 4.0
    
    Previously the 4.0 profile was forced when MCS was explicitly set.
    Instead infer the profile to use from the system.

 configure.ac |   20 +++++++++-----------
 1 files changed, 9 insertions(+), 11 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 19c5432..17bda97 100644
--- a/configure.ac
+++ b/configure.ac
@@ -50,23 +50,21 @@ AM_GLIB_GNU_GETTEXT
 dnl Mono and C# compiler
 dnl Check first for a 4.0 compiler or than fallback to 2.0
 SHAMROCK_CHECK_MONO_MODULE(2.4.0)
-AC_PATH_PROG(MCS, dmcs, no)
-	if test "x$MCS" = "xno"; then
-		unset ac_cv_path_MCS
-		SHAMROCK_FIND_MONO_2_0_COMPILER
-		SHAMROCK_CHECK_MONO_2_0_GAC_ASSEMBLIES([	
+PKG_CHECK_EXISTS([mono >= 2.8],
+		[SHAMROCK_FIND_MONO_4_0_COMPILER
+		SHAMROCK_CHECK_MONO_4_0_GAC_ASSEMBLIES([
 			System.Data
 			Mono.Cairo
 			Mono.Posix
-		])
-	else
-		AC_SUBST(MCS, ["$MCS"])
-		SHAMROCK_CHECK_MONO_4_0_GAC_ASSEMBLIES([	
+		])]
+,
+		[SHAMROCK_FIND_MONO_2_0_COMPILER
+		SHAMROCK_CHECK_MONO_2_0_GAC_ASSEMBLIES([
 			System.Data
 			Mono.Cairo
 			Mono.Posix
-		])
-	fi
+		])])
+AC_SUBST(MCS, ["$MCS"])
 SHAMROCK_FIND_MONO_RUNTIME
 
 dnl NUnit (optional)



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