| diff -Naur Python-3.8.0-orig/Lib/distutils/unixccompiler.py Python-3.8.0/Lib/distutils/unixccompiler.py |
| --- Python-3.8.0-orig/Lib/distutils/unixccompiler.py 2019-10-14 16:34:47.000000000 +0300 |
| +++ Python-3.8.0/Lib/distutils/unixccompiler.py 2019-10-22 10:01:11.964963100 +0300 |
| @@ -248,9 +248,13 @@ |
| # -Wl whenever gcc was used in the past it is probably |
| # safest to keep doing so. |
| if sysconfig.get_config_var("GNULD") == "yes": |
| - # GNU ld needs an extra option to get a RUNPATH |
| + # GNU ELF ld needs an extra option to get a RUNPATH |
| # instead of just an RPATH. |
| - return "-Wl,--enable-new-dtags,-R" + dir |
| + if sys.platform in ["win32", "cygwin"] or \ |
| + "mingw" in compiler: |
| + return [] |
| + else: |
| + return "-Wl,--enable-new-dtags,-R" + dir |
| else: |
| return "-Wl,-R" + dir |
| else: |