f3d: add withManual option, by default disabled on darwin

should fix darwin
This commit is contained in:
Peder Bergebakken Sundt 2024-05-23 23:05:43 +02:00
parent 67d4cea69d
commit dc4209a00a

View File

@ -10,13 +10,14 @@
, libGL
, Cocoa
, OpenGL
, withManual ? !stdenv.isDarwin
}:
stdenv.mkDerivation rec {
pname = "f3d";
version = "2.4.0";
outputs = [ "out" "man" ];
outputs = [ "out" ] ++ lib.optionals withManual [ "man" ];
src = fetchFromGitHub {
owner = "f3d-app";
@ -27,6 +28,8 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [
cmake
] ++ lib.optionals withManual [
# manpage
help2man
gzip
] ++ lib.optionals stdenv.hostPlatform.isElf [
@ -42,7 +45,7 @@ stdenv.mkDerivation rec {
"-DCMAKE_INSTALL_LIBDIR=lib"
"-DCMAKE_INSTALL_INCLUDEDIR=include"
"-DCMAKE_INSTALL_BINDIR=bin"
] ++ lib.optionals withManual [
"-DF3D_LINUX_GENERATE_MAN=ON"
];