summary refs log tree commit diff
path: root/pkgs/development/python-modules
diff options
context:
space:
mode:
authorBert Moens <bert.moens@gmail.com>2017-12-13 21:01:06 +0100
committerBert Moens <bert.moens@gmail.com>2017-12-13 22:01:27 +0100
commit7eb0b20918c8e15dfb7177250df1244a997ae4a2 (patch)
treee8e3fdd69cea1c694f4e9d142a2836910001b9e6 /pkgs/development/python-modules
parent19841b5ba30168c0841422f28e43dcfbde42fd7e (diff)
downloadnixlib-7eb0b20918c8e15dfb7177250df1244a997ae4a2.tar
nixlib-7eb0b20918c8e15dfb7177250df1244a997ae4a2.tar.gz
nixlib-7eb0b20918c8e15dfb7177250df1244a997ae4a2.tar.bz2
nixlib-7eb0b20918c8e15dfb7177250df1244a997ae4a2.tar.lz
nixlib-7eb0b20918c8e15dfb7177250df1244a997ae4a2.tar.xz
nixlib-7eb0b20918c8e15dfb7177250df1244a997ae4a2.tar.zst
nixlib-7eb0b20918c8e15dfb7177250df1244a997ae4a2.zip
wxPython: enable headers
Headers were disabled, probably because they caused a build error: the header files were being
copied to the store path of wxwidgets, but it failed with permission denied. With this commit,
the header files stay in the wxPython store path.
To point the builder of another derivation to the wxPython header files, some tweaking is
needed. E.g. for kicad: cmakeFlags = [ "-DCMAKE_CXX_FLAGS=-I${wxPython}/include/wx-3.0" ]
Diffstat (limited to 'pkgs/development/python-modules')
-rw-r--r--pkgs/development/python-modules/wxPython/3.0.nix5
1 files changed, 4 insertions, 1 deletions
diff --git a/pkgs/development/python-modules/wxPython/3.0.nix b/pkgs/development/python-modules/wxPython/3.0.nix
index ab7b44019c54..abce4cf44e0c 100644
--- a/pkgs/development/python-modules/wxPython/3.0.nix
+++ b/pkgs/development/python-modules/wxPython/3.0.nix
@@ -43,6 +43,9 @@ buildPythonPackage rec {
     # remove wxPython's darwin hack that interference with python-2.7-distutils-C++.patch
     substituteInPlace config.py \
       --replace "distutils.unixccompiler.UnixCCompiler = MyUnixCCompiler" ""
+    # set the WXPREFIX to $out instead of the storepath of wxwidgets
+    substituteInPlace config.py \
+      --replace "WXPREFIX   = getWxConfigValue('--prefix')" "WXPREFIX   = '$out'"
     # this check is supposed to only return false on older systems running non-framework python
     substituteInPlace src/osx_cocoa/_core_wrap.cpp \
       --replace "return wxPyTestDisplayAvailable();" "return true;"
@@ -62,7 +65,7 @@ buildPythonPackage rec {
   buildPhase = "";
 
   installPhase = ''
-    ${python.interpreter} setup.py install WXPORT=${if stdenv.isDarwin then "osx_cocoa" else "gtk2"} NO_HEADERS=1 BUILD_GLCANVAS=${if openglSupport then "1" else "0"} UNICODE=1 --prefix=$out
+    ${python.interpreter} setup.py install WXPORT=${if stdenv.isDarwin then "osx_cocoa" else "gtk2"} NO_HEADERS=0 BUILD_GLCANVAS=${if openglSupport then "1" else "0"} UNICODE=1 --prefix=$out
     wrapPythonPrograms
   '';