blob: 36051cc2e12e7d78b9451ed6e39d706706b9b4ed (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
{ stdenv, fetchurl, pkgconfig, python, isPy3k, isPyPy, wxGTK, openglSupport ? true, pyopengl
, version, sha256, wrapPython, setuptools, ...
}:
assert wxGTK.unicode;
stdenv.mkDerivation rec {
name = "wxPython-${version}";
inherit version;
disabled = isPy3k || isPyPy;
doCheck = false;
sourceRoot = "wxPython-src-${version}/wxPython";
hardeningDisable = [ "format" ];
src = fetchurl {
url = "mirror://sourceforge/wxpython/wxPython-src-${version}.tar.bz2";
inherit sha256;
};
pythonPath = [ python setuptools ];
buildInputs = [ python setuptools pkgconfig wxGTK (wxGTK.gtk) wrapPython ] ++ stdenv.lib.optional openglSupport pyopengl;
installPhase = ''
${python.interpreter} setup.py install WXPORT=gtk2 NO_HEADERS=1 BUILD_GLCANVAS=${if openglSupport then "1" else "0"} UNICODE=1 --prefix=$out
wrapPythonPrograms
'';
passthru = { inherit wxGTK openglSupport; };
}
|