Skip to content

Commit

Permalink
talloc: fix cross-compilation to 32-bit platforms
Browse files Browse the repository at this point in the history
  • Loading branch information
lopsided98 authored and FRidh committed Nov 19, 2020
1 parent 11806b6 commit 6501d98
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
14 changes: 10 additions & 4 deletions pkgs/development/libraries/talloc/default.nix
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{ stdenv
, fetchurl
, python
, python3
, pkg-config
, readline
, libxslt
Expand All @@ -10,7 +10,7 @@
, wafHook
}:

stdenv.mkDerivation rec {
stdenv.mkDerivation (rec {
pname = "talloc";
version = "2.3.1";

Expand All @@ -22,13 +22,14 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [
pkg-config
fixDarwinDylibNames
python
python3
wafHook
docbook-xsl-nons
docbook_xml_dtd_42
];

buildInputs = [
python3
readline
libxslt
];
Expand Down Expand Up @@ -56,4 +57,9 @@ stdenv.mkDerivation rec {
license = licenses.gpl3;
platforms = platforms.all;
};
}
} // stdenv.lib.optionalAttrs (stdenv.hostPlatform != stdenv.buildPlatform) {
# python-config from build Python gives incorrect values when cross-compiling.
# If python-config is not found, the build falls back to using the sysconfig
# module, which works correctly when cross-compiling.
PYTHON_CONFIG = "/invalid";
})
4 changes: 1 addition & 3 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -15949,9 +15949,7 @@ in

taglib-sharp = callPackage ../development/libraries/taglib-sharp { };

talloc = callPackage ../development/libraries/talloc {
python = buildPackages.python3;
};
talloc = callPackage ../development/libraries/talloc { };

tclap = callPackage ../development/libraries/tclap {};

Expand Down

0 comments on commit 6501d98

Please sign in to comment.