Skip to content
This repository has been archived by the owner on Aug 30, 2024. It is now read-only.

Commit

Permalink
Merge pull request #87 from seiko2plus/fix_strip
Browse files Browse the repository at this point in the history
Fix stripping binaries from debugging symbols
  • Loading branch information
charris authored May 6, 2020
2 parents 1c7c0dd + 1547c0d commit 11d6d89
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 2 deletions.
12 changes: 11 additions & 1 deletion env_vars.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
#!/usr/bin/env bash
# Environment variables for build
OPENBLAS_VERSION="v0.3.7"
MACOSX_DEPLOYMENT_TARGET=10.9
CFLAGS="-std=c99 -fno-strict-aliasing"
LDFLAGS="-Wl,--strip-debug"
# Macos's linker doesn't support stripping symbols
if [ "$(uname)" != "Darwin" ]; then
LDFLAGS="-Wl,--strip-debug"
# make sure that LDFLAGS is exposed to child processes,
# since current version of manybuild only export CFLAGS, CPPFLAGS and FFLAGS
export LDFLAGS="$LDFLAGS"
# override the default stripping flags, since we only override CFLAGS and
# the current version of manybuild pass "-strip-all" to CPPFLAGS and FFLAGS
STRIP_FLAGS=""
fi
12 changes: 11 additions & 1 deletion env_vars_32.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#!/usr/bin/env bash
# Environment variables for 32-bit build.
# The important difference from the 64-bit build is `-msse2` to
# compile sse loops for ufuncs.
Expand All @@ -7,4 +8,13 @@ MACOSX_DEPLOYMENT_TARGET=10.9
# Causes failure for pre-1.19 in np.reciprocal
# CFLAGS="-msse2 -std=c99 -fno-strict-aliasing"
CFLAGS="-std=c99 -fno-strict-aliasing"
LDFLAGS="-Wl,--strip-debug"
# Macos's linker doesn't support stripping symbols
if [ "$(uname)" != "Darwin" ]; then
LDFLAGS="-Wl,--strip-debug"
# make sure that LDFLAGS is exposed to child processes,
# since current version of manybuild only export CFLAGS, CPPFLAGS and FFLAGS
export LDFLAGS="$LDFLAGS"
# override the default stripping flags, since we only override CFLAGS and
# the current version of manybuild pass "-strip-all" to CPPFLAGS and FFLAGS
STRIP_FLAGS=""
fi

0 comments on commit 11d6d89

Please sign in to comment.