-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathconfig.yml
105 lines (101 loc) · 3.14 KB
/
config.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
version: 2.1
# CircleCI doesn't handle large file sets properly for local builds
# https://github.com/CircleCI-Public/circleci-cli/issues/281#issuecomment-472808051
localCheckout: &localCheckout
run: |-
PROJECT_PATH=$(cd ${CIRCLE_WORKING_DIRECTORY}; pwd)
mkdir -p ${PROJECT_PATH}
cd /tmp/_circleci_local_build_repo
git ls-files -z | xargs -0 -s 2090860 tar -c | tar -x -C ${PROJECT_PATH}
cp -a /tmp/_circleci_local_build_repo/.git ${PROJECT_PATH}
jobs:
ubuntu_bionic:
description: A template for building and testing Quantum++ on Ubuntu Linux
machine:
image: ubuntu-2004:202010-01
steps:
- checkout # change this from "checkout" to "*localCheckout" when running CircleCI locally
- run:
name: Clone submodules
command: |
git submodule update --init
- run:
name: Install dependencies (Eigen3)
command: |
sudo apt-get update
sudo apt-get install -y libeigen3-dev
- run:
name: Install the library
command: |
mkdir build && cd build
cmake .. -DWITH_EXAMPLES=ON -DWITH_UNIT_TESTS=ON -DCMAKE_BUILD_TYPE=Debug
sudo make install
- run:
name: Compile and run a standalone example
command: |
cd examples/standalone && mkdir build && cd build
cmake .. -DCMAKE_BUILD_TYPE=Debug && make -j2
./standalone
- run:
name: Build the examples
command: |
cd build
make -j2 examples
- run:
name: Build the unit tests
command: |
cd build
make -j2 unit_tests
- run:
name: Run the unit tests
command: |
cd build
ctest -E qpp_Timer
macOS:
description: A template for building and testing Quantum++ on macOS
macos:
xcode: "13.2.1"
steps:
- checkout # change this from "checkout" to "*localCheckout" when running CircleCI locally
- run:
name: Clone submodules
command: |
git submodule update --init
- run:
name: Install dependencies (Eigen3)
command: |
brew update && brew install eigen
- run:
name: Install the library
command: |
mkdir build && cd build
cmake .. -DWITH_EXAMPLES=ON -DWITH_UNIT_TESTS=ON -DCMAKE_BUILD_TYPE=Debug
sudo make install
- run:
name: Compile and run a standalone example
command: |
cd examples/standalone && mkdir build && cd build
cmake .. -DCMAKE_BUILD_TYPE=Debug && make -j2
./standalone
- run:
name: Build the examples
command: |
cd build
make -j2 examples
- run:
name: Build the unit tests
command: |
cd build
make -j2 unit_tests
- run:
name: Run the unit tests
command: |
cd build
ctest -E qpp_Timer
workflows:
build:
jobs:
- ubuntu_bionic:
name: ubuntu-bionic
# - macOS:
# name: macOS-base