3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/applications/graphics/leocad/default.nix

54 lines
1.1 KiB
Nix
Raw Normal View History

2021-03-15 10:05:35 +00:00
{ lib
, mkDerivation
, fetchFromGitHub
, fetchurl
, qmake
, qttools
, zlib
}:
2015-01-23 05:39:39 +00:00
/*
To use aditional parts libraries
set the variable LEOCAD_LIB=/path/to/libs/ or use option -l /path/to/libs/
*/
2021-03-15 10:05:35 +00:00
let
parts = fetchurl {
url = "https://web.archive.org/web/20190715142541/https://www.ldraw.org/library/updates/complete.zip";
sha256 = "sha256-PW3XCbFwRaNkx4EgCnl2rXH7QgmpNgjTi17kZ5bladA=";
};
2015-01-23 05:39:39 +00:00
2021-03-15 10:05:35 +00:00
in
mkDerivation rec {
pname = "leocad";
2021-03-15 10:05:35 +00:00
version = "21.03";
2015-01-23 05:39:39 +00:00
2017-03-19 00:32:30 +00:00
src = fetchFromGitHub {
owner = "leozide";
repo = "leocad";
rev = "v${version}";
2021-03-15 10:05:35 +00:00
sha256 = "sha256-69Ocfk5dBXwcRqAZWEP9Xg41o/tAQo76dIOk9oYhCUE=";
2015-01-23 05:39:39 +00:00
};
2021-03-15 10:05:35 +00:00
nativeBuildInputs = [ qmake qttools ];
buildInputs = [ zlib ];
qmakeFlags = [
"INSTALL_PREFIX=${placeholder "out"}"
"DISABLE_UPDATE_CHECK=1"
];
qtWrapperArgs = [
"--set-default LEOCAD_LIB ${parts}"
];
2015-01-23 05:39:39 +00:00
meta = with lib; {
2015-01-23 05:39:39 +00:00
description = "CAD program for creating virtual LEGO models";
homepage = "https://www.leocad.org/";
2021-03-15 10:05:35 +00:00
license = licenses.gpl2Only;
maintainers = with maintainers; [ peterhoeg ];
platforms = platforms.linux;
2015-01-23 05:39:39 +00:00
};
}