about summary refs log tree commit diff
diff options
context:
space:
mode:
authorPatrick Callahan <pxcallahan@gmail.com>2016-03-26 11:11:48 -0700
committerPatrick Callahan <pxcallahan@gmail.com>2016-03-28 11:44:37 -0700
commit3c95d6d1ea52539c772aa869cd2bc5a919730fc3 (patch)
treeb76740fc300b535410f2578d569d4f6f81b57e2f
parentb682906b6a8ab52f947f7878819bbc72a03c19ba (diff)
sdformat: init at 3.7.0 and 4.0.0
-rw-r--r--pkgs/development/libraries/sdformat/3.nix7
-rw-r--r--pkgs/development/libraries/sdformat/default.nix23
-rw-r--r--pkgs/top-level/all-packages.nix8
3 files changed, 38 insertions, 0 deletions
diff --git a/pkgs/development/libraries/sdformat/3.nix b/pkgs/development/libraries/sdformat/3.nix
new file mode 100644
index 0000000000000..116f248b3b4e8
--- /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 0000000000000..0245b47815e52
--- /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 f7386d8f3b03b..b4052536305eb 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;
   };