0

I am trying to set up OSRM-project on my linux server, however am experiencing issues while doing so. I have the latest versions of the dependencies, and have also installed and setup pthreads: pecl pthread install

then adding it to php, and recompiling php.

Below is the information:

Centos 6 64bit, trying to set up OSRM-Project.

downloading soure, then:

cd osrm-backend
mkdir -p build
cd build
cmake -D STXXL_LIBRARY=/usr/local/include/stxxl.h ..
make

Build fails on make:

Determining if the pthread_create exist failed with the following output: Change Dir: /var/www/html/osrm-backend/build/CMakeFiles/CMakeTmp

Run Build Command:"/usr/bin/gmake" "cmTryCompileExec3544628293/fast" /usr/bin/gmake -f CMakeFiles/cmTryCompileExec3544628293.dir/build.make CMakeFiles/cmTryCompileExec3544628293.dir/build gmake[1]: Entering directory /var/www/html/osrm-backend/build/CMakeFiles/CMakeTmp' /usr/local/bin/cmake -E cmake_progress_report /var/www/html/osrm-backend/build/CMakeFiles/CMakeTmp/CMakeFiles 1 Building C object CMakeFiles/cmTryCompileExec3544628293.dir/CheckSymbolExists.c.o /usr/local/bin/cc -o CMakeFiles/cmTryCompileExec3544628293.dir/CheckSymbolExists.c.o -c /var/www/html/osrm-backend/build/CMakeFiles/CMakeTmp/CheckSymbolExists.c Linking C executable cmTryCompileExec3544628293 /usr/local/bin/cmake -E cmake_link_script CMakeFiles/cmTryCompileExec3544628293.dir/link.txt --verbose=1 /usr/local/bin/cc
CMakeFiles/cmTryCompileExec3544628293.dir/CheckSymbolExists.c.o -o cmTryCompileExec3544628293 -rdynamic CMakeFiles/cmTryCompileExec3544628293.dir/CheckSymbolExists.c.o: In function
main': CheckSymbolExists.c:(.text+0x16): undefined reference to pthread_create' collect2: error: ld returned 1 exit status gmake[1]: *** [cmTryCompileExec3544628293] Error 1 gmake[1]: Leaving directory/var/www/html/osrm-backend/build/CMakeFiles/CMakeTmp' gmake: *** [cmTryCompileExec3544628293/fast] Error 2

File /var/www/html/osrm-backend/build/CMakeFiles/CMakeTmp/CheckSymbolExists.c: /* */ #include

int main(int argc, char** argv) { (void)argv; #ifndef pthread_create return ((int*)(&pthread_create))[argc]; #else (void)argc; return 0; #endif }

Determining if the function pthread_create exists in the pthreads failed with the following output: Change Dir: /var/www/html/osrm-backend/build/CMakeFiles/CMakeTmp

Run Build Command:"/usr/bin/gmake" "cmTryCompileExec4016411170/fast" /usr/bin/gmake -f CMakeFiles/cmTryCompileExec4016411170.dir/build.make CMakeFiles/cmTryCompileExec4016411170.dir/build gmake[1]: Entering directory /var/www/html/osrm-backend/build/CMakeFiles/CMakeTmp' /usr/local/bin/cmake -E cmake_progress_report /var/www/html/osrm-backend/build/CMakeFiles/CMakeTmp/CMakeFiles 1 Building C object CMakeFiles/cmTryCompileExec4016411170.dir/CheckFunctionExists.c.o /usr/local/bin/cc -DCHECK_FUNCTION_EXISTS=pthread_create -o CMakeFiles/cmTryCompileExec4016411170.dir/CheckFunctionExists.c.o -c /usr/local/share/cmake-3.1/Modules/CheckFunctionExists.c Linking C executable cmTryCompileExec4016411170 /usr/local/bin/cmake -E cmake_link_script CMakeFiles/cmTryCompileExec4016411170.dir/link.txt --verbose=1 /usr/local/bin/cc -DCHECK_FUNCTION_EXISTS=pthread_create CMakeFiles/cmTryCompileExec4016411170.dir/CheckFunctionExists.c.o -o cmTryCompileExec4016411170 -rdynamic -lpthreads /opt/rh/devtoolset-2/root/usr/libexec/gcc/x86_64-redhat-linux/4.8.2/ld: cannot find -lpthreads collect2: error: ld returned 1 exit status gmake[1]: *** [cmTryCompileExec4016411170] Error 1 gmake[1]: Leaving directory/var/www/html/osrm-backend/build/CMakeFiles/CMakeTmp'

4

0 回答 0