Merge pull request #6867 from risicle/master
New packages for luabind, stxxl and osrm-backend
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
diff --git a/extractor/extractor_options.cpp b/extractor/extractor_options.cpp
|
||||
index d14d8d9..c64d7fd 100644
|
||||
--- a/extractor/extractor_options.cpp
|
||||
+++ b/extractor/extractor_options.cpp
|
||||
@@ -50,7 +50,7 @@ bool ExtractorOptions::ParseArguments(int argc, char *argv[], ExtractorConfig &e
|
||||
boost::program_options::options_description config_options("Configuration");
|
||||
config_options.add_options()("profile,p",
|
||||
boost::program_options::value<boost::filesystem::path>(
|
||||
- &extractor_config.profile_path)->default_value("profile.lua"),
|
||||
+ &extractor_config.profile_path)->default_value("@out@/profiles/car.lua"),
|
||||
"Path to LUA routing profile")(
|
||||
"threads,t",
|
||||
boost::program_options::value<unsigned int>(&extractor_config.requested_num_threads)
|
||||
@@ -0,0 +1,18 @@
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index b6a40f9..87ca301 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -261,9 +261,10 @@ target_link_libraries(OSRM ${STXXL_LIBRARY})
|
||||
target_link_libraries(osrm-extract ${STXXL_LIBRARY})
|
||||
target_link_libraries(osrm-prepare ${STXXL_LIBRARY})
|
||||
|
||||
-if(MINGW)
|
||||
- # STXXL needs OpenMP library
|
||||
- target_link_libraries(osrm-extract gomp)
|
||||
+find_package(OpenMP)
|
||||
+if (OPENMP_FOUND)
|
||||
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS}")
|
||||
+ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${OpenMP_CXX_FLAGS}")
|
||||
endif()
|
||||
|
||||
find_package( OSMPBF REQUIRED )
|
||||
@@ -0,0 +1,27 @@
|
||||
{stdenv, fetchurl, cmake, luabind, libosmpbf, stxxl, tbb, boost, expat, protobuf, bzip2, zlib, substituteAll}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "osrm-backend-4.5.0";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/Project-OSRM/osrm-backend/archive/v4.5.0.tar.gz";
|
||||
sha256 = "af61e883051f2ecb73520ace6f17cc6da30edc413208ff7cf3d87992eca0756c";
|
||||
};
|
||||
|
||||
patches = [
|
||||
./4.5.0-openmp.patch
|
||||
(substituteAll {
|
||||
src = ./4.5.0-default-profile-path.template.patch;
|
||||
})
|
||||
];
|
||||
|
||||
buildInputs = [ cmake luabind libosmpbf stxxl tbb boost expat protobuf bzip2 zlib ];
|
||||
|
||||
postInstall = "mkdir -p $out/share/osrm-backend && cp -r ../profiles $out/share/osrm-backend/profiles";
|
||||
|
||||
meta = {
|
||||
homepage = https://github.com/Project-OSRM/osrm-backend/wiki;
|
||||
description = "Open Source Routing Machine computes shortest paths in a graph. It was designed to run well with map data from the Openstreetmap Project.";
|
||||
license = stdenv.lib.licenses.bsd2;
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user