File tree Expand file tree Collapse file tree 3 files changed +51
-6
lines changed Expand file tree Collapse file tree 3 files changed +51
-6
lines changed Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+
3
+ # SPDX-FileCopyrightText: 2020 Intel Corporation
4
+ #
5
+ # SPDX-License-Identifier: MIT
6
+
7
+ wget https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS-2023.PUB
8
+ sudo apt-key add GPG-PUB-KEY-INTEL-SW-PRODUCTS-2023.PUB
9
+ echo " deb https://apt.repos.intel.com/oneapi all main" | sudo tee /etc/apt/sources.list.d/oneAPI.list
10
+ sudo apt-get update -o Dir::Etc::sourcelist=" sources.list.d/oneAPI.list" -o APT::Get::List-Cleanup=" 0"
Original file line number Diff line number Diff line change
1
+ # based on: https://gist.github.com/scivision/b22455e3322826a1c385d5d4b1a8d25e
2
+
1
3
name : Build project
2
4
3
- on : [push]
5
+ env :
6
+ LINUX_CPP_COMPONENTS : intel-oneapi-compiler-dpcpp-cpp-and-cpp-classic
7
+ # https://github.com/oneapi-src/oneapi-ci/blob/master/.github/workflows/build_all.yml
8
+ CTEST_NO_TESTS_ACTION : error
9
+
10
+ on :
11
+ push :
12
+ paths :
13
+ - " **.cpp"
14
+ - " **.hpp"
15
+ - " CMakeLists.txt"
16
+ - " .github/workflows/*.yaml"
17
+ - " build.sh"
4
18
5
19
jobs :
6
- build :
20
+ linux :
7
21
runs-on : ubuntu-latest
8
22
9
23
steps :
10
- - name : Checkout repository
11
- uses : actions/checkout@v2
24
+ # must be first as we're using scripts from this repo
25
+ - uses : actions/checkout@v4
26
+
27
+ - name : cache install oneAPI
28
+ id : cache-install
29
+ uses : actions/cache@v3
30
+ with :
31
+ path : |
32
+ /opt/intel/oneapi
33
+ key : install-apt
12
34
13
- - name : Set up environment
14
- run : sudo apt-get update && sudo apt-get install -y build-essential
35
+ - name : non-cache install oneAPI
36
+ if : steps.cache-install.outputs.cache-hit != 'true'
37
+ timeout-minutes : 10
38
+ run : |
39
+ sh -c .github/workflow_scripts/oneapi_setup_apt_repo_linux.sh
40
+ sudo apt install ${{ env.LINUX_CPP_COMPONENTS }}
41
+
42
+ - name : Setup Intel oneAPI environment
43
+ run : |
44
+ source /opt/intel/oneapi/setvars.sh
45
+ printenv >> $GITHUB_ENV
15
46
16
47
- name : Run build script
17
48
run : ./build.sh
49
+
50
+ - name : exclude unused files from cache
51
+ if : steps.cache-install.outputs.cache-hit != 'true'
52
+ run : sh -c .github/workflow_scripts/oneapi_cache_exclude_linux.sh
You can’t perform that action at this time.
0 commit comments