46 lines
1.2 KiB
Nix
46 lines
1.2 KiB
Nix
{stdenv, fetchurl, mesa, tcl, tk, file, libXmu, cmake, qt4, freetype}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
name = "opencascade-6.6.0";
|
|
src = fetchurl {
|
|
url = http://files.opencascade.com/OCCT/OCC_6.6.0_release/OpenCASCADE660.tgz;
|
|
sha256 = "0q2xn915w9skv9sj74lxnyv9g3b0yi1j04majyzxk6sv4nra97z3";
|
|
};
|
|
|
|
buildInputs = [ cmake mesa tcl tk file libXmu qt4 freetype ];
|
|
|
|
sourceRoot = "ros/adm/cmake";
|
|
|
|
cmakeFlags = [
|
|
"-D3RDPARTY_TCL_DIR=${tcl}"
|
|
"-D3RDPARTY_FREETYPE_DIR=${freetype.dev}"
|
|
|
|
# Not used on Linux but must be defined during configuration.
|
|
"-D3RDPARTY_FREETYPE_DLL=${freetype.dev}"
|
|
];
|
|
|
|
# https://bugs.freedesktop.org/show_bug.cgi?id=83631
|
|
NIX_CFLAGS_COMPILE = "-DGLX_GLXEXT_LEGACY";
|
|
|
|
hardeningDisable = [ "format" ];
|
|
|
|
preConfigure = ''
|
|
cmakeFlags="$cmakeFlags -DINSTALL_DIR=$out"
|
|
'';
|
|
|
|
postInstall = ''
|
|
mv $out/inc $out/include
|
|
mkdir -p $out/share/doc/${name}
|
|
cp -R ../../../doc $out/share/doc/${name}
|
|
'';
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
meta = {
|
|
description = "Open CASCADE Technology, libraries for 3D modeling and numerical simulation";
|
|
homepage = http://www.opencascade.org/;
|
|
maintainers = with stdenv.lib.maintainers; [viric];
|
|
platforms = with stdenv.lib.platforms; linux;
|
|
};
|
|
}
|