34 src = fetchFromGitHub {
35 owner = "cnr-isti-vclab";
37 rev = "MeshLab-${version}";
38 sha256 = "sha256-AdUAWS741RQclYaSE3Tz1/I0YSinNAnfSaqef+Tib8Y=";
67 nativeBuildInputs = [ cmake ];
70 substituteAll ${./meshlab.desktop} resources/linux/meshlab.desktop
71 substituteInPlace src/external/libigl.cmake \
72 --replace-fail '$'{MESHLAB_EXTERNAL_DOWNLOAD_DIR}/libigl-2.4.0 ${libigl}
73 substituteInPlace src/external/nexus.cmake \
74 --replace-fail '$'{NEXUS_DIR}/src/corto ${corto.src}
75 substituteInPlace src/external/levmar.cmake \
76 --replace-fail '$'{LEVMAR_LINK} ${levmar.src} \
77 --replace-warn "MD5 ''${LEVMAR_MD5}" ""
78 substituteInPlace src/external/ssynth.cmake \
79 --replace-fail '$'{SSYNTH_LINK} ${structuresynth.src} \
80 --replace-warn "MD5 ''${SSYNTH_MD5}" ""
81 substituteInPlace src/common_gui/CMakeLists.txt \
82 --replace-warn "MESHLAB_LIB_INSTALL_DIR" "CMAKE_INSTALL_LIBDIR"
90 patchelf --add-needed $out/lib/meshlab/libmeshlab-common.so $out/bin/.meshlab-wrapped
94 description = "System for processing and editing 3D triangular meshes";
95 mainProgram = "meshlab";
96 homepage = "https://www.meshlab.net/";
97 license = lib.licenses.gpl3Only;
99 platforms = with lib.platforms; linux;