Skip to content

Add SSH dependency and configuration to dev container #333

Add SSH dependency and configuration to dev container

Add SSH dependency and configuration to dev container #333

Workflow file for this run

name: Conan Create
on:
push:
pull_request:
schedule:
- cron: '0 0 * * *'
env:
CONAN_USER_HOME: "${{ github.workspace }}/release/"
CONAN_USER_HOME_SHORT: "${{ github.workspace }}/release/short"
CONAN_HOME: "${{ github.workspace }}/release/"
CCACHE_DIR: "${{ github.workspace }}/.ccache"
CCACHE_SLOPPINESS: include_file_ctime,include_file_mtime
jobs:
ubuntu-build:
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix:
compiler: [ [gcc,g++], [clang,clang++] ]
type: [ Release ]
timeout-minutes: 120
steps:
- name: Checkout source code
uses: actions/[email protected]
- name: Install build dependencies
run: |
sudo pip install -U conan
sudo apt-get install -yq --no-install-recommends ninja-build
- name: Setup Conan Profile
env:
CC: ${{ matrix.compiler[0] }}
CXX: ${{ matrix.compiler[1] }}
run: |
# build profile
conan profile detect -f
- name: Conan Cache
id: cache-conan
uses: actions/cache@v3
env:
cache-name: cache-conan2-modules
with:
path: ${{ env.CONAN_HOME }}
key: ${{ runner.os }}-builder-${{ env.cache-name }}-${{ matrix.compiler[0] }}-${{ matrix.type }}-${{ hashFiles('conanfile.py') }}
restore-keys: ${{ runner.os }}-builder-${{ env.cache-name }}-${{ matrix.compiler[0] }}-${{ matrix.type }}-
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
run: |
echo timestamp=`date +"%Y-%m-%d-%H;%M;%S"` >> $GITHUB_OUTPUT
- name: ccache Cache
uses: actions/cache@v3
with:
path: ${{ env.CCACHE_DIR }}
key: ${{ runner.os }}-ccache-${{ matrix.compiler[0] }}-${{ matrix.type }}-${{ steps.ccache_cache_timestamp.outputs.timestamp }}
restore-keys: |
${{ runner.os }}-ccache-${{ matrix.compiler[0] }}-${{ matrix.type }}-
- name: Create Celix
env:
CC: ${{ matrix.compiler[0] }}
CXX: ${{ matrix.compiler[1] }}
run: |
conan create . -c tools.cmake.cmaketoolchain:generator=Ninja -b missing -o celix/*:build_all=True -o celix/*:enable_ccache=True -pr:b default -pr:h default -s:h build_type=${{ matrix.type }} -tf examples/conan_test_package_v2 -o celix/*:celix_cxx17=True -o celix/*:celix_install_deprecated_api=True
- name: Dependency Deduction Test
env:
CC: ${{ matrix.compiler[0] }}
CXX: ${{ matrix.compiler[1] }}
run: |
conan inspect . | awk 'BEGIN { FS="[\t:]+"; output=0 } /build/ && !/build_all/ { if(output) print $1} /^options/ {output=1} /^options_definitions/ {output=0}' | while read option; do conan build . -c tools.cmake.cmaketoolchain:generator=Ninja -b missing -o celix/*:${option}=True -pr:b default -pr:h default -s:h build_type=${{ matrix.type }} -of ${option}_dir -o celix/*:celix_cxx17=True -o celix/*:enable_ccache=True -o celix/*:celix_install_deprecated_api=True || exit 1; done
- name: Remove Celix
run: |
conan remove -c celix/*
mac-build:
runs-on: macOS-11
timeout-minutes: 120
steps:
- name: Checkout source code
uses: actions/[email protected]
- name: Install build dependencies
run: |
brew install python ninja
pip3 install -U conan==1.59.0
- name: Setup Conan Profile
run: |
conan profile new default --detect
conan profile update settings.build_type=Release default
- name: Conan Cache
id: cache-conan
uses: actions/cache@v3
env:
cache-name: cache-conan-modules
with:
path: ${{ env.CONAN_USER_HOME }}
key: ${{ runner.os }}-builder-${{ env.cache-name }}-${{ hashFiles('conanfile.py') }}
restore-keys: ${{ runner.os }}-builder-${{ env.cache-name }}-
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
run: |
echo timestamp=`date +"%Y-%m-%d-%H;%M;%S"` >> $GITHUB_OUTPUT
- name: ccache Cache
uses: actions/cache@v3
with:
path: ${{ env.CCACHE_DIR }}
key: ${{ runner.os }}-ccache-Release-${{ steps.ccache_cache_timestamp.outputs.timestamp }}
restore-keys: |
${{ runner.os }}-ccache-Release-
- name: Create Celix
run: |
conan create . -c tools.cmake.cmaketoolchain:generator=Ninja -b missing -o celix:build_all=True -o celix:enable_ccache=True -pr:b default -pr:h default -tf examples/conan_test_package -tbf test-build -o celix:celix_cxx17=True -o celix:celix_install_deprecated_api=True --require-override=libcurl/7.64.1 --require-override=openssl/1.1.1s --require-override=zlib/1.2.13
- name: Dependency Deduction Test
run: |
conan inspect . -a options | awk 'BEGIN { FS="[\t:]+" } /build/ && !/build_all/ { print $1}' | while read option; do conan install . -c tools.cmake.cmaketoolchain:generator=Ninja -b missing -o celix:${option}=True -pr:b default -pr:h default -if ${option}_dir -o celix:celix_cxx17=True -o celix:celix_install_deprecated_api=True -o celix:enable_ccache=True --require-override=libcurl/7.64.1 --require-override=openssl/1.1.1s --require-override=zlib/1.2.13 || exit 1; conan build . -bf ${option}_dir || exit 1; done
- name: Remove Celix
run: |
conan remove -f 'celix/*'