nixpkgs/pkgs/applications/graphics/antimony/default.nix

53 lines
1.3 KiB
Nix
Raw Normal View History

2018-09-10 22:17:00 +02:00
{ stdenv, fetchFromGitHub, libpng, python3
, libGLU_combined, qtbase, ncurses
, cmake, flex, lemon
}:
2015-05-31 21:18:17 +02:00
let
2018-09-10 22:17:00 +02:00
gitRev = "60a58688e552f12501980c4bdab034ab0f2ba059";
gitBranch = "develop";
2018-02-06 16:01:01 +01:00
gitTag = "0.9.3";
in
2015-05-31 21:18:17 +02:00
stdenv.mkDerivation rec {
name = "antimony-${version}";
2018-09-10 22:17:00 +02:00
version = "2018-07-17";
2015-05-31 21:18:17 +02:00
2016-07-09 12:14:04 +02:00
src = fetchFromGitHub {
2018-09-10 22:17:00 +02:00
owner = "mkeeter";
repo = "antimony";
rev = gitRev;
sha256 = "0pgf6kr23xw012xsil56j5gq78mlirmrlqdm09m5wlgcf4vr6xnl";
2015-05-31 21:18:17 +02:00
};
patches = [ ./paths-fix.patch ];
2016-07-09 12:14:04 +02:00
postPatch = ''
2018-09-10 22:17:00 +02:00
sed -i "s,/usr/local,$out,g" \
app/CMakeLists.txt app/app/app.cpp app/app/main.cpp
sed -i "s,python3,${python3.executable}," CMakeLists.txt
'';
2015-05-31 21:18:17 +02:00
buildInputs = [
2018-09-10 22:17:00 +02:00
libpng python3 python3.pkgs.boost
libGLU_combined qtbase ncurses
2015-05-31 21:18:17 +02:00
];
2016-07-09 12:14:04 +02:00
nativeBuildInputs = [ cmake flex lemon ];
2015-05-31 21:18:17 +02:00
2016-07-09 12:14:04 +02:00
cmakeFlags= [
"-DGITREV=${gitRev}"
"-DGITTAG=${gitTag}"
"-DGITBRANCH=${gitBranch}"
];
2015-05-31 21:18:17 +02:00
enableParallelBuilding = true;
2015-05-31 21:18:17 +02:00
meta = with stdenv.lib; {
description = "A computer-aided design (CAD) tool from a parallel universe";
homepage = "https://github.com/mkeeter/antimony";
license = licenses.mit;
2018-09-10 22:17:00 +02:00
maintainers = with maintainers; [ rnhmjoj ];
2015-05-31 21:18:17 +02:00
platforms = platforms.linux;
};
}