Skip to content

Commit

Permalink
[skip.all] Minor update
Browse files Browse the repository at this point in the history
  • Loading branch information
TLCFEM committed Dec 11, 2024
1 parent 1cd3d56 commit f1d5106
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 18 deletions.
2 changes: 1 addition & 1 deletion Script/Rocky.Pre.arm64.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM arm64v8/rockylinux:9 AS build
FROM --platform=arm64 rockylinux:9 AS build

Check warning on line 1 in Script/Rocky.Pre.arm64.Dockerfile

View workflow job for this annotation

GitHub Actions / ide-image-base (arm64)

FROM --platform flag should not use a constant value

FromPlatformFlagConstDisallowed: FROM --platform flag should not use constant value "arm64" More info: https://docs.docker.com/go/dockerfile/rule/from-platform-flag-const-disallowed/

RUN dnf install -y epel-release && crb enable
RUN dnf install -y gcc g++ gfortran cmake wget git hdf5-devel
Expand Down
27 changes: 10 additions & 17 deletions Script/Rocky.arm64.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,32 +1,25 @@
FROM arm64v8/rockylinux:9 AS build

RUN dnf install -y epel-release && crb enable
RUN dnf install -y gcc g++ gfortran cmake wget git hdf5-devel

# part 1: openblas
RUN git clone --depth 1 --branch v0.3.28 https://github.com/OpenMathLib/OpenBLAS.git

# change the following configurations to match your needs
RUN cd OpenBLAS && make TARGET=ARMV8 DYNAMIC_ARCH=1 BINARY=64 USE_THREAD=1 USE_OPENMP=1 NUM_THREADS=20 NO_SHARED=1 NO_CBLAS=1 NO_LAPACKE=1 GEMM_MULTITHREAD_THRESHOLD=64

# part 2: tbb
RUN git clone --depth 1 --branch v2021.12.0 https://github.com/oneapi-src/oneTBB.git
RUN mkdir tbb-build && cd tbb-build && cmake -DCMAKE_BUILD_TYPE=Release -DTBB_TEST=OFF ../oneTBB && cmake --build . --target install --config Release --parallel "$(nproc)"
FROM --platform=arm64 tlcfem/suanpan-env:latest AS build

# part 3: suanpan
RUN git clone --depth 1 --branch dev https://github.com/TLCFEM/suanPan.git

RUN cd suanPan && mkdir build && cd build && cmake -DCMAKE_BUILD_TYPE=Release -DUSE_SYS_LIB=ON -DCUSTOM_OPENBLAS=/OpenBLAS -DBUILD_MULTITHREAD=ON -DUSE_HDF5=ON -DUSE_VTK=OFF -DUSE_AVX2=OFF .. && make -j"$(nproc)"

FROM arm64v8/rockylinux:9 AS runtime
FROM --platform=arm64 rockylinux:9 AS runtime

RUN dnf install -y epel-release && crb enable
RUN dnf install -y libgomp hdf5

COPY --from=build /tbb-build /tbb-build

RUN cd /tbb-build && make install && cd .. && rm -rf tbb-build
RUN find /tbb-build -name "libtbb*.so*" -exec cp {} /usr/local/lib64 \;

RUN rm -rf tbb-build

COPY --from=build /suanPan/build/suanPan /usr/local/bin/suanPan

RUN suanPan -v
RUN ln -s /usr/local/bin/suanPan /usr/local/bin/suanpan
RUN ln -s /usr/local/bin/suanPan /usr/local/bin/sp

RUN sp -v

0 comments on commit f1d5106

Please sign in to comment.