Author: raskin Date: 2010-06-29 22:18:49 +0000 (Tue, 29 Jun 2010) New Revision: 22428
You can view the changes in this commit at: https://svn.nixos.org/viewvc/nix?rev=22428&view=rev Added: nixpkgs/trunk/pkgs/servers/http/redstore/ nixpkgs/trunk/pkgs/servers/http/redstore/default.nix nixpkgs/trunk/pkgs/servers/http/redstore/src-for-default.nix nixpkgs/trunk/pkgs/servers/http/redstore/src-info-for-default.nix Modified: nixpkgs/trunk/maintainers/docs/update-upstream-data.txt nixpkgs/trunk/pkgs/development/libraries/librdf/raptor.nix nixpkgs/trunk/pkgs/development/libraries/redland/1.0.10.nix nixpkgs/trunk/pkgs/lib/misc.nix nixpkgs/trunk/pkgs/top-level/all-packages.nix Log: Adding Redstore HTTP RDF/SPARQL server Changes: Modified: nixpkgs/trunk/maintainers/docs/update-upstream-data.txt =================================================================== --- nixpkgs/trunk/maintainers/docs/update-upstream-data.txt 2010-06-29 20:23:17 UTC (rev 22427) +++ nixpkgs/trunk/maintainers/docs/update-upstream-data.txt 2010-06-29 22:18:49 UTC (rev 22428) @@ -12,4 +12,3 @@ nixpkgs/pkgs/build-support/upstream-updater directory contains some scripts. The worker script is called update-upstream-data.sh. This script requires main expression name (e.g. default.nix). It can optionally accpet a second parameter, URL which will be used instead of getting one by parsing the downloadPage (version extraction, mirror URL creation etc. will still be run). After running the script, check src-for-default.nix (or replace default.nix with expression name, if there are seceral expressions in the directory) for new version information. - Modified: nixpkgs/trunk/pkgs/development/libraries/librdf/raptor.nix =================================================================== --- nixpkgs/trunk/pkgs/development/libraries/librdf/raptor.nix 2010-06-29 20:23:17 UTC (rev 22427) +++ nixpkgs/trunk/pkgs/development/libraries/librdf/raptor.nix 2010-06-29 22:18:49 UTC (rev 22428) @@ -1,10 +1,10 @@ args: with args; -stdenv.mkDerivation { - name = "raptor-1.4.19"; +stdenv.mkDerivation rec { + name = "raptor-1.4.21"; src = fetchurl { - url = http://download.librdf.org/source/raptor-1.4.19.tar.gz; - sha256 = "0qpfl73dvkhngica7wk9qglvd0b3fp9wqnjkl5q8m6h1kf8605ml"; + url = "http://download.librdf.org/source/${name}.tar.gz"; + sha256 = "db3172d6f3c432623ed87d7d609161973d2f7098e3d2233d0702fbcc22cfd8ca"; }; buildInputs = [ Modified: nixpkgs/trunk/pkgs/development/libraries/redland/1.0.10.nix =================================================================== --- nixpkgs/trunk/pkgs/development/libraries/redland/1.0.10.nix 2010-06-29 20:23:17 UTC (rev 22427) +++ nixpkgs/trunk/pkgs/development/libraries/redland/1.0.10.nix 2010-06-29 22:18:49 UTC (rev 22428) @@ -18,10 +18,6 @@ librdf_raptor librdf_rasqal ]; - preConfigure = '' - export NIX_LDFLAGS="$NIX_LDFLAGS -lrasqal -lraptor" - ''; - configureFlags = [ "--with-threads" ] ++ stdenv.lib.optional (bdb != null) "--with-bdb=${bdb}"; Modified: nixpkgs/trunk/pkgs/lib/misc.nix =================================================================== --- nixpkgs/trunk/pkgs/lib/misc.nix 2010-06-29 20:23:17 UTC (rev 22427) +++ nixpkgs/trunk/pkgs/lib/misc.nix 2010-06-29 22:18:49 UTC (rev 22428) @@ -95,6 +95,11 @@ # shortcut for attrByPath ["name"] default attrs + maybeAttrNullable = name: default: attrs: + if attrs == null then default else + if (__hasAttr name attrs) then (__getAttr name attrs) else default; + + # shortcut for attrByPath ["name"] default attrs maybeAttr = name: default: attrs: if (__hasAttr name attrs) then (__getAttr name attrs) else default; @@ -204,8 +209,8 @@ innerClosePropagation (ready ++ [(head list)]) ((tail list) - ++ (maybeAttr "propagatedBuildInputs" [] (head list)) - ++ (maybeAttr "propagatedBuildNativeInputs" [] (head list))); + ++ (maybeAttrNullable "propagatedBuildInputs" [] (head list)) + ++ (maybeAttrNullable "propagatedBuildNativeInputs" [] (head list))); closePropagation = list: (uniqList {inputList = (innerClosePropagation [] list);}); Added: nixpkgs/trunk/pkgs/servers/http/redstore/default.nix =================================================================== --- nixpkgs/trunk/pkgs/servers/http/redstore/default.nix (rev 0) +++ nixpkgs/trunk/pkgs/servers/http/redstore/default.nix 2010-06-29 22:18:49 UTC (rev 22428) @@ -0,0 +1,32 @@ +...@{builderdefspackage + , redland, pkgconfig, gmp + , ...}: +builderDefsPackage +(a : +let + s = import ./src-for-default.nix; + helperArgNames = ["stdenv" "fetchurl" "builderDefsPackage"] ++ + []; + buildInputs = map (n: builtins.getAttr n x) + (builtins.attrNames (builtins.removeAttrs x helperArgNames)); +in +rec { + src = a.fetchUrlFromSrcInfo s; + + inherit (s) name; + inherit buildInputs; + + /* doConfigure should be removed if not needed */ + phaseNames = ["doConfigure" "doMakeInstall"]; + + meta = { + description = "An HTTP interface to Redland RDF store"; + maintainers = with a.lib.maintainers; + [ + raskin + ]; + platforms = with a.lib.platforms; + linux ++ freebsd ++ gnu; + }; +}) x + Added: nixpkgs/trunk/pkgs/servers/http/redstore/src-for-default.nix =================================================================== --- nixpkgs/trunk/pkgs/servers/http/redstore/src-for-default.nix (rev 0) +++ nixpkgs/trunk/pkgs/servers/http/redstore/src-for-default.nix 2010-06-29 22:18:49 UTC (rev 22428) @@ -0,0 +1,9 @@ +rec { + version="0.4"; + name="redstore-0.4"; + hash="1fs54v0d0kkqaz9ajacabb8wifrglvg6kkhd5b0mxmnng352wpp7"; + url="http://redstore.googlecode.com/files/redstore-${version}.tar.gz"; + advertisedUrl="http://redstore.googlecode.com/files/redstore-0.4.tar.gz"; + + +} Added: nixpkgs/trunk/pkgs/servers/http/redstore/src-info-for-default.nix =================================================================== --- nixpkgs/trunk/pkgs/servers/http/redstore/src-info-for-default.nix (rev 0) +++ nixpkgs/trunk/pkgs/servers/http/redstore/src-info-for-default.nix 2010-06-29 22:18:49 UTC (rev 22428) @@ -0,0 +1,6 @@ +{ + downloadPage = "http://code.google.com/p/redstore/downloads/list"; + baseName = "redstore"; + choiceCommand = '' head -n 1 | + sed -re "s...@[&].*@@; s...@.*[?]name=(.*)@http://$(sed -re "s...@.*/p/([^/]+)/....@\\1@" <<< "$(getAttr downloadPage)").googlecode.com/files/\\1@" ''; +} Modified: nixpkgs/trunk/pkgs/top-level/all-packages.nix =================================================================== --- nixpkgs/trunk/pkgs/top-level/all-packages.nix 2010-06-29 20:23:17 UTC (rev 22427) +++ nixpkgs/trunk/pkgs/top-level/all-packages.nix 2010-06-29 22:18:49 UTC (rev 22428) @@ -5943,6 +5943,10 @@ inherit fetchurl stdenv m4 groff readline; }; + redstore = import ../servers/http/redstore { + inherit builderDefsPackage redland pkgconfig gmp; + }; + samba = makeOverridable (import ../servers/samba) { inherit stdenv fetchurl readline openldap pam kerberos popt iniparser libunwind acl fam; _______________________________________________ nix-commits mailing list [email protected] http://mail.cs.uu.nl/mailman/listinfo/nix-commits
