mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-04 21:03:15 +00:00
471dbe9bcf
Eliminate uses of `config.cudaSupport or false` and alike, since the option is now declared in config.nix with a default value fd .nix -t f -x sed 's/config\.cudaSupport or false, cudaPackages [?] [{][}]/config.cudaSupport, cudaPackages ? { }/' '{}' -i fd .nix -t f -x sed 's/config\.cudaSupport or false/config.cudaSupport/' '{}' -i fd .nix -t f -x sed 's/cudaSupport = pkgs.config.cudaSupport/inherit (pkgs.config) cudaSupport/' '{}' -i fd .nix -t f -x sed 's/cudaSupport = config.cudaSupport/inherit (config) cudaSupport/' '{}' -i
47 lines
997 B
Nix
47 lines
997 B
Nix
{ lib
|
|
, config
|
|
, stdenv
|
|
, fetchurl
|
|
, cairo
|
|
, cmake
|
|
, opencv
|
|
, pcre
|
|
, pkg-config
|
|
, cudaSupport ? config.cudaSupport
|
|
, cudaPackages
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "frei0r-plugins";
|
|
version = "1.8.0";
|
|
|
|
src = fetchurl {
|
|
url = "https://files.dyne.org/frei0r/releases/${pname}-${version}.tar.gz";
|
|
hash = "sha256-RaKGVcrwVyJ7RCuADKOJnpNJBRXIHiEtIZ/fSnYT9cQ=";
|
|
};
|
|
|
|
nativeBuildInputs = [ cmake pkg-config ];
|
|
buildInputs = [
|
|
cairo
|
|
opencv
|
|
pcre
|
|
] ++ lib.optionals cudaSupport [
|
|
cudaPackages.cuda_cudart
|
|
cudaPackages.cuda_nvcc
|
|
];
|
|
|
|
postInstall = lib.optionalString stdenv.hostPlatform.isDarwin ''
|
|
for f in $out/lib/frei0r-1/*.so* ; do
|
|
ln -s $f "''${f%.*}.dylib"
|
|
done
|
|
'';
|
|
|
|
meta = with lib; {
|
|
homepage = "https://frei0r.dyne.org";
|
|
description = "Minimalist, cross-platform, shared video plugins";
|
|
license = licenses.gpl2Plus;
|
|
maintainers = [ maintainers.goibhniu ];
|
|
platforms = platforms.linux ++ platforms.darwin;
|
|
};
|
|
}
|