summary refs log tree commit diff
path: root/pkgs/development
diff options
context:
space:
mode:
authorRobert Scott <code@humanleg.org.uk>2015-02-22 13:31:35 +0000
committerRobert Scott <code@humanleg.org.uk>2015-02-22 14:34:24 +0000
commit4147050550367c9aa64a04e94f9d2b8b4a67f492 (patch)
tree28b1e5daf22d3e52da7ebc9a55691220962995ff /pkgs/development
parentd44573e16f3072d02714e1beeaf34e24fc808a62 (diff)
downloadnixpkgs-4147050550367c9aa64a04e94f9d2b8b4a67f492.tar
nixpkgs-4147050550367c9aa64a04e94f9d2b8b4a67f492.tar.gz
nixpkgs-4147050550367c9aa64a04e94f9d2b8b4a67f492.tar.bz2
nixpkgs-4147050550367c9aa64a04e94f9d2b8b4a67f492.tar.lz
nixpkgs-4147050550367c9aa64a04e94f9d2b8b4a67f492.tar.xz
nixpkgs-4147050550367c9aa64a04e94f9d2b8b4a67f492.tar.zst
nixpkgs-4147050550367c9aa64a04e94f9d2b8b4a67f492.zip
add a (slightly naive) packaging of osrm-backend and its missing dependencies
Diffstat (limited to 'pkgs/development')
-rw-r--r--pkgs/development/libraries/libosmpbf/default.nix22
-rw-r--r--pkgs/development/libraries/luabind/0.9.1_boost_1.57_fix.patch23
-rw-r--r--pkgs/development/libraries/luabind/0.9.1_modern_boost_fix.patch59
-rw-r--r--pkgs/development/libraries/luabind/default.nix28
-rw-r--r--pkgs/development/libraries/stxxl/default.nix24
5 files changed, 156 insertions, 0 deletions
diff --git a/pkgs/development/libraries/libosmpbf/default.nix b/pkgs/development/libraries/libosmpbf/default.nix
new file mode 100644
index 00000000000..6ff5d816776
--- /dev/null
+++ b/pkgs/development/libraries/libosmpbf/default.nix
@@ -0,0 +1,22 @@
+{stdenv, fetchurl, protobuf}:
+
+stdenv.mkDerivation rec {
+  name = "libosmpbf-1.3.3";
+
+  src = fetchurl {
+    url = "https://github.com/scrosby/OSM-binary/archive/v1.3.3.tar.gz";
+    sha256 = "a109f338ce6a8438a8faae4627cd08599d0403b8977c185499de5c17b92d0798";
+  };
+
+  buildInputs = [ protobuf ];
+
+  sourceRoot = "OSM-binary-1.3.3/src";
+
+  installFlags = "PREFIX=$(out)";
+
+  meta = {
+    homepage = https://github.com/scrosby/OSM-binary;
+    description = "C library to read and write OpenStreetMap PBF files.";
+    license = stdenv.lib.licenses.lgpl3;
+  };
+}
diff --git a/pkgs/development/libraries/luabind/0.9.1_boost_1.57_fix.patch b/pkgs/development/libraries/luabind/0.9.1_boost_1.57_fix.patch
new file mode 100644
index 00000000000..7ac495777b5
--- /dev/null
+++ b/pkgs/development/libraries/luabind/0.9.1_boost_1.57_fix.patch
@@ -0,0 +1,23 @@
+diff --git a/luabind/object.hpp b/luabind/object.hpp
+index f7b7ca5..1c18e04 100644
+--- a/luabind/object.hpp
++++ b/luabind/object.hpp
+@@ -536,6 +536,8 @@ namespace detail
+       handle m_key;
+   };
+ 
++#if BOOST_VERSION < 105700
++
+ // Needed because of some strange ADL issues.
+ 
+ #define LUABIND_OPERATOR_ADL_WKND(op) \
+@@ -557,7 +559,8 @@ namespace detail
+   LUABIND_OPERATOR_ADL_WKND(!=)
+ 
+ #undef LUABIND_OPERATOR_ADL_WKND
+- 
++
++#endif // BOOST_VERSION < 105700 
+ } // namespace detail
+ 
+ namespace adl
diff --git a/pkgs/development/libraries/luabind/0.9.1_modern_boost_fix.patch b/pkgs/development/libraries/luabind/0.9.1_modern_boost_fix.patch
new file mode 100644
index 00000000000..92e32828a03
--- /dev/null
+++ b/pkgs/development/libraries/luabind/0.9.1_modern_boost_fix.patch
@@ -0,0 +1,59 @@
+diff --git luabind-0.9.1/luabind/detail/call_function.hpp luabind-0.9.1-fixed/luabind/detail/call_function.hpp
+index 1b45ec1..8f5afff 100644
+--- luabind-0.9.1/luabind/detail/call_function.hpp
++++ luabind-0.9.1-fixed/luabind/detail/call_function.hpp
+@@ -323,7 +323,8 @@ namespace luabind
+ 
+ #endif // LUABIND_CALL_FUNCTION_HPP_INCLUDED
+ 
+-#elif BOOST_PP_ITERATION_FLAGS() == 1
++#else
++#if BOOST_PP_ITERATION_FLAGS() == 1
+ 
+ #define LUABIND_TUPLE_PARAMS(z, n, data) const A##n *
+ #define LUABIND_OPERATOR_PARAMS(z, n, data) const A##n & a##n
+@@ -440,4 +441,5 @@ namespace luabind
+ 
+ 
+ #endif
++#endif
+ 
+diff --git luabind-0.9.1/luabind/detail/call_member.hpp luabind-0.9.1-fixed/luabind/detail/call_member.hpp
+index de8d563..e63555b 100644
+--- luabind-0.9.1/luabind/detail/call_member.hpp
++++ luabind-0.9.1-fixed/luabind/detail/call_member.hpp
+@@ -316,7 +316,8 @@ namespace luabind
+ 
+ #endif // LUABIND_CALL_MEMBER_HPP_INCLUDED
+ 
+-#elif BOOST_PP_ITERATION_FLAGS() == 1
++#else
++#if BOOST_PP_ITERATION_FLAGS() == 1
+ 
+ #define LUABIND_TUPLE_PARAMS(z, n, data) const A##n *
+ #define LUABIND_OPERATOR_PARAMS(z, n, data) const A##n & a##n
+@@ -360,4 +361,5 @@ namespace luabind
+ #undef LUABIND_TUPLE_PARAMS
+ 
+ #endif
++#endif
+ 
+diff --git luabind-0.9.1/luabind/wrapper_base.hpp luabind-0.9.1-fixed/luabind/wrapper_base.hpp
+index d54c668..0f88cc5 100755
+--- luabind-0.9.1/luabind/wrapper_base.hpp
++++ luabind-0.9.1-fixed/luabind/wrapper_base.hpp
+@@ -89,7 +89,8 @@ namespace luabind
+ 
+ #endif // LUABIND_WRAPPER_BASE_HPP_INCLUDED
+ 
+-#elif BOOST_PP_ITERATION_FLAGS() == 1
++#else
++#if BOOST_PP_ITERATION_FLAGS() == 1
+ 
+ #define LUABIND_TUPLE_PARAMS(z, n, data) const A##n *
+ #define LUABIND_OPERATOR_PARAMS(z, n, data) const A##n & a##n
+@@ -188,3 +189,4 @@ namespace luabind
+ #undef N
+ 
+ #endif
++#endif
diff --git a/pkgs/development/libraries/luabind/default.nix b/pkgs/development/libraries/luabind/default.nix
new file mode 100644
index 00000000000..d89229541cd
--- /dev/null
+++ b/pkgs/development/libraries/luabind/default.nix
@@ -0,0 +1,28 @@
+{stdenv, fetchurl, boost-build, lua, boost}:
+
+stdenv.mkDerivation rec {
+  name = "luabind-0.9.1";
+
+  src = fetchurl {
+    url = "https://github.com/luabind/luabind/archive/v0.9.1.tar.gz";
+    sha256 = "0e5ead50a07668d29888f2fa6f53220f900c886e46a2c99c7e8656842f05ff2d";
+  };
+
+  patches = [ ./0.9.1_modern_boost_fix.patch ./0.9.1_boost_1.57_fix.patch ];
+
+  buildInputs = [ boost-build lua boost ];
+
+  buildPhase = "LUA_PATH=${lua} bjam release";
+
+  installPhase = "LUA_PATH=${lua} bjam --prefix=$out release install";
+
+  passthru = {
+    inherit lua;
+  };
+
+  meta = {
+    homepage = https://github.com/luabind/luabind;
+    description = "Luabind is a library that helps you create bindings between C++ and Lua.";
+    license = stdenv.lib.licenses.mit;
+  };
+}
diff --git a/pkgs/development/libraries/stxxl/default.nix b/pkgs/development/libraries/stxxl/default.nix
new file mode 100644
index 00000000000..b387c59efa1
--- /dev/null
+++ b/pkgs/development/libraries/stxxl/default.nix
@@ -0,0 +1,24 @@
+{stdenv, fetchurl, cmake, parallel ? true }:
+
+stdenv.mkDerivation rec {
+  name = "stxxl-1.4.1";
+
+  src = fetchurl {
+    url = "https://github.com/stxxl/stxxl/archive/1.4.1.tar.gz";
+    sha256 = "54006a5fccd1435abc2f3ec201997a4d7dacddb984d2717f62191798e5372f6c";
+  };
+
+  buildInputs = [ cmake ];
+
+  cmakeFlags = let parallel_str = if parallel then "ON" else "OFF"; in "-DUSE_GNU_PARALLEL=${parallel_str}";
+
+  passthru = {
+    inherit parallel;
+  };
+
+  meta = {
+    homepage = https://github.com/stxxl/stxxl;
+    description = "STXXL is an implementation of the C++ standard template library STL for external memory (out-of-core) computations.";
+    license = stdenv.lib.licenses.boost;
+  };
+}