mirror of
https://github.com/pyenv/pyenv.git
synced 2024-11-14 20:39:55 -05:00
Merge pull request #819 from woosley/master
use $ORIGIN for rpath so the built python can be copied
This commit is contained in:
commit
99b510859d
2 changed files with 3 additions and 3 deletions
|
@ -153,12 +153,12 @@ You can build CPython with `--enable-shared` to install a version with
|
||||||
shared object.
|
shared object.
|
||||||
|
|
||||||
If `--enabled-shared` was found in `PYTHON_CONFIGURE_OPTS` or `CONFIGURE_OPTS`,
|
If `--enabled-shared` was found in `PYTHON_CONFIGURE_OPTS` or `CONFIGURE_OPTS`,
|
||||||
`python-build` will automatically set `RPATH` to the pyenv's prefix directory.
|
`python-build` will automatically set `RPATH` to the pyenv's `bin/../lib` directory.
|
||||||
This means you don't have to set `LD_LIBRARY_PATH` or `DYLD_LIBRARY_PATH` for
|
This means you don't have to set `LD_LIBRARY_PATH` or `DYLD_LIBRARY_PATH` for
|
||||||
the version(s) installed with `--enable-shared`.
|
the version(s) installed with `--enable-shared`.
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
$ env PYTHON_CONFIGURE_OPTS="--enable-shared` pyenv install 2.7.9
|
$ env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 2.7.9
|
||||||
```
|
```
|
||||||
|
|
||||||
### Checksum verification
|
### Checksum verification
|
||||||
|
|
|
@ -1911,7 +1911,7 @@ package_option python configure --libdir="${PREFIX_PATH}/lib"
|
||||||
if [[ "$CONFIGURE_OPTS" == *"--enable-shared"* ]] || [[ "$PYTHON_CONFIGURE_OPTS" == *"--enable-shared"* ]]; then
|
if [[ "$CONFIGURE_OPTS" == *"--enable-shared"* ]] || [[ "$PYTHON_CONFIGURE_OPTS" == *"--enable-shared"* ]]; then
|
||||||
# The ld on Darwin embeds the full paths to each dylib by default
|
# The ld on Darwin embeds the full paths to each dylib by default
|
||||||
if [[ "$LDFLAGS" != *"-rpath="* ]] && ! is_mac; then
|
if [[ "$LDFLAGS" != *"-rpath="* ]] && ! is_mac; then
|
||||||
export LDFLAGS="-Wl,-rpath=${PREFIX_PATH}/lib ${LDFLAGS}"
|
export LDFLAGS="-Wl,-rpath='\$\$ORIGIN/../lib' ${LDFLAGS}"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue