Skip to content

Commit

Permalink
Github workflows: clang static build
Browse files Browse the repository at this point in the history
  • Loading branch information
mnottale committed Nov 15, 2023
1 parent 3636971 commit 262e0fb
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/build-linux-clang-libcxx-static.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Linux

on:
push:
branches: [ "master" ]
#pull_request:
# branches: [ "master" ]

env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release

jobs:
build:
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: dependencies
run: sudo apt-get install -y clang libc++ wget
- name: Version
run: cd $GITHUB_WORKSPACE && git describe --always > /tmp/version.txt
- name: Boost
run: cd $GITHUB_WORKSPACE && mkdir _boost && cd _boost && wget https://boostorg.jfrog.io/artifactory/main/release/1.82.0/source/boost_1_82_0.tar.bz2 && tar xf boost_1_82_0.tar.bz2 && cd boost_1_82_0 && ./bootstrap.sh && ./b2 toolset=clang cxxflags="-stdlib=libc++" linkflags="-stdlib=libc++" link=static install --prefix=$GITHUB_WORKSPACE/boostinst
- name: Configure
run: mkdir $GITHUB_WORKSPACE/build && cd $GITHUB_WORKSPACE/build && BOOST_ROOT=$GITHUB_WORKSPACE/boostinst/ cmake -D CMAKE_INCLUDE_PATH=$GITHUB_WORKSPACE/boostinst/include -D CMAKE_LIBRARY_PATH=$GITHUB_WORKSPACE/boostinst/lib -D CMAKE_C_COMPILER=clang -D CMAKE_CXX_COMPILER=clang++ -D CMAKE_CXX_STANDARD=17 -D CMAKE_CXX_FLAGS="-stdlib=libc++ -fno-delete-null-pointer-checks -fPIC" -DSTATIC_BUILD=On -DWITH_EMBED=On -DBoost_NO_SYSTEM_PATHS=On -DCMAKE_INSTALL_PREFIX=/tmp/urbisdk -DCMAKE_BUILD_TYPE=Release -DBoost_USE_STATIC_LIBS=On ..
- name: Build
# Build your program with the given configuration
run: cd $GITHUB_WORKSPACE/build && make -j $(nproc)
- name: Install
# Build your program with the given configuration
run: cd $GITHUB_WORKSPACE/build && make install -j $(nproc)
- uses: actions/upload-artifact@v3
with:
name: urbisdk-linux-clang-static
path: /tmp/urbisdk

0 comments on commit 262e0fb

Please sign in to comment.