Skip to content
Snippets Groups Projects
Commit fd7b8875 authored by Wouter Deconinck's avatar Wouter Deconinck
Browse files

feat: strip /opt/software, not /usr/local; build_type Release

parent 1c5ff170
Branches
Tags
1 merge request!367feat: strip /opt/software, not /usr/local; build_type Release
......@@ -179,11 +179,14 @@ WORKDIR /
## ========================================================================================
FROM builder as staging
# Garbage collect in environment
RUN cd /opt/spack-environment && spack env activate . && spack gc -y
# Strip all the binaries
# This reduces the image by factor of x2, so worth the effort
# note that we do not strip python libraries as it can cause issues in some cases
RUN find -L /usr/local/* \
RUN du -sh /opt/software/linux-*/gcc-*/* | sort -h \
&& find -L /opt/software/* \
-type d -name site-packages -prune -false \
-o \
-type d -name lib-dynload -prune -false \
......@@ -193,7 +196,8 @@ RUN find -L /usr/local/* \
| xargs file -i \
| grep 'charset=binary' \
| grep 'x-executable\|x-sharedlib' \
| awk -F: '{print $1}' | xargs strip -s
| awk -F: '{print $1}' | xargs strip -s \
&& du -sh /opt/software/linux-*/gcc-*/* | sort -h
## Bugfix to address issues loading the Qt5 libraries on Linux kernels prior to 3.15
## See
......
......@@ -29,7 +29,7 @@ spack:
- nlohmann-json@3.10.5
- opencascade@7.6.0
- pkg-config@0.29.2
- podio@0.15 build_type=RelWithDebInfo
- podio@0.15
- pythia8@8.306 +fastjet
- python@3.10.4
- py-numpy@1.22.3
......@@ -47,4 +47,6 @@ spack:
packages:
all:
compiler: [gcc]
variants:
build_type=Release
view: /usr/local
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment