Mike Frysinger | ce0b8c0 | 2019-07-11 00:40:18 -0400 | [diff] [blame] | 1 | we already patch the python modules behind the python-config scripts, |
| 2 | but the shell python-config script is completely unrelated. |
| 3 | |
| 4 | we throw away the -L$libdir path because $libdir is in the toolchain's |
| 5 | search path already, so we don't need the redundancy. |
| 6 | |
| 7 | --- a/Misc/python-config.sh.in |
| 8 | +++ b/Misc/python-config.sh.in |
| 9 | @@ -25,6 +25,9 @@ installed_prefix () |
| 10 | } |
| 11 | |
| 12 | prefix_real=$(installed_prefix "$0") |
| 13 | +if [ "${prefix_real}" = "/usr" ]; then |
| 14 | + prefix_real="${SYSROOT}/usr" |
| 15 | +fi |
| 16 | |
| 17 | # Use sed to fix paths from their built-to locations to their installed-to |
| 18 | # locations. Keep prefix & exec_prefix using their original values in case |
| 19 | @@ -92,7 +95,7 @@ do |
| 20 | if [ -z "$PYTHONFRAMEWORK" ] ; then |
| 21 | LINKFORSHAREDUSED=$LINKFORSHARED |
| 22 | fi |
| 23 | - echo "-L$libdir $LIBS $LINKFORSHAREDUSED" |
| 24 | + echo "$LIBS $LINKFORSHAREDUSED" |
| 25 | ;; |
| 26 | --extension-suffix) |
| 27 | echo "$SO" |