2021-01-23 13:26:19 +01:00
|
|
|
{ lib, stdenv, fetchFromGitHub, python, autoreconfHook, pkg-config, makeWrapper
|
2018-03-11 15:44:20 +01:00
|
|
|
, flex
|
2021-03-04 20:35:08 +01:00
|
|
|
, gettext, libedit, glib, imagemagick6, libxml2, boost, gnuplot, graphviz
|
2018-03-11 15:44:20 +01:00
|
|
|
, tesseract, gts, libXtst
|
|
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
2020-03-27 00:06:03 +01:00
|
|
|
version = "0.42";
|
2019-08-15 14:41:18 +02:00
|
|
|
pname = "fMBT";
|
2018-03-11 15:44:20 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "intel";
|
|
|
|
repo = "fMBT";
|
|
|
|
rev = "v${version}";
|
2020-03-27 00:06:03 +01:00
|
|
|
sha256 = "1jb9nb2mipc5cg99a80dny4m06vz2zral0q30fv75rz2cb6ja4zp";
|
2018-03-11 15:44:20 +01:00
|
|
|
};
|
|
|
|
|
2021-01-19 07:50:56 +01:00
|
|
|
nativeBuildInputs = [ autoreconfHook pkg-config flex makeWrapper
|
2018-03-11 15:44:20 +01:00
|
|
|
python.pkgs.wrapPython ];
|
|
|
|
|
2021-03-04 20:35:08 +01:00
|
|
|
buildInputs = [ python gettext libedit glib imagemagick6 libxml2 boost
|
2021-01-19 22:20:11 +01:00
|
|
|
gnuplot graphviz tesseract gts
|
2018-03-11 15:44:20 +01:00
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = with python.pkgs; [
|
|
|
|
pyside pydbus pexpect pysideShiboken
|
|
|
|
];
|
|
|
|
|
|
|
|
preBuild = ''
|
|
|
|
export PYTHONPATH="$PYTHONPATH:$out/lib/python${python.pythonVersion}/site-packages"
|
|
|
|
export PATH="$PATH:$out/bin"
|
2021-01-23 13:26:19 +01:00
|
|
|
export LD_LIBRARY_PATH="${lib.makeLibraryPath [libXtst]}"
|
2018-03-11 15:44:20 +01:00
|
|
|
'';
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
echo -e '#! ${stdenv.shell}\npython "$@"' > "$out/bin/fmbt-python"
|
|
|
|
chmod a+x "$out/bin/fmbt-python"
|
|
|
|
patchShebangs "$out/bin"
|
|
|
|
for i in "$out"/bin/*; do
|
|
|
|
wrapProgram "$i" --suffix "PATH" ":" "$PATH" \
|
|
|
|
--suffix "PYTHONPATH" ":" "$PYTHONPATH" \
|
|
|
|
--suffix "LD_LIBRARY_PATH" ":" "$LD_LIBRARY_PATH"
|
|
|
|
done
|
|
|
|
'';
|
|
|
|
|
2021-01-23 13:26:19 +01:00
|
|
|
meta = with lib; {
|
2018-03-11 15:44:20 +01:00
|
|
|
description = "Free Model-Based Testing tool";
|
|
|
|
homepage = "https://github.com/intel/fMBT";
|
|
|
|
license = licenses.lgpl21;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = with maintainers; [ raskin ];
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|