1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-24 14:41:17 +00:00

add puredata-with-plugins:

a wrapper for puredata, plus packages for the following plugins:
cyclone
helmholtz
maxlib
mrpeach
puremapping
timbreid
zexy
This commit is contained in:
Bart Brouns 2015-03-16 15:39:52 +01:00
parent 82ee506f43
commit 2479dc0c63
9 changed files with 315 additions and 0 deletions

View file

@ -0,0 +1,41 @@
{ stdenv, fetchurl, puredata }:
stdenv.mkDerivation rec {
name = "cyclone-${version}";
version = "0.1-alpha55";
src = fetchurl {
url = "http://downloads.sourceforge.net/project/pure-data/libraries/cyclone/${name}.tar.gz";
sha256 = "1yys9xrlz09xgnqk2gqdl8vw6xj6l9d7km2lkihidgjql0jx5b5i";
};
buildInputs = [ puredata ];
/*unpackPhase = ''*/
/*unzip $src*/
/*'';*/
patchPhase = ''
for file in `grep -r -l g_canvas.h`
do
sed -i 's|#include "g_canvas.h"|#include "${puredata}/include/pd/g_canvas.h"|g' $file
done
for file in `grep -r -l m_imp.h`
do
sed -i 's|#include "m_imp.h"|#include "${puredata}/include/pd/m_imp.h"|g' $file
done
'';
installPhase = ''
mkdir -p $out/cyclone
cp -r bin/* $out/cyclone
'';
meta = {
description = "A library of PureData classes, bringing some level of compatibility between Max/MSP and Pd environments.";
homepage = http://puredata.info/downloads/cyclone;
license = stdenv.lib.licenses.tcltk;
maintainers = [ stdenv.lib.maintainers.magnetophon ];
platforms = stdenv.lib.platforms.linux;
};
}

View file

@ -0,0 +1,42 @@
{ stdenv, fetchurl, unzip, puredata }:
stdenv.mkDerivation rec {
name = "helmholtz";
src = fetchurl {
url = "http://www.katjaas.nl/helmholtz/helmholtz~.zip";
name = "helmholtz.zip";
sha256 = "0h1fj7lmvq9j6rmw33rb8k0byxb898bi2xhcwkqalb84avhywgvs";
};
buildInputs = [ unzip puredata ];
unpackPhase = ''
unzip $src
mv helmholtz~/src/helmholtz\~.cpp .
mv helmholtz~/src/Helmholtz.cpp .
mv helmholtz~/src/include/ .
mv helmholtz~/src/Makefile .
rm -rf helmholtz~/src/
rm helmholtz~/helmholtz~.pd_darwin
rm helmholtz~/helmholtz~.dll
rm -rf __MACOSX
'';
patchPhase = ''
sed -i "s@current: pd_darwin@current: pd_linux@g" Makefile
sed -i "s@-Wl@@g" Makefile
'';
installPhase = ''
cp -r helmholtz~/ $out/
'';
meta = {
description = "time domain pitch tracker for Pure Data";
homepage = http://www.katjaas.nl/helmholtz/helmholtz.html;
license = stdenv.lib.licenses.bsd3;
maintainers = [ stdenv.lib.maintainers.magnetophon ];
platforms = stdenv.lib.platforms.linux;
};
}

View file

@ -0,0 +1,33 @@
{ stdenv, fetchurl, puredata }:
stdenv.mkDerivation rec {
name = "maxlib-${version}";
version = "1.5.5";
src = fetchurl {
url = "http://downloads.sourceforge.net/project/pure-data/libraries/maxlib/${name}.tar.gz";
sha256 = "0vxl9s815dnay5r0067rxsfh8f6jbk61f0nxrydzjydfycza7p1w";
};
buildInputs = [ puredata ];
patchPhase = ''
for i in ${puredata}/include/pd/*; do
ln -s $i .
done
sed -i "s@/usr@$out@g" Makefile
'';
postInstall = ''
mv $out/local/lib/pd-externals/maxlib/ $out
rm -rf $out/local/
'';
meta = {
description = "A library of non-tilde externals for puredata, by Miller Puckette.";
homepage = http://puredata.info/downloads/maxlib;
license = stdenv.lib.licenses.gpl2;
maintainers = [ stdenv.lib.maintainers.magnetophon ];
platforms = stdenv.lib.platforms.linux;
};
}

View file

@ -0,0 +1,60 @@
{ stdenv, fetchurl, puredata }:
stdenv.mkDerivation rec {
name = "mrpeach-${version}";
version = "1.1";
# this was to only usable url I could find:
# - The main url changes hash: http://pure-data.cvs.sourceforge.net/viewvc/pure-data/externals/mrpeach/?view=tar
# - There are lot's of places where this SW is available as part of a big pkg: pd-extended, pd-l2ork
# - It's just 211K
src = fetchurl {
url = "http://slackonly.com/pub/korgie/sources/pd_mrpeach-2011.10.21.tar.gz";
sha256 = "12jqba3jsdrk20ib9wc2wiivki88ypcd4mkzgsri9siywbbz9w8x";
};
buildInputs = [puredata ];
patchPhase = ''
for D in net osc
do
sed -i "s@prefix = /usr/local@prefix = $out@g" $D/Makefile
for i in ${puredata}/include/pd/*; do
ln -s $i $D/
done
done
'';
buildPhase = ''
for D in net osc
do
cd $D
make
cd ..
done
'';
installPhase = ''
for D in net osc
do
cd $D
make install
cd ..
done
'';
fixupPhase = ''
mv $out/lib/pd-externals/net $out
mv $out/lib/pd-externals/osc $out
rm -rf $out/lib
'';
meta = {
description = "A collection of Pd objectclasses for OSC-messages.";
homepage = http://puredata.info/downloads/osc;
license = stdenv.lib.licenses.gpl2;
maintainers = [ stdenv.lib.maintainers.magnetophon ];
platforms = stdenv.lib.platforms.linux;
};
}

View file

@ -0,0 +1,30 @@
{ stdenv, fetchurl, unzip, puredata }:
stdenv.mkDerivation rec {
name = "puremapping";
src = fetchurl {
url = "http://www.chnry.net/ch/IMG/zip/puremapping-libdir-generic.zip";
name = "puremapping";
sha256 = "1ygzxsfj3rnzjkpmgi4wch810q8s5vm1gdam6a938hbbvamafgvc";
};
buildInputs = [ unzip puredata ];
unpackPhase = ''
unzip $src
'';
installPhase = ''
mkdir -p $out/puremapping
mv puremapping/ $out
'';
meta = {
description = "Set of externals to facilitate the use of sensors within Pure Data and to create complex relations between input and output of a dynamic system.";
homepage = http://www.chnry.net/ch/?090-Pure-Mapping&lang=en;
license = stdenv.lib.licenses.gpl1;
maintainers = [ stdenv.lib.maintainers.magnetophon ];
platforms = stdenv.lib.platforms.linux;
};
}

View file

@ -0,0 +1,35 @@
{ stdenv, fetchurl, unzip, puredata }:
stdenv.mkDerivation rec {
version = "0.6.0";
name = "timbreid-${version}";
src = fetchurl {
url = "http://williambrent.conflations.com/pd/timbreID-${version}-src.zip";
sha256 = "02rnkb0vpjxrr60c3hryv7zhyjpci2mi9dk27kjxpj5zp26gjk0p";
};
buildInputs = [ unzip puredata ];
unpackPhase = ''
unzip $src
mv timbreID-0.6.0-src/tID/* .
rm -rf timbreID-0.6.0-src/tID/
rm -rf timbreID-0.6.0-src/INSTALL.txt
'';
installPhase = ''
mkdir -p $out/
cp -r *.pd $out/
cp -r *.pd_linux $out/
cp -r *.wav $out/
'';
meta = {
description = "A collection of audio feature analysis externals for puredata";
homepage = http://williambrent.conflations.com/pages/research.html;
license = stdenv.lib.licenses.gpl3;
maintainers = [ stdenv.lib.maintainers.magnetophon ];
platforms = stdenv.lib.platforms.linux;
};
}

View file

@ -0,0 +1,36 @@
{ stdenv, fetchurl, autoconf, automake, puredata }:
stdenv.mkDerivation rec {
name = "zexy-${version}";
version = "2.2.4";
src = fetchurl {
url = "http://puredata.info/downloads/zexy/releases/${version}/${name}.tar.gz";
sha256 = "1xpgl82c2lc6zfswjsa7z10yhv5jb7a4znzh3nc7ffrzm1z8vylp";
};
buildInputs = [ autoconf automake puredata ];
patchPhase = ''
cd src/
for i in ${puredata}/include/pd/*; do
ln -s $i .
done
patchShebangs
./bootstrap.sh
./configure --enable-lpt=no --prefix=$out
'';
postInstall = ''
mv $out/lib/pd/extra/zexy $out
rm -rf $out/lib
'';
meta = {
description = "the swiss army knife for puredata";
homepage = http://puredata.info/downloads/zexy;
license = stdenv.lib.licenses.gpl2;
maintainers = [ stdenv.lib.maintainers.magnetophon ];
platforms = stdenv.lib.platforms.linux;
};
}

View file

@ -0,0 +1,23 @@
{ stdenv, buildEnv, puredata, makeWrapper, plugins }:
let
puredataFlags = map (x: "-path ${x}/") plugins;
drv = buildEnv {
name = "puredata-with-plugins-" + (builtins.parseDrvName puredata.name).version;
paths = [ puredata ] ++ plugins;
postBuild = ''
# TODO: This could be avoided if buildEnv could be forced to create all directories
if [ -L $out/bin ]; then
rm $out/bin
mkdir $out/bin
for i in ${puredata}/bin/*; do
ln -s $i $out/bin
done
fi
wrapProgram $out/bin/pd \
--add-flags "${toString puredataFlags}"
'';
};
in stdenv.lib.overrideDerivation drv (x : { buildInputs = x.buildInputs ++ [ makeWrapper ]; })

View file

@ -9993,6 +9993,8 @@ let
cvs2svn = callPackage ../applications/version-management/cvs2svn { }; cvs2svn = callPackage ../applications/version-management/cvs2svn { };
cyclone = callPackage ../applications/audio/pd-plugins/cyclone { };
d4x = callPackage ../applications/misc/d4x { }; d4x = callPackage ../applications/misc/d4x { };
darcs = haskell-ng.lib.overrideCabal haskellngPackages.darcs (drv: { darcs = haskell-ng.lib.overrideCabal haskellngPackages.darcs (drv: {
@ -10659,6 +10661,8 @@ let
hello = callPackage ../applications/misc/hello/ex-2 { }; hello = callPackage ../applications/misc/hello/ex-2 { };
helmholtz = callPackage ../applications/audio/pd-plugins/helmholtz { };
herbstluftwm = callPackage ../applications/window-managers/herbstluftwm { }; herbstluftwm = callPackage ../applications/window-managers/herbstluftwm { };
hexchat = callPackage ../applications/networking/irc/hexchat { }; hexchat = callPackage ../applications/networking/irc/hexchat { };
@ -11082,6 +11086,8 @@ let
vaapiSupport = config.mpv.vaapiSupport or false; vaapiSupport = config.mpv.vaapiSupport or false;
}; };
mrpeach = callPackage ../applications/audio/pd-plugins/mrpeach { };
mrxvt = callPackage ../applications/misc/mrxvt { }; mrxvt = callPackage ../applications/misc/mrxvt { };
mudlet = callPackage ../games/mudlet { mudlet = callPackage ../games/mudlet {
@ -11152,6 +11158,8 @@ let
lua = lua5; lua = lua5;
}; };
maxlib = callPackage ../applications/audio/pd-plugins/maxlib { };
mupdf = callPackage ../applications/misc/mupdf { mupdf = callPackage ../applications/misc/mupdf {
openjpeg = openjpeg_2_0_1; openjpeg = openjpeg_2_0_1;
}; };
@ -11337,6 +11345,9 @@ let
pulseview = callPackage ../applications/science/electronics/pulseview { }; pulseview = callPackage ../applications/science/electronics/pulseview { };
puredata = callPackage ../applications/audio/puredata { }; puredata = callPackage ../applications/audio/puredata { };
puredata-with-plugins = plugins: callPackage ../applications/audio/puredata/wrapper.nix { inherit plugins; };
puremapping = callPackage ../applications/audio/pd-plugins/puremapping { };
pythonmagick = callPackage ../applications/graphics/PythonMagick { }; pythonmagick = callPackage ../applications/graphics/PythonMagick { };
@ -11741,6 +11752,8 @@ let
gtk = gtk3; gtk = gtk3;
}; };
timbreid = callPackage ../applications/audio/pd-plugins/timbreid { };
timidity = callPackage ../tools/misc/timidity { }; timidity = callPackage ../tools/misc/timidity { };
tint2 = callPackage ../applications/misc/tint2 { }; tint2 = callPackage ../applications/misc/tint2 { };
@ -12328,6 +12341,8 @@ let
zeroc_ice = callPackage ../development/libraries/zeroc-ice { }; zeroc_ice = callPackage ../development/libraries/zeroc-ice { };
zexy = callPackage ../applications/audio/pd-plugins/zexy { };
girara = callPackage ../applications/misc/girara { girara = callPackage ../applications/misc/girara {
gtk = gtk3; gtk = gtk3;
stdenv = overrideCC stdenv gcc49; stdenv = overrideCC stdenv gcc49;