Merge pull request #66379 from gebner/freecadwrapqt

freecad: use qt wrapper
This commit is contained in:
Gabriel Ebner 2019-08-09 15:29:52 +02:00 committed by GitHub
commit 6be96fbd4a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 9 deletions

View file

@ -1,4 +1,4 @@
{ stdenv, fetchurl, cmake, ninja, coin3d, xercesc, ode, eigen, qt5, opencascade-occt, gts
{ stdenv, mkDerivation, fetchurl, cmake, ninja, coin3d, xercesc, ode, eigen, qt5, opencascade-occt, gts
, hdf5, vtk, medfile, zlib, python3Packages, swig, gfortran, libXmu
, soqt, libf2c, libGLU, makeWrapper, pkgconfig
, mpi ? null }:
@ -7,7 +7,7 @@ assert mpi != null;
let
pythonPackages = python3Packages;
in stdenv.mkDerivation rec {
in mkDerivation rec {
name = "freecad-${version}";
version = "0.18.3";
@ -46,12 +46,13 @@ in stdenv.mkDerivation rec {
# Their main() removes PYTHONPATH=, and we rely on it.
preConfigure = ''
sed '/putenv("PYTHONPATH/d' -i src/Main/MainGui.cpp
qtWrapperArgs+=(--prefix PYTHONPATH : "$PYTHONPATH")
'';
postInstall = ''
wrapProgram $out/bin/FreeCAD --prefix PYTHONPATH : $PYTHONPATH \
--set COIN_GL_NO_CURRENT_CONTEXT_CHECK 1
'';
qtWrapperArgs = [
"--set COIN_GL_NO_CURRENT_CONTEXT_CHECK 1"
];
postFixup = ''
mv $out/share/doc $out
@ -59,9 +60,9 @@ in stdenv.mkDerivation rec {
meta = with stdenv.lib; {
description = "General purpose Open Source 3D CAD/MCAD/CAx/CAE/PLM modeler";
homepage = https://www.freecadweb.org/;
homepage = "https://www.freecadweb.org/";
license = licenses.lgpl2Plus;
maintainers = [ maintainers.viric ];
maintainers = with maintainers; [ viric gebner ];
platforms = platforms.linux;
};
}

View file

@ -18344,7 +18344,7 @@ in
fractal = callPackage ../applications/networking/instant-messengers/fractal { };
freecad = callPackage ../applications/graphics/freecad { mpi = openmpi; };
freecad = qt5.callPackage ../applications/graphics/freecad { mpi = openmpi; };
freemind = callPackage ../applications/misc/freemind { };