Skip to content

Commit 461e2de

Browse files
authored
Merge pull request #37 from troelsfr/feature/creating-build-matrix
New build matrix
2 parents ad95587 + 74ddb9d commit 461e2de

File tree

3 files changed

+69
-5
lines changed

3 files changed

+69
-5
lines changed

.github/workflows/cd-docs.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ on:
44
push:
55
branches:
66
- main
7-
7+
88
jobs:
99
build-and-deploy-docs:
1010
runs-on: ubuntu-latest

.github/workflows/cd-ubuntu-executable.yml .github/workflows/cd-linux-release.yml

+2-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
1-
#on:
2-
# push:
3-
# tags:
4-
# - 'v*'
1+
name: Linux Release
2+
53
on:
64
release:
75
types:

.github/workflows/cd-mac-release.yml

+66
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
name: Mac Release
2+
3+
on:
4+
release:
5+
types:
6+
- created
7+
8+
jobs:
9+
build:
10+
name: Upload Release Asset
11+
runs-on: macos-11
12+
steps:
13+
- name: Checkout code
14+
uses: actions/checkout@v2
15+
16+
- name: "Installing dependencies"
17+
run: |
18+
rm '/usr/local/bin/2to3'
19+
brew install llvm@11
20+
brew install cmake
21+
brew install python@3.9
22+
brew unlink python@3.9
23+
brew link python@3.9
24+
echo "/usr/local/opt/llvm@11/bin" >> $GITHUB_PATH
25+
git submodule update --init --recursive
26+
pip3 install --user -r requirements.txt
27+
dotnet tool install --global Microsoft.Quantum.IQSharp --version 0.20.2110171573
28+
chmod +x manage
29+
30+
exec -l $SHELL
31+
32+
- name: "Running unit tests"
33+
run: |
34+
./manage test
35+
env:
36+
LDFLAGS: "-L/usr/local/opt/llvm@11/lib -Wl,-rpath,/usr/local/opt/llvm@11/lib"
37+
CPPFLAGS: "-I/usr/local/opt/llvm@11/include"
38+
CC: clang
39+
CXX: clang++
40+
41+
- name: "Build project"
42+
run: |
43+
mkdir -p Release
44+
cd Release
45+
cmake .. -DMICROSOFT_ENABLE_DYNAMIC_LOADING=0
46+
make qat
47+
cd ..
48+
mv Release/qir/qat/Apps/qat ./
49+
chmod +x qat
50+
tar cf qat-mac.zip qat
51+
env:
52+
LDFLAGS: "-L/usr/local/opt/llvm@11/lib -Wl,-rpath,/usr/local/opt/llvm@11/lib"
53+
CPPFLAGS: "-I/usr/local/opt/llvm@11/include"
54+
CC: clang
55+
CXX: clang++
56+
57+
- name: Upload Release Asset
58+
id: upload-release-asset
59+
uses: actions/upload-release-asset@v1
60+
env:
61+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
62+
with:
63+
upload_url: ${{ github.event.release.upload_url }}
64+
asset_path: ./qat-mac.zip
65+
asset_name: qat-mac.zip
66+
asset_content_type: application/zip

0 commit comments

Comments
 (0)