02cf88bb76
GitOrigin-RevId: c4a0efdd5a728e20791b8d8d2f26f90ac228ee8d
64 lines
1.3 KiB
Nix
64 lines
1.3 KiB
Nix
{ lib
|
|
, mkDerivation
|
|
, fetchFromGitHub
|
|
, libpng
|
|
, gsl
|
|
, libsndfile
|
|
, lzo
|
|
, qmake
|
|
, qttools
|
|
, qtbase
|
|
, qtmultimedia
|
|
, withOpenCL ? true
|
|
, opencl-clhpp ? null
|
|
, ocl-icd ? null
|
|
}:
|
|
|
|
assert withOpenCL -> opencl-clhpp != null;
|
|
assert withOpenCL -> ocl-icd != null;
|
|
|
|
mkDerivation rec {
|
|
pname = "mandelbulber";
|
|
version = "2.28";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "buddhi1980";
|
|
repo = "mandelbulber2";
|
|
rev = version;
|
|
sha256 = "sha256-NrXfEUoTJSz8C6rNU+tSO4PUUo5YWP0bknzXQieOqDc=";
|
|
};
|
|
|
|
nativeBuildInputs = [
|
|
qmake
|
|
qttools
|
|
];
|
|
buildInputs = [
|
|
qtbase
|
|
qtmultimedia
|
|
libpng
|
|
gsl
|
|
libsndfile
|
|
lzo
|
|
] ++ lib.optionals withOpenCL [
|
|
opencl-clhpp
|
|
ocl-icd
|
|
];
|
|
|
|
sourceRoot = "${src.name}/mandelbulber2";
|
|
|
|
qmakeFlags = [
|
|
"SHARED_PATH=${placeholder "out"}"
|
|
(if withOpenCL
|
|
then "qmake/mandelbulber-opencl.pro"
|
|
else "qmake/mandelbulber.pro")
|
|
];
|
|
|
|
meta = with lib; {
|
|
description = "A 3D fractal rendering engine";
|
|
longDescription = "Mandelbulber creatively generates three-dimensional fractals. Explore trigonometric, hyper-complex, Mandelbox, IFS, and many other 3D fractals.";
|
|
homepage = "https://mandelbulber.com";
|
|
license = licenses.gpl3Plus;
|
|
platforms = platforms.linux;
|
|
maintainers = with maintainers; [ kovirobi ];
|
|
};
|
|
}
|