Skip to content

Commit 0127404

Browse files
committed
Attempt arm64 build too.
1 parent f867542 commit 0127404

File tree

2 files changed

+57
-0
lines changed

2 files changed

+57
-0
lines changed

.circleci/config.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,15 @@ jobs:
2525
- run:
2626
name: Build and test
2727
command: bash ./tools/circleci_bionic_conda_pagmo_head_39.sh
28+
ubuntu_arm64:
29+
machine:
30+
image: ubuntu-2004:202101-01
31+
resource_class: arm.medium
32+
steps:
33+
- checkout
34+
- run:
35+
name: Build and test
36+
command: bash ./tools/circleci_ubuntu_arm64.sh
2837

2938
workflows:
3039
version: 2.1
@@ -33,3 +42,4 @@ workflows:
3342
- bionic_conda_pagmo_head_38
3443
- bionic_conda_pagmo_head_37
3544
- bionic_conda_pagmo_head_39
45+
- ubuntu_arm64

tools/circleci_ubuntu_arm64.sh

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
#!/usr/bin/env bash
2+
3+
# Echo each command
4+
set -x
5+
6+
# Exit on error.
7+
set -e
8+
9+
# Core deps.
10+
sudo apt-get install wget
11+
12+
# Install conda+deps.
13+
wget https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-Linux-aarch64.sh -O miniconda.sh
14+
export deps_dir=$HOME/local
15+
export PATH="$HOME/miniconda/bin:$PATH"
16+
bash miniconda.sh -b -p $HOME/miniconda
17+
conda create -y -q -p $deps_dir c-compiler cxx-compiler cmake eigen nlopt boost-cpp tbb tbb-devel python=3.8 numpy cloudpickle networkx dill numba pybind11 scipy
18+
source activate $deps_dir
19+
20+
# Install pagmo.
21+
git clone https://github.com/esa/pagmo2.git
22+
cd pagmo2
23+
mkdir build
24+
cd build
25+
cmake ../ -DCMAKE_BUILD_TYPE=Debug -DBoost_NO_BOOST_CMAKE=ON -DPAGMO_WITH_EIGEN3=ON -DPAGMO_WITH_NLOPT=ON -DCMAKE_PREFIX_PATH=$deps_dir -DCMAKE_INSTALL_PREFIX=$deps_dir -DPAGMO_ENABLE_IPO=ON -DPAGMO_INSTALL_LIBDIR=lib
26+
make -j4 install VERBOSE=1
27+
cd ..
28+
cd ..
29+
30+
# Create the build dir and cd into it.
31+
mkdir build
32+
cd build
33+
34+
# Build pygmo.
35+
cmake ../ -DCMAKE_BUILD_TYPE=Debug -DBoost_NO_BOOST_CMAKE=ON -DCMAKE_PREFIX_PATH=$deps_dir -DCMAKE_INSTALL_PREFIX=$deps_dir -DPYGMO_ENABLE_IPO=ON
36+
make -j2 install VERBOSE=1
37+
cd
38+
39+
# Run the test suite.
40+
python -c "import pygmo; pygmo.test.run_test_suite(1); pygmo.mp_island.shutdown_pool(); pygmo.mp_bfe.shutdown_pool()"
41+
42+
# Run the additional tests.
43+
cd ~/project/tools
44+
python circleci_additional_tests.py
45+
46+
set +e
47+
set +x

0 commit comments

Comments
 (0)