1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-22 13:41:26 +00:00

Use variables for ca-bundle.crt and GHCJS_LIBDIR.

This commit is contained in:
Ryan Trinkle 2014-08-25 18:17:18 -04:00
parent a5e6027ece
commit 983af4a921

View file

@ -8,7 +8,7 @@
, regexPosix, alex, happy, git, gnumake, gcc, autoconf, patch
, automake, libtool, cabalInstallGhcjs, gmp, base16Bytestring
, cryptohash, executablePath, transformersCompat
, haddock, hspec, xhtml, primitive
, haddock, hspec, xhtml, primitive, cacert, pkgs, ghc
}:
cabal.mkDerivation (self: rec {
pname = "ghcjs";
@ -79,14 +79,14 @@ cabal.mkDerivation (self: rec {
'';
postInstall = ''
export HOME=$(pwd)
export GIT_SSL_CAINFO=/etc/ssl/certs/ca-bundle.crt
export GIT_SSL_CAINFO="${cacert}/etc/ca-bundle.crt"
git clone git://github.com/ghcjs/ghcjs-boot.git
cd ghcjs-boot
git checkout f9f79d0cf40212943bcc1ad2672f2e0a7af2b7c9
git submodule update --init --recursive
( cd boot ; chmod u+w . ; ln -s .. ghcjs-boot )
chmod -R u+w . # because fetchgit made it read-only
local GHCJS_LIBDIR=$out/share/ghcjs/x86_64-linux-0.1.0-7.8.2
local GHCJS_LIBDIR=$out/share/ghcjs/${pkgs.stdenv.system}-${version}-${ghc.ghc.version}
ensureDir $GHCJS_LIBDIR
cp -R ${shims} $GHCJS_LIBDIR/shims
${cabalInstallGhcjs}/bin/cabal-js update