nixpkgs-suyu/pkgs/applications/radio/gnss-sdr/default.nix

79 lines
1.5 KiB
Nix
Raw Normal View History

{ lib, stdenv, fetchFromGitHub
, armadillo
, boost
, cmake
, glog
, gmock
, openssl
, gflags
, gnuradio
, orc
, pkg-config
, pythonPackages
, uhd
2019-08-08 22:11:41 +02:00
, log4cpp
, blas, lapack
2019-08-08 22:11:41 +02:00
, matio
, pugixml
, protobuf
}:
stdenv.mkDerivation rec {
pname = "gnss-sdr";
2020-08-10 14:03:26 +02:00
version = "0.0.13";
src = fetchFromGitHub {
owner = "gnss-sdr";
repo = "gnss-sdr";
rev = "v${version}";
2020-08-10 14:03:26 +02:00
sha256 = "0a3k47fl5dizzhbqbrbmckl636lznyjby2d2nz6fz21637hvrnby";
};
nativeBuildInputs = [ cmake pkg-config ];
buildInputs = [
armadillo
boost.dev
glog
gmock
openssl.dev
gflags
gnuradio
orc
pythonPackages.Mako
pythonPackages.six
# UHD support is optional, but gnuradio is built with it, so there's
# nothing to be gained by leaving it out.
uhd
2019-08-08 22:11:41 +02:00
log4cpp
blas lapack
2019-08-08 22:11:41 +02:00
matio
pugixml
protobuf
];
cmakeFlags = [
"-DGFlags_ROOT_DIR=${gflags}/lib"
"-DGLOG_INCLUDE_DIR=${glog}/include"
"-DENABLE_UNIT_TESTING=OFF"
# gnss-sdr doesn't truly depend on BLAS or LAPACK, as long as
# armadillo is built using both, so skip checking for them.
"-DBLAS=YES"
"-DLAPACK=YES"
"-DBLAS_LIBRARIES=-lblas"
"-DLAPACK_LIBRARIES=-llapack"
# Similarly, it doesn't actually use gfortran despite checking for
# its presence.
"-DGFORTRAN=YES"
];
meta = with lib; {
description = "An open source Global Navigation Satellite Systems software-defined receiver";
2020-03-14 06:56:58 +01:00
homepage = "https://gnss-sdr.org/";
license = licenses.gpl3Plus;
platforms = platforms.linux;
};
}