]> gitweb @ CieloNegro.org - pkgsrc-ghc.git/commitdiff
Small fixes for Darwin
authorPHO <pho@cielonegro.org>
Tue, 19 Jan 2010 08:20:21 +0000 (17:20 +0900)
committerPHO <pho@cielonegro.org>
Tue, 19 Jan 2010 08:20:21 +0000 (17:20 +0900)
Makefile

index 3bc235892c4cda8751ee378a79b0f53a1b46427a..399d09d818d8316ef60c0b5f16dcd655571ebc4f 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -35,7 +35,8 @@ ONLY_FOR_PLATFORM= NetBSD-*-i386 FreeBSD-*-i386 Darwin-*-powerpc
 # way than this?
 .include "../../mk/compiler.mk"
 .if empty(CCPATH)
-WARNINGS+= "This package depends on pkgsrc's undocumented variable CCPATH but it disappeared somehow."
+WARNINGS+= "This package depends on pkgsrc's undocumented variable\
+CCPATH but it disappeared somehow."
 WARNINGS+= "Using hard-coded /usr/bin/gcc as the C compiler..."
 CONFIGURE_ARGS+= --with-gcc=/usr/bin/gcc
 .else
@@ -141,13 +142,21 @@ do-configure:
 # Disable file splitting until pkgsrc gets improved.
 pre-build:
        ${RUN} ${ECHO} "SplitObjs = NO" >> ${WRKSRC}/mk/build.mk
-# We need a work around for powerpc ld bug.
-# See http://hackage.haskell.org/trac/ghc/ticket/3260
+# We have to sacrifice the GHCi library for GHC itself to work around
+# for powerpc ld bug.  See
+# http://hackage.haskell.org/trac/ghc/ticket/3260
 .if ${MACHINE_ARCH} == "powerpc"
+       ${RUN} ${MKDIR} ${WRKSRC}/compiler/stage1/build
        ${RUN} ${TOUCH} ${WRKSRC}/compiler/stage1/build/HS${DISTNAME}.o
+       ${RUN} ${MKDIR} ${WRKSRC}/compiler/stage2/build
        ${RUN} ${TOUCH} ${WRKSRC}/compiler/stage2/build/HS${DISTNAME}.o
 .endif
 
+.if ${MACHINE_ARCH} == "powerpc"
+WARNINGS+= "You won't be able to use GHCi library for GHC itself\
+because of powerpc ld bug."
+.endif
+
 # Some unused scripts don't pass the portability test.
 CHECK_PORTABILITY_SKIP+=       distrib/prep-bin-dist-mingw