ghc.mk: fix 'make install' for cross-mingw32
[ghc.git] / aclocal.m4
index 6341bc9..fc7b24c 100644 (file)
@@ -14,7 +14,8 @@ AC_DEFUN([GHC_SELECT_FILE_EXTENSIONS],
         AC_MSG_WARN([I'm assuming you wanted to build for i386-unknown-mingw32])
         exit 1
         ;;
-    *-unknown-mingw32)
+    # examples: i386-unknown-mingw32, i686-w64-mingw32, x86_64-w64-mingw32
+    *-mingw32)
         windows=YES
         $2='.exe'
         $3='.dll'
@@ -227,7 +228,7 @@ AC_DEFUN([FPTOOLS_SET_HASKELL_PLATFORM_VARS],
 
     checkVendor() {
         case [$]1 in
-        dec|unknown|hp|apple|next|sun|sgi|ibm|montavista|portbld)
+        dec|none|unknown|hp|apple|next|sun|sgi|ibm|montavista|portbld)
             ;;
         *)
             echo "Unknown vendor [$]1"
@@ -1130,7 +1131,9 @@ AC_SUBST([LdHasFilelist])
 # ----------
 # Sets fp_prog_ar to a path to ar. Exits if no ar can be found
 AC_DEFUN([FP_PROG_AR],
-[AC_PATH_PROG([fp_prog_ar], [ar])
+[if test -z "$fp_prog_ar"; then
+  AC_PATH_PROG([fp_prog_ar], [ar])
+fi
 if test -z "$fp_prog_ar"; then
   AC_MSG_ERROR([cannot find ar in your PATH, no idea how to make a library])
 fi