2011-03-03 14:41:10 +01:00
|
|
|
{ fetchsvn, stdenv, cmake, coin3d, xercesc, ode, eigen, qt4, opencascade, gts,
|
2011-03-02 18:18:30 +01:00
|
|
|
boost, zlib,
|
2011-03-04 10:48:33 +01:00
|
|
|
python, swig, gfortran, soqt, libf2c, pyqt4 }:
|
2011-03-02 18:18:30 +01:00
|
|
|
|
2011-03-03 14:41:10 +01:00
|
|
|
# It builds but fails to install
|
2011-03-02 18:18:30 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "freecad-${version}";
|
2011-03-03 14:41:10 +01:00
|
|
|
version = "svn-${src.rev}";
|
2011-03-02 18:18:30 +01:00
|
|
|
|
2011-03-03 14:41:10 +01:00
|
|
|
src = fetchsvn {
|
|
|
|
url = https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk;
|
|
|
|
rev = "4184";
|
|
|
|
sha256 = "26bd8407ce38f070b81ef39145aed093eed3c200d165a605b8169162d66568ce";
|
2011-03-02 18:18:30 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ cmake coin3d xercesc ode eigen qt4 opencascade gts boost
|
2011-03-04 10:48:33 +01:00
|
|
|
zlib python swig gfortran soqt libf2c pyqt ];
|
2011-03-02 18:18:30 +01:00
|
|
|
|
2011-03-03 14:41:10 +01:00
|
|
|
enableParallelBuilding = true;
|
2011-03-02 18:18:30 +01:00
|
|
|
|
2011-03-03 14:41:10 +01:00
|
|
|
# They are used to boost 1.42, and we have newer boost that require
|
|
|
|
# this for freecad to build
|
|
|
|
NIX_CFLAGS_COMPILE = "-DBOOST_FILESYSTEM_VERSION=2";
|
2011-03-02 18:18:30 +01:00
|
|
|
|
2011-03-04 10:48:33 +01:00
|
|
|
# This will help only x86_64, but will not hurt on others.
|
|
|
|
preBuild = ''
|
|
|
|
export NIX_LDFLAGS="-L${gfortran.gcc}/lib64 $NIX_LDFLAGS";
|
|
|
|
'';
|
|
|
|
|
2011-03-04 10:48:24 +01:00
|
|
|
patches = [ ./cmakeinstall.patch ];
|
|
|
|
|
2011-03-03 14:41:10 +01:00
|
|
|
meta = {
|
|
|
|
homepage = http://free-cad.sourceforge.net/;
|
|
|
|
license = [ "GPLv2+" "LGPLv2+" ];
|
|
|
|
description = "General purpose Open Source 3D CAD/MCAD/CAx/CAE/PLM modeler";
|
2011-03-04 10:48:33 +01:00
|
|
|
maintainers = with stdenv.lib.maintainers; [viric];
|
|
|
|
platforms = with stdenv.lib.platforms; linux;
|
2011-03-03 14:41:10 +01:00
|
|
|
};
|
2011-03-02 18:18:30 +01:00
|
|
|
}
|