1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-12-25 03:17:13 +00:00
nixpkgs/pkgs/development/python-modules/pyftgl/default.nix
Maximilian Bosch 5ad7aedf63 pythonPackages.pyftgl: fix build (#47232)
See https://hydra.nixos.org/build/80705583

Recent `boost` versions with `python` enabled have changed their naming
scheme for `boost_python` shared objects which causes issues with the
proper linking when building `pyftgl`.

Previously the library was named `boost_python3`, no it's named
`boost_python36` for current python (3.6.x).

The same issue applies for the `python2`.

Addresses #45960
2018-09-23 22:39:21 +02:00

35 lines
744 B
Nix

{ lib, buildPythonPackage, fetchFromGitHub, isPy3k
, boost, freetype, ftgl, libGLU_combined
, python
}:
let
pythonVersion = with lib.versions; "${major python.version}${minor python.version}";
in
buildPythonPackage rec {
pname = "pyftgl";
version = "0.4b";
name = pname + "-" + version;
src = fetchFromGitHub {
owner = "umlaeute";
repo = name;
rev = version;
sha256 = "12zcjv4cwwjihiaf74kslrdmmk4bs47h7006gyqfwdfchfjdgg4r";
};
postPatch = ''
sed -i "s,'boost_python','boost_python${pythonVersion}',g" setup.py
'';
buildInputs = [ boost freetype ftgl libGLU_combined ];
meta = with lib; {
description = "Python bindings for FTGL (FreeType for OpenGL)";
license = licenses.gpl2Plus;
};
}