vapoursynth-editor: allow adding plugins without rebuilding
This commit is contained in:
parent
c373e6ddb2
commit
b6f3c4d075
@ -1,9 +1,10 @@
|
|||||||
{ lib, mkDerivation, fetchFromBitbucket
|
{ lib, stdenv, mkDerivation, fetchFromBitbucket, makeWrapper, runCommand
|
||||||
, python3, vapoursynth
|
, python3, vapoursynth
|
||||||
, qmake, qtbase, qtwebsockets
|
, qmake, qtbase, qtwebsockets
|
||||||
}:
|
}:
|
||||||
|
|
||||||
mkDerivation rec {
|
let
|
||||||
|
unwrapped = mkDerivation rec {
|
||||||
pname = "vapoursynth-editor";
|
pname = "vapoursynth-editor";
|
||||||
version = "R19";
|
version = "R19";
|
||||||
|
|
||||||
@ -26,13 +27,12 @@ mkDerivation rec {
|
|||||||
mkdir -p $out/bin
|
mkdir -p $out/bin
|
||||||
for bin in vsedit{,-job-server{,-watcher}}; do
|
for bin in vsedit{,-job-server{,-watcher}}; do
|
||||||
mv $bin $out/bin
|
mv $bin $out/bin
|
||||||
|
wrapQtApp $out/bin/$bin
|
||||||
wrapQtApp $out/bin/$bin \
|
|
||||||
--prefix PYTHONPATH : ${vapoursynth}/${python3.sitePackages} \
|
|
||||||
--prefix LD_LIBRARY_PATH : ${vapoursynth}/lib
|
|
||||||
done
|
done
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
passthru = { inherit withPlugins; };
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "Cross-platform editor for VapourSynth scripts";
|
description = "Cross-platform editor for VapourSynth scripts";
|
||||||
homepage = "https://bitbucket.org/mystery_keeper/vapoursynth-editor";
|
homepage = "https://bitbucket.org/mystery_keeper/vapoursynth-editor";
|
||||||
@ -40,4 +40,20 @@ mkDerivation rec {
|
|||||||
maintainers = with maintainers; [ tadeokondrak ];
|
maintainers = with maintainers; [ tadeokondrak ];
|
||||||
platforms = platforms.all;
|
platforms = platforms.all;
|
||||||
};
|
};
|
||||||
}
|
};
|
||||||
|
|
||||||
|
withPlugins = plugins: let
|
||||||
|
vapoursynthWithPlugins = vapoursynth.withPlugins plugins;
|
||||||
|
in runCommand "${unwrapped.name}-with-plugins" {
|
||||||
|
buildInputs = [ makeWrapper ];
|
||||||
|
passthru = { withPlugins = plugins': withPlugins (plugins ++ plugins'); };
|
||||||
|
} ''
|
||||||
|
mkdir -p $out/bin
|
||||||
|
for bin in vsedit{,-job-server{,-watcher}}; do
|
||||||
|
makeWrapper ${unwrapped}/bin/$bin $out/bin/$bin \
|
||||||
|
--prefix PYTHONPATH : ${vapoursynthWithPlugins}/${python3.sitePackages} \
|
||||||
|
--prefix LD_LIBRARY_PATH : ${vapoursynthWithPlugins}/lib
|
||||||
|
done
|
||||||
|
'';
|
||||||
|
in
|
||||||
|
withPlugins []
|
||||||
|
Loading…
x
Reference in New Issue
Block a user