factor-lang: Update derivation and build with clang
parent
d5adb9f392
commit
d579a46c16
|
@ -31,7 +31,7 @@ let
|
||||||
# l3pp = callPackage ./l3pp { };
|
# l3pp = callPackage ./l3pp { };
|
||||||
# mathsat = callPackage ./mathsat { };
|
# mathsat = callPackage ./mathsat { };
|
||||||
|
|
||||||
factor-lang = callPackage ./factor-lang/scope.nix { };
|
factor-lang = callPackage ./factor-lang/scope.nix { stdenv = prev.clangStdenv; };
|
||||||
|
|
||||||
foxitreader = callPackage ./foxitreader.nix { openssl = prev.openssl_1_0_2; };
|
foxitreader = callPackage ./foxitreader.nix { openssl = prev.openssl_1_0_2; };
|
||||||
|
|
||||||
|
|
|
@ -75,34 +75,14 @@ stdenv.mkDerivation rec {
|
||||||
|
|
||||||
configurePhase = "true";
|
configurePhase = "true";
|
||||||
|
|
||||||
|
LD_LIBRARY_PATH = "/run/opengl-driver/lib:${runtimeLibPath}";
|
||||||
buildPhase = ''
|
buildPhase = ''
|
||||||
make linux-x86-64
|
patchShebangs ./build.sh
|
||||||
|
|
||||||
# Factor uses XDG_CACHE_HOME for cache during compilation.
|
# Factor uses XDG_CACHE_HOME for cache during compilation.
|
||||||
# We can't have that. So set it to $TMPDIR/.cache
|
# We can't have that. So, set it to $TMPDIR/.cache
|
||||||
export XDG_CACHE_HOME=$TMPDIR/.cache && mkdir -p $XDG_CACHE_HOME
|
export XDG_CACHE_HOME=$TMPDIR/.cache && mkdir -p $XDG_CACHE_HOME
|
||||||
|
./build.sh compile
|
||||||
# The released image has library path info embedded, so we
|
./build.sh bootstrap
|
||||||
# first have to recreate the boot image with Nix paths, and
|
|
||||||
# then use it to build the Nix release image.
|
|
||||||
cp boot.unix-x86.64.image factor.image
|
|
||||||
|
|
||||||
# Expose libraries in LD_LIBRARY_PATH for factor
|
|
||||||
export LD_LIBRARY_PATH=${lib.makeLibraryPath runtimeLibs}:$LD_LIBRARY_PATH
|
|
||||||
|
|
||||||
echo "=== Building first full image from boot image..."
|
|
||||||
|
|
||||||
# build full factor image from boot image, saving the state for the next call
|
|
||||||
./factor -script -e='"unix-x86.64" USING: system bootstrap.image memory ; make-image save 0 exit'
|
|
||||||
|
|
||||||
echo "=== Building new boot image..."
|
|
||||||
# make a new bootstrap image
|
|
||||||
./factor -script -e='"unix-x86.64" USING: system bootstrap.image ; make-image 0 exit'
|
|
||||||
|
|
||||||
echo "=== Building final full image..."
|
|
||||||
# rebuild final full factor image to include all patched sources
|
|
||||||
./factor -i=boot.unix-x86.64.image
|
|
||||||
|
|
||||||
'';
|
'';
|
||||||
|
|
||||||
doCheck = true;
|
doCheck = true;
|
||||||
|
|
|
@ -6,7 +6,7 @@ let
|
||||||
let callPackage = pkgs.newScope self ;
|
let callPackage = pkgs.newScope self ;
|
||||||
in rec {
|
in rec {
|
||||||
recurseForDerivations = true;
|
recurseForDerivations = true;
|
||||||
interpreter = callPackage ./default.nix { inherit (gnome2) gtkglext; };
|
interpreter = callPackage ./default.nix { inherit (gnome2) gtkglext; inherit stdenv; };
|
||||||
|
|
||||||
# Convenience access for using the returned attribute the same way as the interpreter derivation
|
# Convenience access for using the returned attribute the same way as the interpreter derivation
|
||||||
withLibs = self.interpreter.withLibs;
|
withLibs = self.interpreter.withLibs;
|
||||||
|
|
Loading…
Reference in New Issue