2019-08-19 06:01:55 +00:00
|
|
|
{ lib, mkDerivation, fetchFromGitHub, fetchpatch, qmake
|
2018-08-18 12:44:46 +00:00
|
|
|
, qtbase, qtscript, qtwebkit, qtserialport, qtsvg, qtdeclarative, qtquickcontrols2
|
|
|
|
, alsaLib, libsndfile, flite, openssl, udev, SDL2
|
|
|
|
}:
|
|
|
|
|
2019-08-19 06:01:55 +00:00
|
|
|
mkDerivation rec {
|
|
|
|
pname = "apmplanner2";
|
2020-06-14 11:27:38 +00:00
|
|
|
version = "2.0.28-rc1";
|
2019-08-19 06:01:55 +00:00
|
|
|
|
2018-08-18 12:44:46 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "ArduPilot";
|
|
|
|
repo = "apm_planner";
|
2019-09-08 23:38:31 +00:00
|
|
|
rev = version;
|
2020-06-14 11:27:38 +00:00
|
|
|
sha256 = "18yn8bdz5hmgb0m5hlk8bibz4cj4g25w75pm1rvc4ds0mr1qgyjd";
|
2018-08-18 12:44:46 +00:00
|
|
|
};
|
|
|
|
|
2019-08-19 06:01:55 +00:00
|
|
|
buildInputs = [
|
|
|
|
alsaLib libsndfile flite openssl udev SDL2
|
2018-08-18 12:44:46 +00:00
|
|
|
qtbase qtscript qtwebkit qtserialport qtsvg qtdeclarative qtquickcontrols2
|
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [ qmake ];
|
|
|
|
|
|
|
|
qmakeFlags = [ "apm_planner.pro" ];
|
|
|
|
|
|
|
|
# this ugly hack is necessary, as `bin/apmplanner2` needs the contents of `share/APMPlanner2` inside of `bin/`
|
2018-08-24 22:39:58 +00:00
|
|
|
preFixup = ''
|
|
|
|
ln --relative --symbolic $out/share/APMPlanner2/* $out/bin/
|
|
|
|
substituteInPlace $out/share/applications/apmplanner2.desktop \
|
2020-06-14 11:27:38 +00:00
|
|
|
--replace /usr $out
|
2018-08-24 22:39:58 +00:00
|
|
|
'';
|
2019-08-19 06:01:55 +00:00
|
|
|
|
2018-08-18 12:44:46 +00:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Ground station software for autonomous vehicles";
|
|
|
|
longDescription = ''
|
|
|
|
A GUI ground control station for autonomous vehicles using the MAVLink protocol.
|
|
|
|
Includes support for the APM and PX4 based controllers.
|
|
|
|
'';
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://ardupilot.org/planner2/";
|
2019-08-19 06:01:55 +00:00
|
|
|
license = lib.licenses.gpl3;
|
|
|
|
maintainers = with lib.maintainers; [ wucke13 ];
|
2018-08-18 12:44:46 +00:00
|
|
|
};
|
|
|
|
}
|