2016-08-26 08:57:14 -07:00
|
|
|
{ stdenv, fetchFromGitHub, cmake, pkgconfig, boost, gnuradio
|
2020-10-05 02:04:49 -07:00
|
|
|
, makeWrapper, cppunit, gr-osmosdr, log4cpp
|
2016-08-26 08:57:14 -07:00
|
|
|
, pythonSupport ? true, python, swig
|
|
|
|
}:
|
|
|
|
|
|
|
|
assert pythonSupport -> python != null && swig != null;
|
|
|
|
|
2019-08-13 14:52:01 -07:00
|
|
|
stdenv.mkDerivation {
|
2019-08-15 05:41:18 -07:00
|
|
|
pname = "gr-ais";
|
2017-07-14 17:01:49 -07:00
|
|
|
version = "2015-12-20";
|
2016-08-26 08:57:14 -07:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "bistromath";
|
|
|
|
repo = "gr-ais";
|
2017-07-14 17:01:49 -07:00
|
|
|
# Upstream PR: https://github.com/bistromath/gr-ais/commit/8502d0252a2a1a9b8d1a71795eaeb5d820684054
|
2019-08-13 14:52:01 -07:00
|
|
|
rev = "8502d0252a2a1a9b8d1a71795eaeb5d820684054";
|
|
|
|
sha256 = "1b9j0kc74cw12a7jv4lii77dgzqzg2s8ndzp4xmisxksgva1qfvh";
|
2016-08-26 08:57:14 -07:00
|
|
|
};
|
|
|
|
|
2017-09-14 12:24:37 -07:00
|
|
|
nativeBuildInputs = [ pkgconfig ];
|
2016-08-26 08:57:14 -07:00
|
|
|
buildInputs = [
|
2020-10-05 02:04:49 -07:00
|
|
|
cmake boost gnuradio makeWrapper cppunit gr-osmosdr log4cpp
|
2016-08-26 08:57:14 -07:00
|
|
|
] ++ stdenv.lib.optionals pythonSupport [ python swig ];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
for prog in "$out"/bin/*; do
|
|
|
|
wrapProgram "$prog" --set PYTHONPATH $PYTHONPATH:$(toPythonPath "$out")
|
|
|
|
done
|
|
|
|
'';
|
|
|
|
|
2017-07-14 17:27:30 -07:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2016-08-26 08:57:14 -07:00
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Gnuradio block for ais";
|
2020-03-31 18:11:51 -07:00
|
|
|
homepage = "https://github.com/bistromath/gr-ais";
|
2016-08-26 08:57:14 -07:00
|
|
|
license = licenses.gpl3Plus;
|
2017-07-14 17:26:42 -07:00
|
|
|
platforms = platforms.linux ++ platforms.darwin;
|
2016-08-26 08:57:14 -07:00
|
|
|
maintainers = with maintainers; [ mog ];
|
|
|
|
};
|
|
|
|
}
|