Merge pull request #18644 from lazka/python-no-mdll-v2

python: use -shared instead if -mdll (v2)
This commit is contained in:
Christoph Reiter
2023-09-28 18:32:12 +02:00
committed by GitHub
2 changed files with 41 additions and 6 deletions

View File

@@ -0,0 +1,32 @@
From 3680d09207f1df34346552cd63c906210c15b943 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=D9=85=D9=87=D8=AF=D9=8A=20=D8=B4=D9=8A=D9=86=D9=88=D9=86?=
=?UTF-8?q?=20=28Mehdi=20Chinoune=29?= <mehdi.chinoune@hotmail.com>
Date: Wed, 27 Sep 2023 21:45:13 +0100
Subject: [PATCH 148/N] Use `-shared` instead of `-mdll`
---
Lib/distutils/cygwinccompiler.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Lib/distutils/cygwinccompiler.py b/Lib/distutils/cygwinccompiler.py
index d8c8428..860b48c 100644
--- a/Lib/distutils/cygwinccompiler.py
+++ b/Lib/distutils/cygwinccompiler.py
@@ -125,7 +125,7 @@ class CygwinCCompiler(UnixCCompiler):
shared_option = "-shared"
self.set_executables(compiler='%s -mcygwin -O -Wall' % self.cc,
- compiler_so='%s -mcygwin -mdll -O -Wall' % self.cc,
+ compiler_so='%s -mcygwin -shared -O -Wall' % self.cc,
compiler_cxx='%s -mcygwin -O -Wall' % self.cxx,
linker_exe='%s -mcygwin' % self.cc,
linker_so=('%s -mcygwin %s' %
@@ -287,7 +287,7 @@ class Mingw32CCompiler(CygwinCCompiler):
'Cygwin gcc cannot be used with --compiler=mingw32')
self.set_executables(compiler='%s -O2 -Wall' % self.cc,
- compiler_so='%s -mdll -O2 -Wall' % self.cc,
+ compiler_so='%s -shared -O2 -Wall' % self.cc,
compiler_cxx='%s -O2 -Wall' % self.cxx,
linker_exe='%s' % self.cc,
linker_so='%s %s'

View File

@@ -22,11 +22,11 @@ else
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}${_pybasever}")
fi
pkgver=${_pybasever}.5
pkgrel=2
pkgrel=4
pkgdesc="A high-level scripting language (mingw-w64)"
arch=('any')
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clang32' 'clangarm64')
license=('PSF')
license=('spdx:PSF-2.0')
url="https://www.python.org/"
depends=("${MINGW_PACKAGE_PREFIX}-gcc-libs"
"${MINGW_PACKAGE_PREFIX}-expat"
@@ -46,7 +46,7 @@ makedepends=(
"${MINGW_PACKAGE_PREFIX}-autotools"
"autoconf-archive"
)
options=('makeflags') # 'debug' '!strip')
#options=('debug' '!strip')
source=("https://www.python.org/ftp/python/${pkgver%rc?}/Python-${pkgver}.tar.xz"
0001-sysconfig-make-_sysconfigdata.py-relocatable.patch
0002-build-add-with-nt-threads-and-make-it-default-on-min.patch
@@ -194,7 +194,8 @@ source=("https://www.python.org/ftp/python/${pkgver%rc?}/Python-${pkgver}.tar.xz
0144-setup.py-don-t-prepend-the-system-library-directorie.patch
0145-tests-skip-a-broken-test.patch
0146-Port-GetPythonImport-to-mingw.patch
0147-LoadLibraryExW-make-sure-to-only-use-backslashes-for.patch)
0147-LoadLibraryExW-make-sure-to-only-use-backslashes-for.patch
0148-Use-shared-instead-of-mdll.patch)
# Helper macros to help make tasks easier #
apply_patch_with_msg() {
@@ -354,7 +355,8 @@ prepare() {
0144-setup.py-don-t-prepend-the-system-library-directorie.patch \
0145-tests-skip-a-broken-test.patch \
0146-Port-GetPythonImport-to-mingw.patch \
0147-LoadLibraryExW-make-sure-to-only-use-backslashes-for.patch
0147-LoadLibraryExW-make-sure-to-only-use-backslashes-for.patch \
0148-Use-shared-instead-of-mdll.patch
autoreconf -vfi
}
@@ -602,4 +604,5 @@ sha256sums=('85cd12e9cf1d6d5a45f17f7afe1cebe7ee628d3282281c492e86adf636defa3f'
'6e0d29ee44c5d5ab8605a980c7cee246acf5ccce638e6a7cee4c4e7a8ec865cd'
'3b6bf12600203d45ff9b0ecde0bb9959c4fde923c9609e4c1e18b6d7877e3f1b'
'd9a54181024f0b538d8903bdf772a0dd754811aab339e6f553c47e1198ab04cc'
'71fd408d8bb8ca40584f287adea583032d1b7150f011abe2165c44d468428f0f')
'71fd408d8bb8ca40584f287adea583032d1b7150f011abe2165c44d468428f0f'
'bccfac6f05b4faa023bb41fd08f0979f77d5656dadfe90ef44418189f79e9f56')