-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
45 lines (38 loc) · 1.16 KB
/
Copy pathDockerfile
File metadata and controls
45 lines (38 loc) · 1.16 KB
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
# SPDX-License-Identifier: BSD-2-Clause OR GPL-2.0-only
#
# CI Dockerfile - copies source and builds in a single image.
# Used by GitHub Actions. For local development, use docker-compose.yml instead:
#
# docker compose run --rm build-gcc # Build with GCC
# docker compose run --rm build-clang # Build with Clang
# docker compose run --rm test-full # Build and test with all features
# docker compose run --rm shell # Interactive shell
#
FROM fedora:rawhide
RUN dnf install -y \
gcc-c++ \
clang \
cmake \
ninja-build \
pkgconf-pkg-config \
libfabric-devel \
git \
&& dnf clean all
WORKDIR /build
COPY . /src
ARG CC=gcc
ARG CXX=g++
ARG BUILD_TYPE=Release
ARG USE_STDEXEC=OFF
ARG USE_ASIO=OFF
RUN cmake -S /src -B /build -G Ninja \
-DCMAKE_C_COMPILER=${CC} \
-DCMAKE_CXX_COMPILER=${CXX} \
-DCMAKE_BUILD_TYPE=${BUILD_TYPE} \
-DLOOM_BUILD_TESTS=ON \
-DLOOM_USE_STDEXEC=${USE_STDEXEC} \
-DLOOM_FETCHCONTENT_STDEXEC=${USE_STDEXEC} \
-DLOOM_USE_ASIO=${USE_ASIO} \
-DLOOM_FETCHCONTENT_ASIO=${USE_ASIO}
RUN cmake --build /build --parallel
CMD ["ctest", "--test-dir", "/build", "--output-on-failure"]