talloc, tdb: fix cross-compilation after wafHook improvements
This commit is contained in:
parent
3d60a00c63
commit
cbd9409086
@ -1,6 +1,6 @@
|
|||||||
{ stdenv, fetchurl, python, pkgconfig, readline, libxslt
|
{ stdenv, fetchurl, python, pkgconfig, readline, libxslt
|
||||||
, docbook_xsl, docbook_xml_dtd_42, fixDarwinDylibNames
|
, docbook_xsl, docbook_xml_dtd_42, fixDarwinDylibNames
|
||||||
, buildPackages
|
, wafHook
|
||||||
}:
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
@ -11,23 +11,22 @@ stdenv.mkDerivation rec {
|
|||||||
sha256 = "1kk76dyav41ip7ddbbf04yfydb4jvywzi2ps0z2vla56aqkn11di";
|
sha256 = "1kk76dyav41ip7ddbbf04yfydb4jvywzi2ps0z2vla56aqkn11di";
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ pkgconfig fixDarwinDylibNames python
|
nativeBuildInputs = [ pkgconfig fixDarwinDylibNames python wafHook
|
||||||
docbook_xsl docbook_xml_dtd_42 ];
|
docbook_xsl docbook_xml_dtd_42 ];
|
||||||
buildInputs = [ readline libxslt ];
|
buildInputs = [ readline libxslt ];
|
||||||
|
|
||||||
prePatch = ''
|
wafPath = "buildtools/bin/waf";
|
||||||
patchShebangs buildtools/bin/waf
|
|
||||||
'';
|
|
||||||
|
|
||||||
configureFlags = [
|
configureFlags = [
|
||||||
"--enable-talloc-compat1"
|
"--enable-talloc-compat1"
|
||||||
"--bundled-libraries=NONE"
|
"--bundled-libraries=NONE"
|
||||||
"--builtin-libraries=replace"
|
"--builtin-libraries=replace"
|
||||||
] ++ stdenv.lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
|
|
||||||
"--cross-compile"
|
|
||||||
"--cross-execute=${stdenv.hostPlatform.emulator buildPackages}"
|
|
||||||
];
|
];
|
||||||
configurePlatforms = [];
|
|
||||||
|
# this must not be exported before the ConfigurePhase otherwise waf whines
|
||||||
|
preBuild = stdenv.lib.optionalString stdenv.hostPlatform.isMusl ''
|
||||||
|
export NIX_CFLAGS_LINK="-no-pie -shared";
|
||||||
|
'';
|
||||||
|
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
${stdenv.cc.targetPrefix}ar q $out/lib/libtalloc.a bin/default/talloc_[0-9]*.o
|
${stdenv.cc.targetPrefix}ar q $out/lib/libtalloc.a bin/default/talloc_[0-9]*.o
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{ stdenv, fetchurl, python2, pkgconfig, readline, libxslt
|
{ stdenv, fetchurl, wafHook, pkgconfig, readline, libxslt
|
||||||
, docbook_xsl, docbook_xml_dtd_42, buildPackages
|
, docbook_xsl, docbook_xml_dtd_42
|
||||||
}:
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
@ -10,23 +10,17 @@ stdenv.mkDerivation rec {
|
|||||||
sha256 = "1ibcz466xwk1x6xvzlgzd5va4lyrjzm3rnjak29kkwk7cmhw4gva";
|
sha256 = "1ibcz466xwk1x6xvzlgzd5va4lyrjzm3rnjak29kkwk7cmhw4gva";
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ pkgconfig python2 ];
|
nativeBuildInputs = [ pkgconfig wafHook ];
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
readline libxslt docbook_xsl docbook_xml_dtd_42
|
readline libxslt docbook_xsl docbook_xml_dtd_42
|
||||||
];
|
];
|
||||||
|
|
||||||
preConfigure = ''
|
wafPath = "buildtools/bin/waf";
|
||||||
patchShebangs buildtools/bin/waf
|
|
||||||
'';
|
|
||||||
|
|
||||||
configureFlags = [
|
configureFlags = [
|
||||||
"--bundled-libraries=NONE"
|
"--bundled-libraries=NONE"
|
||||||
"--builtin-libraries=replace"
|
"--builtin-libraries=replace"
|
||||||
] ++ stdenv.lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
|
|
||||||
"--cross-compile"
|
|
||||||
"--cross-execute=${stdenv.hostPlatform.emulator buildPackages}"
|
|
||||||
];
|
];
|
||||||
configurePlatforms = [ ];
|
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
description = "The trivial database";
|
description = "The trivial database";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user