Skip to content

Commit e697789

Browse files
committed
CI: Build ABACUS with Ninja generator
1 parent 2ffe7ab commit e697789

6 files changed

Lines changed: 20 additions & 13 deletions

File tree

.github/workflows/ase_plugin_test.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ jobs:
3939
4040
- name: Install external tools from toolchain
4141
run: |
42-
apt update && apt install -y xz-utils
42+
apt update && apt install -y xz-utils ninja-build
4343
cd toolchain
4444
./install_abacus_toolchain_new.sh --with-dftd4=install --dry-run -j8
4545
./scripts/stage4/install_stage4.sh
@@ -54,7 +54,7 @@ jobs:
5454
export CMAKE_PREFIX_PATH=${PEXSI32_ROOT}:${SUPERLU_DIST32_ROOT}:${PARMETIS32_ROOT}:${METIS32_ROOT}:${GKLIB_ROOT}:${CMAKE_PREFIX_PATH}
5555
source toolchain/install/setup
5656
rm -rf build
57-
cmake -B build
57+
cmake -B build -G Ninja
5858
cmake --build build -j2
5959
6060
- name: Install and Soft Link ABACUS

.github/workflows/build_test_cmake.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ jobs:
6161

6262
- name: Install external tools from toolchain
6363
run: |
64-
apt update && apt install -y gfortran xz-utils
64+
apt update && apt install -y gfortran ninja-build xz-utils
6565
cd toolchain
6666
./install_abacus_toolchain_new.sh --with-dftd4=install --dry-run ${{matrix.external_toolchain_args}}
6767
./scripts/stage4/install_stage4.sh
@@ -76,5 +76,5 @@ jobs:
7676
export CMAKE_PREFIX_PATH=${PEXSI32_ROOT}:${SUPERLU_DIST32_ROOT}:${PARMETIS32_ROOT}:${METIS32_ROOT}:${GKLIB_ROOT}:${CMAKE_PREFIX_PATH}
7777
source toolchain/install/setup
7878
rm -rf build
79-
cmake -B build ${{ matrix.build_args }}
80-
cmake --build build -j2
79+
cmake -B build -G Ninja ${{ matrix.build_args }}
80+
cmake --build build -j $(nproc)

.github/workflows/coverage.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323

2424
- name: Install Perl Dependencies and Coverage Tools
2525
run: |
26-
apt update && apt install -y curl jq ca-certificates python3-pip xz-utils
26+
apt update && apt install -y curl jq ca-certificates python3-pip xz-utils ninja-build
2727
apt install -y lcov perl-modules
2828
apt install -y libcapture-tiny-perl libdatetime-perl libjson-perl libperlio-gzip-perl
2929
lcov --version
@@ -44,7 +44,7 @@ jobs:
4444
mkdir -p build
4545
chmod -R 755 build/
4646
47-
cmake -B build \
47+
cmake -B build -G Ninja \
4848
-DENABLE_COVERAGE=ON \
4949
-DBUILD_TESTING=ON \
5050
-DENABLE_MLALGO=ON \

.github/workflows/cuda.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
- name: Install Ccache
3333
run: |
3434
sudo apt-get update
35-
sudo apt-get install -y ccache xz-utils
35+
sudo apt-get install -y ccache xz-utils ninja-build
3636
3737
- name: Install external tools from toolchain
3838
run: |
@@ -46,7 +46,7 @@ jobs:
4646
nvidia-smi
4747
source toolchain/install/setup
4848
rm -rf build
49-
cmake -B build -DUSE_CUDA=ON -DBUILD_TESTING=ON
49+
cmake -B build -G Ninja -DUSE_CUDA=ON -DBUILD_TESTING=ON
5050
cmake --build build -j4
5151
cmake --install build
5252

.github/workflows/dynamic.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,15 @@ jobs:
2020
uses: actions/checkout@v7
2121
- name: Install external tools from toolchain
2222
run: |
23-
apt update && apt install -y xz-utils
23+
apt update && apt install -y xz-utils ninja-build
2424
cd toolchain
2525
./install_abacus_toolchain_new.sh --with-dftd4=install --dry-run -j8
2626
./scripts/stage4/install_stage4.sh
2727
cd ..
2828
- name: Building
2929
run: |
3030
source toolchain/install/setup
31-
cmake -B build -DENABLE_ASAN=1 -DENABLE_MLALGO=1 -DENABLE_LIBXC=1
31+
cmake -B build -G Ninja -DENABLE_ASAN=1 -DENABLE_MLALGO=1 -DENABLE_LIBXC=1
3232
cmake --build build -j8
3333
cmake --install build
3434
- name: Testing

.github/workflows/test.yml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,14 @@ jobs:
3636
- name: Install CI tools
3737
run: |
3838
sudo apt-get update
39-
sudo apt-get install -y gfortran ccache ca-certificates python-is-python3 python3-pip
39+
sudo apt-get install -y \
40+
gfortran \
41+
ccache \
42+
ca-certificates \
43+
python-is-python3 \
44+
python3-pip \
45+
ninja-build \
46+
xz-utils
4047
sudo pip install clang-format clang-tidy
4148
4249
- name: Install external tools from toolchain
@@ -49,7 +56,7 @@ jobs:
4956
- name: Configure
5057
run: |
5158
source toolchain/install/setup
52-
cmake -B build \
59+
cmake -B build -G Ninja \
5360
-DBUILD_TESTING=ON \
5461
-DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
5562
-DENABLE_MLALGO=ON \

0 commit comments

Comments
 (0)