mirror of
https://github.com/pyenv/pyenv.git
synced 2024-12-22 06:51:13 +00:00
feat(python-build): Add PACKAGE_LDFLAGS to support custom LDFLAGS per package
This commit is contained in:
parent
0167890c8c
commit
5fda898694
1 changed files with 4 additions and 0 deletions
|
@ -810,6 +810,7 @@ build_package_standard_build() {
|
|||
local PACKAGE_MAKE_OPTS="${package_var_name}_MAKE_OPTS"
|
||||
local PACKAGE_MAKE_OPTS_ARRAY="${package_var_name}_MAKE_OPTS_ARRAY[@]"
|
||||
local PACKAGE_CFLAGS="${package_var_name}_CFLAGS"
|
||||
local PACKAGE_LDFLAGS="${package_var_name}_LDFLAGS"
|
||||
|
||||
if [ "$package_var_name" = "PYTHON" ]; then
|
||||
use_homebrew || true
|
||||
|
@ -827,6 +828,9 @@ build_package_standard_build() {
|
|||
( if [ "${CFLAGS+defined}" ] || [ "${!PACKAGE_CFLAGS+defined}" ]; then
|
||||
export CFLAGS="$CFLAGS ${!PACKAGE_CFLAGS}"
|
||||
fi
|
||||
if [ "${LDFLAGS+defined}" ] || [ "${!PACKAGE_LDFLAGS+defined}" ]; then
|
||||
export LDFLAGS="$LDFLAGS ${!PACKAGE_LDFLAGS}"
|
||||
fi
|
||||
if [ -z "$CC" ] && is_mac -ge 1010; then
|
||||
export CC=clang
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue