From 3c95d6d1ea52539c772aa869cd2bc5a919730fc3 Mon Sep 17 00:00:00 2001 From: Patrick Callahan Date: Sat, 26 Mar 2016 11:11:48 -0700 Subject: [PATCH] sdformat: init at 3.7.0 and 4.0.0 --- pkgs/development/libraries/sdformat/3.nix | 7 ++++++ .../libraries/sdformat/default.nix | 23 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 8 +++++++ 3 files changed, 38 insertions(+) create mode 100644 pkgs/development/libraries/sdformat/3.nix create mode 100644 pkgs/development/libraries/sdformat/default.nix diff --git a/pkgs/development/libraries/sdformat/3.nix b/pkgs/development/libraries/sdformat/3.nix new file mode 100644 index 000000000000..116f248b3b4e --- /dev/null +++ b/pkgs/development/libraries/sdformat/3.nix @@ -0,0 +1,7 @@ +{ stdenv, fetchurl, callPackage, ... } @ args: + +callPackage ./default.nix (args // rec { + version = "3.7.0"; + srchash-sha256 = "07kn8bgvj9mwwinsp2cbmz11z7zw2lgnj61mi1gi1pjg7q9in98q"; +}) + diff --git a/pkgs/development/libraries/sdformat/default.nix b/pkgs/development/libraries/sdformat/default.nix new file mode 100644 index 000000000000..0245b47815e5 --- /dev/null +++ b/pkgs/development/libraries/sdformat/default.nix @@ -0,0 +1,23 @@ +{ stdenv, fetchurl, cmake, boost, ruby_1_9, ignition, tinyxml + , name ? "sdformat-${version}" + , version ? "4.0.0" # versions known to work with this expression include 3.7.0 + , srchash-sha256 ? "b0f94bb40b0d83e35ff250a7916fdfd6df5cdc1e60c47bc53dd2da5e2378163e" + , ... + }: + +let + ruby = ruby_1_9; +in +stdenv.mkDerivation rec { + src = fetchurl { + url = "http://osrf-distributions.s3.amazonaws.com/sdformat/releases/${name}.tar.bz2"; + sha256 = srchash-sha256; + }; + + inherit name; + + enableParallelBuilding = true; + buildInputs = [ + cmake boost ruby ignition.math2 tinyxml + ]; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index f7386d8f3b03..b4052536305e 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1572,6 +1572,14 @@ in gawp = goPackages.gawp.bin // { outputs = [ "bin" ]; }; + gazeboSimulator = recurseIntoAttrs { + sdformat = gazeboSimulator.sdformat4; + + sdformat3 = callPackage ../development/libraries/sdformat/3.nix { }; + + sdformat4 = callPackage ../development/libraries/sdformat { }; + }; + gbdfed = callPackage ../tools/misc/gbdfed { gtk = gtk2; };