Skip to content

Commit b2748e5

Browse files
authored
Merge pull request multi-build#140 from xhochy/strip-linux-binaries
Strip binaries on non-OSX builds
2 parents 3634d86 + 453308d commit b2748e5

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

configure_build.sh

+7
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,13 @@ if [ -n "$IS_OSX" ]; then
2525

2626
# Disable homebrew auto-update
2727
export HOMEBREW_NO_AUTO_UPDATE=1
28+
else
29+
# Strip all binaries after compilation.
30+
STRIP_FLAGS=${STRIP_FLAGS:-"-Wl,-strip-all"}
31+
32+
export CFLAGS="${CFLAGS:-$STRIP_FLAGS}"
33+
export CXXFLAGS="${CXXFLAGS:-$STRIP_FLAGS}"
34+
export FFLAGS="${FFLAGS:-$STRIP_FLAGS}"
2835
fi
2936

3037
# Promote BUILD_PREFIX on search path to any newly built libs

0 commit comments

Comments
 (0)