ghc, haskell-modules: ARM cross build fixes.

As requested in #33405.

authored by Drew Hess and committed by John Ericson e4f3fe05 888404f1

+5 -5
+1 -1
pkgs/development/compilers/ghc/7.10.3-binary.nix
··· 43 or (throw "cannot bootstrap GHC on this platform")); 44 45 nativeBuildInputs = [ perl ]; 46 - buildInputs = stdenv.lib.optionals stdenv.isArm [ llvm_35 ]; 47 48 # Cannot patchelf beforehand due to relative RPATHs that anticipate 49 # the final install location/
··· 43 or (throw "cannot bootstrap GHC on this platform")); 44 45 nativeBuildInputs = [ perl ]; 46 + buildInputs = stdenv.lib.optionals stdenv.targetPlatform.isArm [ llvm_35 ]; 47 48 # Cannot patchelf beforehand due to relative RPATHs that anticipate 49 # the final install location/
+1 -1
pkgs/development/compilers/ghc/7.10.3.nix
··· 44 ./relocation.patch 45 ]; 46 47 - buildInputs = [ ghc perl libxml2 libxslt docbook_xsl docbook_xml_dtd_45 docbook_xml_dtd_42 hscolour ] ++ stdenv.lib.optionals stdenv.isArm [ llvm_35 ]; 48 49 enableParallelBuilding = true; 50
··· 44 ./relocation.patch 45 ]; 46 47 + buildInputs = [ ghc perl libxml2 libxslt docbook_xsl docbook_xml_dtd_45 docbook_xml_dtd_42 hscolour ] ++ stdenv.lib.optionals targetPlatform.isArm [ llvm_35 ]; 48 49 enableParallelBuilding = true; 50
+1 -1
pkgs/development/compilers/ghc/8.2.1-binary.nix
··· 46 or (throw "cannot bootstrap GHC on this platform")); 47 48 nativeBuildInputs = [ perl ]; 49 - buildInputs = stdenv.lib.optionals (stdenv.isArm || stdenv.isAarch64) [ llvm_39 ]; 50 51 # Cannot patchelf beforehand due to relative RPATHs that anticipate 52 # the final install location/
··· 46 or (throw "cannot bootstrap GHC on this platform")); 47 48 nativeBuildInputs = [ perl ]; 49 + buildInputs = stdenv.lib.optionals (stdenv.targetPlatform.isArm || stdenv.targetPlatform.isAarch64) [ llvm_39 ]; 50 51 # Cannot patchelf beforehand due to relative RPATHs that anticipate 52 # the final install location/
+1 -1
pkgs/development/compilers/ghc/8.2.2.nix
··· 46 sed 's|#BuildFlavour = quick-cross|BuildFlavour = perf-cross|' mk/build.mk.sample > mk/build.mk 47 ''; 48 49 - buildInputs = [ alex autoconf automake ghc happy hscolour perl python3 sphinx ] ++ stdenv.lib.optionals (stdenv.isArm || stdenv.isAarch64) [ llvm_39 ]; 50 51 enableParallelBuilding = true; 52
··· 46 sed 's|#BuildFlavour = quick-cross|BuildFlavour = perf-cross|' mk/build.mk.sample > mk/build.mk 47 ''; 48 49 + buildInputs = [ alex autoconf automake ghc happy hscolour perl python3 sphinx ] ++ stdenv.lib.optionals (targetPlatform.isArm || targetPlatform.isAarch64) [ llvm_39 ]; 50 51 enableParallelBuilding = true; 52
+1 -1
pkgs/development/haskell-modules/generic-builder.nix
··· 130 (optionalString (enableSharedExecutables && stdenv.isDarwin) "--ghc-option=-optl=-Wl,-headerpad_max_install_names") 131 (optionalString enableParallelBuilding "--ghc-option=-j$NIX_BUILD_CORES") 132 (optionalString useCpphs "--with-cpphs=${cpphs}/bin/cpphs --ghc-options=-cpp --ghc-options=-pgmP${cpphs}/bin/cpphs --ghc-options=-optP--cpp") 133 - (enableFeature (enableDeadCodeElimination && !stdenv.isArm && !stdenv.isAarch64 && (versionAtLeast "8.0.1" ghc.version)) "split-objs") 134 (enableFeature enableLibraryProfiling "library-profiling") 135 (enableFeature enableExecutableProfiling (if versionOlder ghc.version "8" then "executable-profiling" else "profiling")) 136 (enableFeature enableSharedLibraries "shared")
··· 130 (optionalString (enableSharedExecutables && stdenv.isDarwin) "--ghc-option=-optl=-Wl,-headerpad_max_install_names") 131 (optionalString enableParallelBuilding "--ghc-option=-j$NIX_BUILD_CORES") 132 (optionalString useCpphs "--with-cpphs=${cpphs}/bin/cpphs --ghc-options=-cpp --ghc-options=-pgmP${cpphs}/bin/cpphs --ghc-options=-optP--cpp") 133 + (enableFeature (enableDeadCodeElimination && !hostPlatform.isArm && !hostPlatform.isAarch64 && (versionAtLeast "8.0.1" ghc.version)) "split-objs") 134 (enableFeature enableLibraryProfiling "library-profiling") 135 (enableFeature enableExecutableProfiling (if versionOlder ghc.version "8" then "executable-profiling" else "profiling")) 136 (enableFeature enableSharedLibraries "shared")