Move genodeBase libraries to $out/lib
This commit is contained in:
parent
fddd605d5c
commit
5063468f3d
|
@ -175,8 +175,9 @@ let
|
||||||
# The actual ld.lib.so is kernel specific
|
# The actual ld.lib.so is kernel specific
|
||||||
# so ship the stubbed library for linking
|
# so ship the stubbed library for linking
|
||||||
''
|
''
|
||||||
cp $BUILD_DIR/var/libcache/ld/ld.abi.so $out/ld.lib.so
|
mkdir -p $out/include $out/lib
|
||||||
mkdir -p $out/include
|
mv $out/*.lib.so $out/lib/
|
||||||
|
cp $BUILD_DIR/var/libcache/ld/ld.abi.so $out/lib/ld.lib.so
|
||||||
cp -r --no-preserve=mode \
|
cp -r --no-preserve=mode \
|
||||||
$GENODE_DIR/repos/base/include/* \
|
$GENODE_DIR/repos/base/include/* \
|
||||||
$GENODE_DIR/repos/os/include/* \
|
$GENODE_DIR/repos/os/include/* \
|
||||||
|
|
|
@ -111,9 +111,9 @@ let
|
||||||
echo "-fno-exceptions" >> $out/nix-support/cc-cflags
|
echo "-fno-exceptions" >> $out/nix-support/cc-cflags
|
||||||
'' + mkExtraBuildCommands cc
|
'' + mkExtraBuildCommands cc
|
||||||
+ stdenv.lib.optionalString stdenv.targetPlatform.isGenode ''
|
+ stdenv.lib.optionalString stdenv.targetPlatform.isGenode ''
|
||||||
echo "-I${genodeBase}/include" >> $out/nix-support/cc-cflags
|
|
||||||
echo "--sysroot=${genodeBase}" >> $out/nix-support/cc-cflags
|
echo "--sysroot=${genodeBase}" >> $out/nix-support/cc-cflags
|
||||||
echo "-L ${genodeBase}" >> $out/nix-support/cc-cflags
|
echo "-isystem=${genodeBase}/include" >> $out/nix-support/cc-cflags
|
||||||
|
echo "-L ${genodeBase}/lib" >> $out/nix-support/cc-cflags
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -134,7 +134,8 @@ let
|
||||||
'' + mkExtraBuildCommands cc
|
'' + mkExtraBuildCommands cc
|
||||||
+ stdenv.lib.optionalString stdenv.targetPlatform.isGenode ''
|
+ stdenv.lib.optionalString stdenv.targetPlatform.isGenode ''
|
||||||
echo "--sysroot=${genodeBase}" >> $out/nix-support/cc-cflags
|
echo "--sysroot=${genodeBase}" >> $out/nix-support/cc-cflags
|
||||||
echo "-L ${genodeBase}" >> $out/nix-support/cc-cflags
|
echo "-isystem=${genodeBase}/include" >> $out/nix-support/cc-cflags
|
||||||
|
echo "-L ${genodeBase}/lib" >> $out/nix-support/cc-cflags
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -154,6 +155,8 @@ let
|
||||||
echo "-B${targetLlvmLibraries.compiler-rt}/lib" >> $out/nix-support/cc-cflags
|
echo "-B${targetLlvmLibraries.compiler-rt}/lib" >> $out/nix-support/cc-cflags
|
||||||
'' + mkExtraBuildCommands cc + stdenv.lib.optionalString stdenv.targetPlatform.isGenode ''
|
'' + mkExtraBuildCommands cc + stdenv.lib.optionalString stdenv.targetPlatform.isGenode ''
|
||||||
echo "--sysroot=${genodeBase}" >> $out/nix-support/cc-cflags
|
echo "--sysroot=${genodeBase}" >> $out/nix-support/cc-cflags
|
||||||
|
echo "-isystem=${genodeBase}/include" >> $out/nix-support/cc-cflags
|
||||||
|
echo "-L ${genodeBase}/lib" >> $out/nix-support/cc-cflags
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -168,6 +171,10 @@ let
|
||||||
extraBuildCommands = ''
|
extraBuildCommands = ''
|
||||||
echo "-nostartfiles" >> $out/nix-support/cc-cflags
|
echo "-nostartfiles" >> $out/nix-support/cc-cflags
|
||||||
echo "-target ${stdenv.targetPlatform.config}" >> $out/nix-support/cc-cflags
|
echo "-target ${stdenv.targetPlatform.config}" >> $out/nix-support/cc-cflags
|
||||||
|
'' + stdenv.lib.optionalString stdenv.targetPlatform.isGenode ''
|
||||||
|
echo "--sysroot=${genodeBase}" >> $out/nix-support/cc-cflags
|
||||||
|
echo "-isystem=${genodeBase}/include" >> $out/nix-support/cc-cflags
|
||||||
|
echo "-L ${genodeBase}/lib" >> $out/nix-support/cc-cflags
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -205,7 +212,10 @@ let
|
||||||
|
|
||||||
openmp = callPackage ./openmp.nix {};
|
openmp = callPackage ./openmp.nix {};
|
||||||
|
|
||||||
libunwind = callPackage ./libunwind.nix ({} //
|
libunwind = if stdenv.targetPlatform.isGenode then
|
||||||
|
null
|
||||||
|
else
|
||||||
|
callPackage ./libunwind.nix ({} //
|
||||||
(stdenv.lib.optionalAttrs (stdenv.hostPlatform.useLLVM or false) {
|
(stdenv.lib.optionalAttrs (stdenv.hostPlatform.useLLVM or false) {
|
||||||
stdenv = overrideCC stdenv buildLlvmTools.lldClangNoLibcxx;
|
stdenv = overrideCC stdenv buildLlvmTools.lldClangNoLibcxx;
|
||||||
}));
|
}));
|
||||||
|
|
|
@ -26,6 +26,7 @@ let
|
||||||
|
|
||||||
in rec {
|
in rec {
|
||||||
inherit stdenv genodeSources;
|
inherit stdenv genodeSources;
|
||||||
|
inherit (nixpkgs) genodeBase;
|
||||||
|
|
||||||
base-hw-pc = buildUpstream {
|
base-hw-pc = buildUpstream {
|
||||||
name = "base-hw-pc";
|
name = "base-hw-pc";
|
||||||
|
|
Loading…
Reference in New Issue