Skip to content

Commit

Permalink
python3Packages.py3exiv2: fix build
Browse files Browse the repository at this point in the history
Recent boost versions name their `python3` shared objects
`boost_python3x` rather than `boost_python3`.

See https://hydra.nixos.org/build/80712295
Addresses #45960

(cherry picked from commit 50f23da)
  • Loading branch information
Ma27 authored and Mic92 committed Sep 24, 2018
1 parent ea48d53 commit 20d144b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
9 changes: 7 additions & 2 deletions pkgs/development/python-modules/py3exiv2/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ buildPythonPackage, isPy3k, fetchPypi, stdenv, exiv2, boost, libcxx }:
{ buildPythonPackage, isPy3k, fetchPypi, stdenv, exiv2, boost, libcxx, substituteAll, python }:

buildPythonPackage rec {
pname = "py3exiv2";
Expand All @@ -16,7 +16,12 @@ buildPythonPackage rec {
NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.isDarwin "-I${libcxx}/include/c++/v1";

# fix broken libboost_python3 detection
patches = [ ./setup.patch ];
patches = [
(substituteAll {
src = ./setup.patch;
version = "3${stdenv.lib.versions.minor python.version}";
})
];

meta = {
homepage = "https://launchpad.net/py3exiv2";
Expand Down
2 changes: 1 addition & 1 deletion pkgs/development/python-modules/py3exiv2/setup.patch
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
return l.replace('libboost', 'boost')

-libboost = get_libboost_name()
+libboost = 'boost_python3'
+libboost = 'boost_python@version@'

setup(
name='py3exiv2',

0 comments on commit 20d144b

Please sign in to comment.