2021-08-22 07:53:02 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, cmake
|
|
|
|
, doxygen
|
2023-05-24 13:37:59 +00:00
|
|
|
, gbenchmark
|
2021-08-22 07:53:02 +00:00
|
|
|
, graphviz
|
2023-05-24 13:37:59 +00:00
|
|
|
, gtest
|
2021-08-22 07:53:02 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "ftxui";
|
2023-07-15 17:15:38 +00:00
|
|
|
version = "4.1.1";
|
2021-08-22 07:53:02 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "ArthurSonzogni";
|
2022-07-18 16:21:45 +00:00
|
|
|
repo = "ftxui";
|
2022-03-30 09:31:56 +00:00
|
|
|
rev = "v${version}";
|
2023-07-15 17:15:38 +00:00
|
|
|
sha256 = "sha256-qFgCLV7sgGxlL18sThqpl+vyXL68GXcbYqMG7mXhsB4=";
|
2021-08-22 07:53:02 +00:00
|
|
|
};
|
|
|
|
|
2023-07-15 17:15:38 +00:00
|
|
|
strictDeps = true;
|
|
|
|
|
2021-08-22 07:53:02 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
cmake
|
|
|
|
doxygen
|
|
|
|
graphviz
|
|
|
|
];
|
|
|
|
|
2023-07-15 17:15:38 +00:00
|
|
|
checkInputs = [
|
2023-05-24 13:37:59 +00:00
|
|
|
gtest
|
2023-07-15 17:15:38 +00:00
|
|
|
gbenchmark
|
2023-05-24 13:37:59 +00:00
|
|
|
];
|
|
|
|
|
2022-07-18 16:21:45 +00:00
|
|
|
cmakeFlags = [
|
|
|
|
"-DFTXUI_BUILD_EXAMPLES=OFF"
|
2023-05-24 13:37:59 +00:00
|
|
|
"-DFTXUI_BUILD_DOCS=ON"
|
2023-07-15 17:15:38 +00:00
|
|
|
"-DFTXUI_BUILD_TESTS=${if doCheck then "ON" else "OFF"}"
|
2022-07-18 16:21:45 +00:00
|
|
|
];
|
|
|
|
|
2023-07-15 17:15:38 +00:00
|
|
|
doCheck = stdenv.buildPlatform.canExecute stdenv.hostPlatform;
|
2022-03-30 09:31:56 +00:00
|
|
|
|
2021-08-22 07:53:02 +00:00
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/ArthurSonzogni/FTXUI";
|
2022-03-30 09:31:56 +00:00
|
|
|
changelog = "https://github.com/ArthurSonzogni/FTXUI/blob/v${version}/CHANGELOG.md";
|
|
|
|
description = "Functional Terminal User Interface library for C++";
|
2021-08-22 07:53:02 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = [ maintainers.ivar ];
|
2023-05-24 13:37:59 +00:00
|
|
|
platforms = platforms.all;
|
2021-08-22 07:53:02 +00:00
|
|
|
};
|
|
|
|
}
|