diff --git a/mingw-w64-python-h5py/001-mingw-python.patch b/mingw-w64-python-h5py/001-mingw-python.patch index 9ea7d0d86e..f9e5c5a66b 100644 --- a/mingw-w64-python-h5py/001-mingw-python.patch +++ b/mingw-w64-python-h5py/001-mingw-python.patch @@ -23,20 +23,20 @@ COMPILER_SETTINGS['include_dirs'].append(localpath('windows')) COMPILER_SETTINGS['define_macros'].extend([ ('_HDF5USEDLL_', None), ---- h5py-2.10.0/setup_configure.py.orig 2019-10-28 06:39:22.882866000 +0300 -+++ h5py-2.10.0/setup_configure.py 2019-10-28 06:45:46.958833800 +0300 -@@ -200,8 +200,12 @@ - regexp = re.compile(r'^libhdf5.dylib') - elif sys.platform.startswith('win') or \ - sys.platform.startswith('cygwin'): -- default_path = 'hdf5.dll' -- regexp = re.compile(r'^hdf5.dll') -+ if 'GCC' in sys.version: -+ default_path = 'libhdf5-0.dll' -+ regexp = re.compile(r'^libhdf5-[0-9].dll') -+ else: -+ default_path = 'hdf5.dll' -+ regexp = re.compile(r'^hdf5.dll') - else: - default_path = 'libhdf5.so' - regexp = re.compile(r'^libhdf5.so') +--- h5py-3.3.0/setup_configure.py.orig 2021-07-14 20:32:17.516742500 +0200 ++++ h5py-3.3.0/setup_configure.py 2021-07-14 20:34:00.998030600 +0200 +@@ -202,8 +202,12 @@ + regexp = re.compile(r'^libhdf5.dylib') + elif sys.platform.startswith('win') or \ + sys.platform.startswith('cygwin'): +- default_path = 'hdf5.dll' +- regexp = re.compile(r'^hdf5.dll') ++ if 'GCC' in sys.version: ++ default_path = 'libhdf5-0.dll' ++ regexp = re.compile(r'^libhdf5-[0-9].dll') ++ else: ++ default_path = 'hdf5.dll' ++ regexp = re.compile(r'^hdf5.dll') + if sys.version_info >= (3, 8): + # To overcome "difficulty" loading the library on windows + # https://bugs.python.org/issue42114 diff --git a/mingw-w64-python-h5py/PKGBUILD b/mingw-w64-python-h5py/PKGBUILD index 58c5068bf8..cece2fc79e 100644 --- a/mingw-w64-python-h5py/PKGBUILD +++ b/mingw-w64-python-h5py/PKGBUILD @@ -6,8 +6,8 @@ pkgname=("${MINGW_PACKAGE_PREFIX}-python-${_realname}") provides=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}") conflicts=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}") replaces=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}") -pkgver=2.10.0 -pkgrel=2 +pkgver=3.3.0 +pkgrel=1 pkgdesc="General-purpose Python bindings for the HDF5 library (mingw-w64)" arch=('any') mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64') @@ -23,8 +23,8 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-cython" source=(https://github.com/h5py/h5py/releases/download/${pkgver}/h5py-${pkgver}.tar.gz 001-mingw-python.patch lzf_c.c.patch) -sha256sums=('84412798925dc870ffd7107f045d7659e60f5d46d1c70c700375248bf6bf512d' - 'cd8dff9d11117521cc7948400fa92cbc115d432c93aac181a20017d27e3f197e' +sha256sums=('4a279dca1c8212543b7d9b4400e3df15589d7dcccb85555be38afc9891c5fad6' + 'f743ffdfe2eee2dc48001af7c4aba4a78a05270fbda1c06e5edda71770503812' '6d0126b881b5dcd637146d151341b72aa68eef760092272279072ec0bc4ceca9') prepare() { @@ -39,6 +39,8 @@ prepare() { build() { cd "${srcdir}/python-build-${CARCH}" + + H5PY_SETUP_REQUIRES=0 \ MSYS2_ARG_CONV_EXCL="--prefix=;--install-scripts=;--install-platlib=" \ ${MINGW_PREFIX}/bin/python setup.py build } @@ -46,6 +48,7 @@ build() { package() { cd "${srcdir}/python-build-${CARCH}" + H5PY_SETUP_REQUIRES=0 \ MSYS2_ARG_CONV_EXCL="--prefix=;--install-scripts=;--install-platlib=" \ ${MINGW_PREFIX}/bin/python setup.py install --skip-build \ --prefix=${MINGW_PREFIX} --root=${pkgdir} --optimize=1