From 734a1b39e0b85e376cd2671bf4274f8de4cd6c18 Mon Sep 17 00:00:00 2001 From: "Yury G. Kudryashov" Date: Sun, 10 Feb 2008 17:40:00 +0000 Subject: [PATCH] added SDL_net, some minor modifications to SDL_image and SDL_mixer svn path=/nixpkgs/branches/stdenv-updates/; revision=10595 --- .../libraries/SDL_image/default.nix | 17 +++++++------ .../libraries/SDL_mixer/default.nix | 25 ++++++++++++++----- .../development/libraries/SDL_net/default.nix | 22 ++++++++++++++++ 3 files changed, 51 insertions(+), 13 deletions(-) create mode 100644 pkgs/development/libraries/SDL_net/default.nix diff --git a/pkgs/development/libraries/SDL_image/default.nix b/pkgs/development/libraries/SDL_image/default.nix index 4dd7d3679b84..d26213ef7cd7 100644 --- a/pkgs/development/libraries/SDL_image/default.nix +++ b/pkgs/development/libraries/SDL_image/default.nix @@ -1,11 +1,14 @@ args: with args; -stdenv.mkDerivation { - name = "SDL_image-1.2.6"; +stdenv.mkDerivation (rec { + pname = "SDL_image"; + version = "1.2.6"; + + name = "${pname}-${version}"; src = fetchurl { - url = http://www.libsdl.org/projects/SDL_image/release/SDL_image-1.2.6.tar.gz; - sha256 = "1i3f72dw3i3l6d77dk81gw57sp0629rng9k76qb37brlz7dv3z48"; - }; + url = "http://www.libsdl.org/projects/${pname}/release/${name}.tar.gz"; + sha256 = "1i3f72dw3i3l6d77dk81gw57sp0629rng9k76qb37brlz7dv3z48"; + }; buildInputs = [SDL libpng libjpeg libtiff libungif libXpm]; @@ -13,7 +16,7 @@ stdenv.mkDerivation { meta = { description = " - SDL image library. + SDL image library. "; }; -} +}) diff --git a/pkgs/development/libraries/SDL_mixer/default.nix b/pkgs/development/libraries/SDL_mixer/default.nix index 14b8359c70a4..024fd643be6f 100644 --- a/pkgs/development/libraries/SDL_mixer/default.nix +++ b/pkgs/development/libraries/SDL_mixer/default.nix @@ -1,11 +1,24 @@ -{stdenv, fetchurl, SDL, libogg, libvorbis}: +args: with args; +stdenv.mkDerivation (rec { + pname = "SDL_mixer"; + version = "1.2.8"; + + name = "${pname}-${version}"; -stdenv.mkDerivation { - name = "SDL_mixer-1.2.7"; src = fetchurl { - url = http://www.libsdl.org/projects/SDL_mixer/release/SDL_mixer-1.2.7.tar.gz; - md5 = "7959b89c8f8f1564ca90968f6c88fa1e"; + url = "http://www.libsdl.org/projects/${pname}/release/${name}.tar.gz"; + sha256 = "a8222a274778ff16d0e3ee49a30db27a48a4d357169a915fc599a764e405e0b6"; }; + buildInputs = [SDL libogg libvorbis]; + configureFlags = "--disable-music-ogg-shared"; -} + + postInstall = "ln -s \${out}/include/SDL/SDL_mixer.h \${out}/include/"; + + meta = { + description = " + SDL multi-channel audio mixer library. +"; + }; +}) diff --git a/pkgs/development/libraries/SDL_net/default.nix b/pkgs/development/libraries/SDL_net/default.nix new file mode 100644 index 000000000000..7de557322f66 --- /dev/null +++ b/pkgs/development/libraries/SDL_net/default.nix @@ -0,0 +1,22 @@ +args: with args; +stdenv.mkDerivation (rec { + pname = "SDL_net"; + version = "1.2.7"; + + name = "${pname}-${version}"; + + src = fetchurl { + url = "http://www.libsdl.org/projects/SDL_net/release/${name}.tar.gz"; + sha256 = "2ce7c84e62ff8117b9f205758bcce68ea603e08bc9d6936ded343735b8b77c53"; + }; + + buildInputs = [SDL]; + + postInstall = "ln -s \${out}/include/SDL/SDL_net.h \${out}/include/"; + + meta = { + description = " + SDL networking library. +"; + }; +})