Skip to content

Add Apache License #299

Add Apache License

Add Apache License #299

Workflow file for this run

##
## Copyright (c) 2014-2023 Key4hep-Project.
##
## This file is part of k4FWCore.
## See https://key4hep.github.io/key4hep-doc/ for further info.
##
## Licensed under the Apache License, Version 2.0 (the "License");
## you may not use this file except in compliance with the License.
## You may obtain a copy of the License at
##
## http://www.apache.org/licenses/LICENSE-2.0
##
## Unless required by applicable law or agreed to in writing, software
## distributed under the License is distributed on an "AS IS" BASIS,
## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
## See the License for the specific language governing permissions and
## limitations under the License.
##
name: linux
on: [push, pull_request]
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
cvmfs_base: ['sft.cern.ch/lcg/views']
ENVIRONMENT: ['dev3/latest/x86_64-centos7-gcc11-opt']
include:
- cvmfs_base: 'sw.hsf.org'
ENVIRONMENT: 'key4hep'
- cvmfs_base: 'sw-nightlies.hsf.org'
ENVIRONMENT: 'key4hep'
steps:
- uses: actions/checkout@v2
- uses: cvmfs-contrib/github-action-cvmfs@v2
- name: Start container
run: |
docker run -it --name CI_container -v ${GITHUB_WORKSPACE}:/Package -v /cvmfs:/cvmfs:shared -d ghcr.io/aidasoft/centos7:latest /bin/bash
- name: CMake Configure
run: |
docker exec CI_container /bin/bash -c 'cd Package;\
mkdir -p build install;\
source /cvmfs/${{ matrix.cvmfs_base }}/${{ matrix.ENVIRONMENT }}/setup.sh;\
cd build;\
cmake -DCMAKE_INSTALL_PREFIX=../install -DCMAKE_CXX_STANDARD=17 -DCMAKE_CXX_FLAGS=" -fdiagnostics-color=always " -G Ninja ..;'
- name: Compile
run: |
docker exec CI_container /bin/bash -c 'cd ./Package;\
source /cvmfs/${{ matrix.cvmfs_base }}/${{ matrix.ENVIRONMENT }}/setup.sh;\
cd build;\
ninja -k0;'
- name: Test
run: |
docker exec CI_container /bin/bash -c 'cd ./Package;\
source /cvmfs/${{ matrix.cvmfs_base }}/${{ matrix.ENVIRONMENT }}/setup.sh;\
cd build;\
ninja -k0 && ctest --output-on-failure;'
- name: Install
run: |
docker exec CI_container /bin/bash -c 'cd ./Package;\
source /cvmfs/${{ matrix.cvmfs_base }}/${{ matrix.ENVIRONMENT }}/setup.sh;\
cd build;\
ninja -k0 install;'