Trying to make freecad find pyqt. This required a patch to be able to use PYTHONPATH.

svn path=/nixpkgs/trunk/; revision=26169
This commit is contained in:
Lluís Batlle i Rossell 2011-03-05 22:27:51 +00:00
parent 6b10954921
commit 69a67fc7cf
2 changed files with 27 additions and 3 deletions

View File

@ -1,6 +1,6 @@
{ fetchsvn, stdenv, cmake, coin3d, xercesc, ode, eigen, qt4, opencascade, gts,
boost, zlib,
python, swig, gfortran, soqt, libf2c }:
python, swig, gfortran, soqt, libf2c, pyqt4, makeWrapper }:
# It builds but fails to install
@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
};
buildInputs = [ cmake coin3d xercesc ode eigen qt4 opencascade gts boost
zlib python swig gfortran soqt libf2c ];
zlib python swig gfortran soqt libf2c pyqt4 makeWrapper ];
enableParallelBuilding = true;
@ -28,7 +28,12 @@ stdenv.mkDerivation rec {
export NIX_LDFLAGS="-L${gfortran.gcc}/lib64 $NIX_LDFLAGS";
'';
patches = [ ./cmakeinstall.patch ];
postInstall = ''
wrapProgram $out/bin/FreeCAD --prefix PYTHONPATH : $PYTHONPATH \
--set COIN_GL_NO_CURRENT_CONTEXT_CHECK 1
'';
patches = [ ./cmakeinstall.patch ./pythonpath.patch ];
meta = {
homepage = http://free-cad.sourceforge.net/;

View File

@ -0,0 +1,19 @@
http://sourceforge.net/apps/phpbb/free-cad/viewtopic.php?f=4&t=847&p=6364
Index: src/Main/MainGui.cpp
===================================================================
--- a/src/Main/MainGui.cpp (revision 4193)
+++ a/src/Main/MainGui.cpp (working copy)
@@ -149,10 +149,10 @@
// http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=559846
putenv("LANG=C");
putenv("LC_ALL=C");
- putenv("PYTHONPATH=");
+ //putenv("PYTHONPATH=");
#else
setlocale(LC_NUMERIC, "C");
- _putenv("PYTHONPATH=");
+ //_putenv("PYTHONPATH=");
#endif
// Name and Version of the Application