Open shacker27 opened 6 years ago
@shacker27 i reproduced the issue as
docker run -v /home/miha/mapbox/osrm-backend:/osrm-host --security-opt seccomp=unconfined -it centos:6.9 /bin/bash
yum install yum-utils centos-release-scl
yum-config-manager --enable rhel-server-rhscl-6-rpms
yum install devtoolset-6
yum install git cmake zlib-devel wget autoconf automake
scl enable devtoolset-6 bash
cd
wget http://ftp.gnu.org/gnu/glibc/glibc-2.14.tar.gz
tar xvzf glibc-2.14.tar.gz
cd glibc-2.14 && mkdir build && cd build
sed -i 's/3\.4\* | 4\.\[0-9\]\* )/3.4* | 4.[0-9]* | 6.* )/g' ../configure
sed -i 's/3\.79\* | 3\.\[89\]\*)/3.79* | 3.[89]* | 4.* )/g' ../configure
../configure --prefix=/opt/glibc-2.14
make -j4
make install
cd
git clone https://github.com/Project-OSRM/osrm-backend.git osrm-backend
mkdir osrm-backend/build
cd osrm-backend/build
cmake .. -DENABLE_MASON=ON -DCMAKE_BUILD_TYPE=Debug
make -j4
wget http://download.geofabrik.de/europe/germany/berlin-latest.osm.pbf
export LD_LIBRARY_PATH=/opt/glibc-2.14/lib
./osrm-extract -p ../profiles/car.lua berlin-latest.osm.pbf
The problem here is in TBB installed by mason.
After a change of
mason_use(tbb VERSION ${MASON_TBB_VERSION})
add_dependency_includes(${MASON_PACKAGE_tbb_INCLUDE_DIRS})
set(TBB_LIBRARIES ${MASON_PACKAGE_tbb_LDFLAGS})
in CMakeLists.txt to
find_package(TBB REQUIRED)
add_dependency_includes(${TBB_INCLUDE_DIR})
if(WIN32 AND CMAKE_BUILD_TYPE MATCHES Debug)
set(TBB_LIBRARIES ${TBB_DEBUG_LIBRARIES})
endif()
and making a local TBB build
cd
wget https://github.com/01org/tbb/archive/2018_U1.zip
unzip 2018_U1.zip
cd tbb-2018_U1
make -j4
cd /root/osrm-backend/build
export LD_LIBRARY_PATH=/opt/glibc-2.14/lib:/root/tbb-2018_U1/build/linux_intel64_gcc_cc6.3.1_libc2.14_kernel4.10.0_release
cmake .. -DENABLE_MASON=ON -DCMAKE_BUILD_TYPE=Debug -DTBB_INSTALL_DIR=/root/tbb-2018_U1
./osrm-extract -p ../profiles/car.lua berlin-latest.osm.pbf
osrm-extract
works without hanging at TBB code.
Hey @oxidase thanks for verifying this! I've been battling it for a while so incredibly helpful to see what the issue is.
When I change CMakeLists.txt
as specified above and add the -DTBB_INSTALL_DIR
to the cmake
command, I get the following error:
CMake Error at CMakeLists.txt:470 (message):
MASON_PACKAGE_tbb_LIBRARY_DIRS is empty, rpath will not work
I am by no means a cmake expert but commenting out
if(NOT MASON_PACKAGE_tbb_LIBRARY_DIRS)
message(FATAL_ERROR "MASON_PACKAGE_tbb_LIBRARY_DIRS is empty, rpath will not work")
endif()
allows me to build and things seem to be working.
This issue seems to be stale. It will be closed in 30 days if no further activity occurs.
I'm trying to build and run
osrm-extract
(v5.13.0) on CentOS 6.9 and have followed these instructions to build the package. The only exception is that I am building OSRM in debug mode so I include symbols.When attempting to extract the example Berlin pbf via
/usr/local/bin/osrm-extract -p /usr/local/share/osrm/profiles/car.lua berlin-latest.osm.pbf
I see several lines of log output, up untilParse relations ...
(seems like this line), at which point the program just hangs forever.Running the program in gdb and telling gdb to catch exceptions, I get the following stack trace (Note: Program log output included for context):
I've built my glibc-2.14 installation in
/opt/glibc-2.14
and you can see whatosrm-extract
is linking to with the output ofldd
below: