[commit: ghc] master: Build system: remove hack for Mac OSX in configure.ac (#10476) (864a9c4)

git at git.haskell.org git at git.haskell.org
Tue Sep 8 08:03:44 UTC 2015


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/864a9c4f83156caacae5777b3ad6b93b4da9c242/ghc

>---------------------------------------------------------------

commit 864a9c4f83156caacae5777b3ad6b93b4da9c242
Author: Thomas Miedema <thomasmiedema at gmail.com>
Date:   Mon Sep 7 15:58:33 2015 +0200

    Build system: remove hack for Mac OSX in configure.ac (#10476)
    
    Cross-compilation on Mac OSX currently doesn't work. While building
    stage 1, the build system uses the `ar` for the target architecture
    instead of the `ar` for build/host architecture.
    
    The cause is a hack added in 24746fe78024a1edab843bc710c79c55998ab134
    (2010), to supporting bootstrap compilers built with older versions of
    Xcode. Xcode 4.3 started installing command line tools in a different
    location. Assuming this all behind us now, and the paths didn't change
    again (you never now), we can delete the hack.
    
    Deleting the hack fixes the cross compilation issue. Tested by Trac user
    jakzale.
    
    Reviewed by: austin
    
    Differential Revision: https://phabricator.haskell.org/D1231


>---------------------------------------------------------------

864a9c4f83156caacae5777b3ad6b93b4da9c242
 configure.ac | 13 +++----------
 1 file changed, 3 insertions(+), 10 deletions(-)

diff --git a/configure.ac b/configure.ac
index 793ec0f..47b07dd 100644
--- a/configure.ac
+++ b/configure.ac
@@ -121,20 +121,13 @@ if test "$WithGhc" != ""; then
   GhcMinVersion2=`echo "$GhcMinVersion" | sed 's/^\\(.\\)$/0\\1/'`
   GhcCanonVersion="$GhcMajVersion$GhcMinVersion2"
 
-  BOOTSTRAPPING_GHC_INFO_FIELD([OS_STAGE0],[target os])
   BOOTSTRAPPING_GHC_INFO_FIELD([CC_STAGE0],[C compiler command])
   dnl ToDo, once "ld command" is reliably available.
   dnl Then, we can remove the LD_STAGE0 hack in mk/build-package-date.mk
   dnl BOOTSTRAPPING_GHC_INFO_FIELD([LD_STAGE0],[ld command])
-  if test "x$OS_STAGE0" != "xOSDarwin"; then
-    BOOTSTRAPPING_GHC_INFO_FIELD([AR_STAGE0],[ar command])
-    BOOTSTRAPPING_GHC_INFO_FIELD([AR_OPTS_STAGE0],[ar flags])
-    BOOTSTRAPPING_GHC_INFO_FIELD([ArSupportsAtFile_STAGE0],[ar supports at file])
-  else
-    AR_STAGE0='$(AR)'
-    AR_OPTS_STAGE0='$(AR_OPTS)'
-    ArSupportsAtFile_STAGE0='$(ArSupportsAtFile)'
-  fi
+  BOOTSTRAPPING_GHC_INFO_FIELD([AR_STAGE0],[ar command])
+  BOOTSTRAPPING_GHC_INFO_FIELD([AR_OPTS_STAGE0],[ar flags])
+  BOOTSTRAPPING_GHC_INFO_FIELD([ArSupportsAtFile_STAGE0],[ar supports at file])
 fi
 
 dnl ** Must have GHC to build GHC



More information about the ghc-commits mailing list