Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build on Arch Linux #6282

Closed
vklachkov opened this issue Jul 15, 2022 · 1 comment
Closed

Build on Arch Linux #6282

vklachkov opened this issue Jul 15, 2022 · 1 comment

Comments

@vklachkov
Copy link

I researched building osrm-backend on Arch Linux.
Perhaps someone will be interested

Dependencies

Some dependencies were installed before the build started. If something is missing from the list, write, I will add

  • clang
  • libc++
  • cmake
  • boost
  • lua52

Clang 14 was chosen as the compiler. For some reason, GCC 12 gives a lot of errors

Build

Build old tbb

Download source code from ubuntu repository

wget http://archive.ubuntu.com/ubuntu/pool/universe/t/tbb/tbb_2017~U7.orig.tar.xz

Unpack

tar xf tbb_2017\~U7.orig.tar.xz

cd tbb-2017_U7

Build

Check parameters:

make compiler=clang info

My output:

OS: linux
arch=intel64
compiler=clang
runtime=cc12.1.0_libc2.35_kernel5.18.11
tbb_build_prefix=linux_intel64_clang_cc12.1.0_libc2.35_kernel5.18.11

And build:

CXXFLAGS="-std=c++14" make compiler=clang

Install

Copy includes:

sudo cp -r include/serial /usr/include/

sudo cp -r include/tbb /usr/include/

Copy shared libraries:

sudo cp build/linux_intel64_clang_cc12.1.0_libc2.35_kernel5.18.11_release/libtbb* /lib64/

Build osrm-backend

Setup enviroment

export CXX=clang++

export CXXFLAGS="-std=c++14"

export CC=clang

Build

git clone --recursive https://github.com/Project-OSRM/osrm-backend/

cd osrm-backend

mkdir -p build

cd build

cmake .. \
        -DCMAKE_INSTALL_PREFIX=/usr \
        -DCMAKE_INSTALL_LIBDIR=lib \
        -DCMAKE_BUILD_TYPE=Release \
        -DBUILD_SHARED_LIBS=ON \
        -DLUA_INCLUDE_DIR=/usr/include

sudo make install

@vklachkov
Copy link
Author

Not actual after #6300

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant