diff options
author | Robert Helgesson <robert@rycee.net> | 2015-12-29 23:52:11 +0100 |
---|---|---|
committer | Robert Helgesson <robert@rycee.net> | 2015-12-30 21:15:15 +0100 |
commit | abf836b06652a3545fb8b009aeb0bb6600fe3479 (patch) | |
tree | 158b3887fd2f7a4807904b235775f3426b054622 /pkgs/development/libraries/ois | |
parent | 9a47354a964fd0b746dd753f0dd1ebf24ff9ce69 (diff) |
ois: use stdenv
This replaces use of `builderDefsPackage`.
Diffstat (limited to 'pkgs/development/libraries/ois')
-rw-r--r-- | pkgs/development/libraries/ois/default.nix | 83 |
1 files changed, 32 insertions, 51 deletions
diff --git a/pkgs/development/libraries/ois/default.nix b/pkgs/development/libraries/ois/default.nix index 67df3645eb906..25bb7a365f284 100644 --- a/pkgs/development/libraries/ois/default.nix +++ b/pkgs/development/libraries/ois/default.nix @@ -1,60 +1,41 @@ -x@{builderDefsPackage, fetchurl - , autoconf, automake, libtool, m4 - , libX11, xproto, libXi, inputproto - , libXaw, libXmu, libXt - , ...}: -builderDefsPackage -(a : -let - helperArgNames = ["stdenv" "fetchurl" "builderDefsPackage"] ++ - []; - - buildInputs = map (n: builtins.getAttr n x) - (builtins.attrNames (builtins.removeAttrs x helperArgNames)); - sourceInfo = rec { - baseName="ois"; - majorVersion="1"; - minorVersion="3"; - version="${majorVersion}.${minorVersion}"; - name="${baseName}-${version}"; - url="mirror://sourceforge/project/wgois/Source%20Release/${version}/ois_v${majorVersion}-${minorVersion}.tar.gz"; - hash="18gs6xxhbqb91x2gm95hh1pmakimqim1k9c65h7ah6g14zc7dyjh"; - }; +{ stdenv, fetchurl, autoconf, automake, libtool, libX11, xproto +, libXi, inputproto, libXaw, libXmu, libXt }: + +let + majorVersion = "1"; + minorVersion = "3"; in -rec { - src = a.fetchurl { - url = sourceInfo.url; - sha256 = sourceInfo.hash; - }; - inherit (sourceInfo) name version; - inherit buildInputs; +stdenv.mkDerivation rec { + name = "ois-${version}"; + version = "${majorVersion}.${minorVersion}"; + + src = fetchurl { + url = "mirror://sourceforge/project/wgois/Source%20Release/${version}/ois_v${majorVersion}-${minorVersion}.tar.gz"; + sha256 = "18gs6xxhbqb91x2gm95hh1pmakimqim1k9c65h7ah6g14zc7dyjh"; + }; - phaseNames = ["doPatch" "doConfigure" "doMakeInstall"]; + patches = [ + (fetchurl { + url = http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/dev-games/ois/files/ois-1.3-gcc47.patch; + sha256 = "026jw06n42bcrmg0sbdhzc4cqxsnf7fw30a2z9cigd9x282zhii8"; + name = "gcc47.patch"; + }) + ]; - patches = [(fetchurl { - url = http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/dev-games/ois/files/ois-1.3-gcc47.patch; - sha256 = "026jw06n42bcrmg0sbdhzc4cqxsnf7fw30a2z9cigd9x282zhii8"; - name = "gcc47.patch"; - })]; patchFlags = "-p0"; - configureCommand = ''sh bootstrap; sh configure''; + buildInputs = [ + autoconf automake libtool libX11 xproto libXi inputproto libXaw + libXmu libXt + ]; + + preConfigure = "sh bootstrap"; - meta = { + meta = with stdenv.lib; { description = "Object-oriented C++ input system"; - maintainers = with a.lib.maintainers; - [ - raskin - ]; - platforms = with a.lib.platforms; - linux; - license = a.lib.licenses.zlib; + maintainers = [ maintainers.raskin ]; + platforms = platforms.linux; + license = licenses.zlib; }; - passthru = { - updateInfo = { - downloadPage = "http://sourceforge.net/projects/wgois/files/Source Release/"; - }; - }; -}) x - +} |