From bd7249b1a8e48fd6cdb20e97d53ba278dfdb29f8 Mon Sep 17 00:00:00 2001 From: Marcelo Duarte Date: Sat, 17 Apr 2021 08:11:15 -0300 Subject: [PATCH 1/3] cx_Freeze 6.6 --- .../PKGBUILD | 28 +++++++++++-------- 1 file changed, 17 insertions(+), 11 deletions(-) rename {mingw-w64-python-cx_Freeze => mingw-w64-python-cx-freeze}/PKGBUILD (57%) diff --git a/mingw-w64-python-cx_Freeze/PKGBUILD b/mingw-w64-python-cx-freeze/PKGBUILD similarity index 57% rename from mingw-w64-python-cx_Freeze/PKGBUILD rename to mingw-w64-python-cx-freeze/PKGBUILD index b9f5be2736..f231b52d1a 100644 --- a/mingw-w64-python-cx_Freeze/PKGBUILD +++ b/mingw-w64-python-cx-freeze/PKGBUILD @@ -3,13 +3,15 @@ # Contributor: Duong Pham # Contributor: Lara Maia -_realname=cx_Freeze +_realname=cx-freeze pkgbase=mingw-w64-python-${_realname} 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=6.5.3 +provides=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}" + "${MINGW_PACKAGE_PREFIX}-python3-cx_Freeze") +conflicts=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}" + "${MINGW_PACKAGE_PREFIX}-python3-cx_Freeze") +replaces=("${MINGW_PACKAGE_PREFIX}-python3-cx_Freeze") +pkgver=6.6 pkgrel=1 pkgdesc="Creates standalone executables from Python scripts, with the same performance (mingw-w64)" arch=('any') @@ -17,26 +19,30 @@ mingw_arch=('mingw32' 'mingw64' 'ucrt64') license=('PSF') url="https://github.com/marcelotduarte/cx_Freeze/" depends=("${MINGW_PACKAGE_PREFIX}-python" + "${MINGW_PACKAGE_PREFIX}-python-cx-logging" "${MINGW_PACKAGE_PREFIX}-python-importlib-metadata") makedepends=("${MINGW_PACKAGE_PREFIX}-python-setuptools") options=('staticlibs' 'strip' '!debug') -source=(${_realname}-${pkgver}.tar.gz::https://pypi.io/packages/source/c/cx_Freeze/cx_Freeze-${pkgver}.tar.gz) -sha256sums=('e0d03cabcdf9b9c21354807ed9f06fa9481a8fd5a0838968a830f01a70820ff1') +source=(cx_Freeze-${pkgver}.tar.gz::https://pypi.io/packages/source/c/cx_Freeze/cx_Freeze-${pkgver}.tar.gz) +sha256sums=('c4af8ad3f7e7d71e291c1dec5d0fb26bbe92df834b098ed35434c901fbd6762f') prepare() { - rm -Rf python-cx_Freeze-${CARCH} - cp -a cx_Freeze-${pkgver} python-cx_Freeze-${CARCH} + rm -Rf python-${_realname}-${CARCH} + cp -a cx_Freeze-${pkgver} python-${_realname}-${CARCH} + # patch cx_Logging 3.0 - temporary fix until 3.1 + curl https://raw.githubusercontent.com/anthony-tuininga/cx_Logging/master/src/cx_Logging.h -o cx_Logging.h + cp cx_Logging.h python-${_realname}-${CARCH}/source/bases } build() { echo "Building for Python" - cd python-cx_Freeze-${CARCH} + cd python-${_realname}-${CARCH} ${MINGW_PREFIX}/bin/python setup.py build } package() { local _mingw_prefix=$(cygpath -wm ${MINGW_PREFIX}) - cd python-cx_Freeze-${CARCH} + cd python-${_realname}-${CARCH} MSYS2_ARG_CONV_EXCL="--prefix=;--install-scripts=;--install-platlib=" \ ${MINGW_PREFIX}/bin/python setup.py install --prefix=${MINGW_PREFIX} \ --root="${pkgdir}" --optimize=1 --skip-build From 2bf39aae7cb228f5948e7994010762372e57c199 Mon Sep 17 00:00:00 2001 From: Christoph Reiter Date: Sun, 18 Apr 2021 13:21:11 +0200 Subject: [PATCH 2/3] cx-freeze: fix provides/conflicts/replaces --- mingw-w64-python-cx-freeze/PKGBUILD | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/mingw-w64-python-cx-freeze/PKGBUILD b/mingw-w64-python-cx-freeze/PKGBUILD index f231b52d1a..0d93f174f4 100644 --- a/mingw-w64-python-cx-freeze/PKGBUILD +++ b/mingw-w64-python-cx-freeze/PKGBUILD @@ -6,11 +6,12 @@ _realname=cx-freeze pkgbase=mingw-w64-python-${_realname} pkgname=("${MINGW_PACKAGE_PREFIX}-python-${_realname}") -provides=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}" - "${MINGW_PACKAGE_PREFIX}-python3-cx_Freeze") -conflicts=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}" - "${MINGW_PACKAGE_PREFIX}-python3-cx_Freeze") -replaces=("${MINGW_PACKAGE_PREFIX}-python3-cx_Freeze") +provides=("${MINGW_PACKAGE_PREFIX}-python3-cx_Freeze" + "${MINGW_PACKAGE_PREFIX}-python-cx_Freeze") +conflicts=("${MINGW_PACKAGE_PREFIX}-python3-cx_Freeze" + "${MINGW_PACKAGE_PREFIX}-python-cx_Freeze") +replaces=("${MINGW_PACKAGE_PREFIX}-python3-cx_Freeze" + "${MINGW_PACKAGE_PREFIX}-python-cx_Freeze") pkgver=6.6 pkgrel=1 pkgdesc="Creates standalone executables from Python scripts, with the same performance (mingw-w64)" From e9f9a58bab91f9a8c18948217efc93463b7a881b Mon Sep 17 00:00:00 2001 From: Christoph Reiter Date: Sun, 18 Apr 2021 13:24:53 +0200 Subject: [PATCH 3/3] cx-freeze: add cx_Logging.h to source to make the build reproducible --- mingw-w64-python-cx-freeze/PKGBUILD | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/mingw-w64-python-cx-freeze/PKGBUILD b/mingw-w64-python-cx-freeze/PKGBUILD index 0d93f174f4..e02809b1f0 100644 --- a/mingw-w64-python-cx-freeze/PKGBUILD +++ b/mingw-w64-python-cx-freeze/PKGBUILD @@ -24,14 +24,16 @@ depends=("${MINGW_PACKAGE_PREFIX}-python" "${MINGW_PACKAGE_PREFIX}-python-importlib-metadata") makedepends=("${MINGW_PACKAGE_PREFIX}-python-setuptools") options=('staticlibs' 'strip' '!debug') -source=(cx_Freeze-${pkgver}.tar.gz::https://pypi.io/packages/source/c/cx_Freeze/cx_Freeze-${pkgver}.tar.gz) -sha256sums=('c4af8ad3f7e7d71e291c1dec5d0fb26bbe92df834b098ed35434c901fbd6762f') +source=(cx_Freeze-${pkgver}.tar.gz::https://pypi.io/packages/source/c/cx_Freeze/cx_Freeze-${pkgver}.tar.gz + https://raw.githubusercontent.com/anthony-tuininga/cx_Logging/425267a154119497/src/cx_Logging.h) +sha256sums=('c4af8ad3f7e7d71e291c1dec5d0fb26bbe92df834b098ed35434c901fbd6762f' + '601472dd2e8267d64c91ec6875f83a89b8df1920b06e70ec8bbb5def643ff77d') prepare() { rm -Rf python-${_realname}-${CARCH} cp -a cx_Freeze-${pkgver} python-${_realname}-${CARCH} + # patch cx_Logging 3.0 - temporary fix until 3.1 - curl https://raw.githubusercontent.com/anthony-tuininga/cx_Logging/master/src/cx_Logging.h -o cx_Logging.h cp cx_Logging.h python-${_realname}-${CARCH}/source/bases }