openipmi: fix cross compilation
(cherry picked from commit 6f8fa26d6f6ebdcf51964ddcbf33e160f8d8436d)
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
{
|
||||
stdenv,
|
||||
buildPackages,
|
||||
fetchurl,
|
||||
popt,
|
||||
ncurses,
|
||||
@@ -18,6 +19,17 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "sha256-xi049dp99Cmaw6ZSUI6VlTd1JEAYHjTHayrs69fzAbk=";
|
||||
};
|
||||
|
||||
postConfigure = lib.optionalString (!stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
|
||||
substituteInPlace lanserv/Makefile \
|
||||
--replace-fail "sdrcomp/sdrcomp_build -o" "${buildPackages.openipmi}/bin/sdrcomp -o"
|
||||
'';
|
||||
|
||||
strictDeps = true;
|
||||
|
||||
nativeBuildInputs = [
|
||||
python3
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
ncurses
|
||||
popt
|
||||
@@ -26,6 +38,10 @@ stdenv.mkDerivation rec {
|
||||
openssl
|
||||
];
|
||||
|
||||
makeFlags = [
|
||||
"BUILD_CC=${stdenv.cc.targetPrefix}cc"
|
||||
];
|
||||
|
||||
outputs = [
|
||||
"out"
|
||||
"lib"
|
||||
|
||||
Reference in New Issue
Block a user