[arch-commits] Commit in python-cx_freeze/repos/community-x86_64 (3 files)
Felix Yan
felixonmars at archlinux.org
Mon Sep 10 19:42:13 UTC 2018
Date: Monday, September 10, 2018 @ 19:42:12
Author: felixonmars
Revision: 379262
archrelease: copy trunk to community-x86_64
Added:
python-cx_freeze/repos/community-x86_64/PKGBUILD
(from rev 379261, python-cx_freeze/trunk/PKGBUILD)
python-cx_freeze/repos/community-x86_64/python3.7.patch
(from rev 379261, python-cx_freeze/trunk/python3.7.patch)
Deleted:
python-cx_freeze/repos/community-x86_64/PKGBUILD
-----------------+
PKGBUILD | 99 ++++++++++++++++++++++++++++++++----------------------
python3.7.patch | 23 ++++++++++++
2 files changed, 83 insertions(+), 39 deletions(-)
Deleted: PKGBUILD
===================================================================
--- PKGBUILD 2018-09-10 19:41:54 UTC (rev 379261)
+++ PKGBUILD 2018-09-10 19:42:12 UTC (rev 379262)
@@ -1,39 +0,0 @@
-# $Id$
-# Maintainer: Alexander Rødseth <rodseth at gmail.com>
-# Contributor: Ray Rashif <schiv at archlinux.org>
-# Contributor: Douglas Soares de Andrade <douglas at archlinux.org>
-# Contributor: Eric Belanger <eric at archlinux.org>
-# Contributor: Roberto Alsina <ralsina at kde.org>
-# Contributor: Julien Duponchelle <julien at gns3.net>
-
-pkgbase=python-cx_freeze
-pkgname=('python-cx_freeze' 'python2-cx_freeze')
-pkgver=5.1.1
-pkgrel=2
-pkgdesc='Utilities for freezing Python scripts into executables'
-arch=('x86_64')
-url='http://cx-freeze.sourceforge.net/'
-license=('PSF')
-makedepends=('python' 'python2')
-source=("https://pypi.io/packages/source/c/cx_Freeze/cx_Freeze-$pkgver.tar.gz")
-sha512sums=('64f9c3b7f6c3003c1dc439fc2da7d0c13c5f146834e3ab8ece3921f1eb30c6e3eda480ccc84e61cc061597521b360cf8f5ef8e0bbcce1437157360c3d9c1adbc')
-
-package_python-cx_freeze() {
- depends=('python')
- conflicts=('cx_freeze' 'python2-cx_freeze')
-
- cd "cx_Freeze-$pkgver"
- python setup.py install --root "$pkgdir" --optimize 1
-}
-
-package_python2-cx_freeze() {
- depends=('python2')
- conflicts=('cx_freeze' 'python-cx_freeze')
- replaces=('cx_freeze')
-
- cd "cx_Freeze-$pkgver"
- python2 setup.py install --root "$pkgdir" --optimize 1
-
- # Python 2 fix
- find "$pkgdir" -name qotd.py -exec sed -i '0,/on/s//on2/' {} \;
-}
Copied: python-cx_freeze/repos/community-x86_64/PKGBUILD (from rev 379261, python-cx_freeze/trunk/PKGBUILD)
===================================================================
--- PKGBUILD (rev 0)
+++ PKGBUILD 2018-09-10 19:42:12 UTC (rev 379262)
@@ -0,0 +1,60 @@
+# $Id$
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Alexander Rødseth <rodseth at gmail.com>
+# Contributor: Ray Rashif <schiv at archlinux.org>
+# Contributor: Douglas Soares de Andrade <douglas at archlinux.org>
+# Contributor: Eric Belanger <eric at archlinux.org>
+# Contributor: Roberto Alsina <ralsina at kde.org>
+# Contributor: Julien Duponchelle <julien at gns3.net>
+
+pkgbase=python-cx_freeze
+pkgname=('python-cx_freeze' 'python2-cx_freeze')
+pkgver=5.1.1
+pkgrel=3
+pkgdesc='Utilities for freezing Python scripts into executables'
+arch=('x86_64')
+url='https://anthony-tuininga.github.io/cx_Freeze'
+license=('PSF')
+makedepends=('python-setuptools' 'python2-setuptools')
+checkdepends=('python-nose' 'python2-nose' 'python-openpyxl' 'python2-openpyxl' 'python2-mock')
+source=("$pkgbase-$pkgver.tar.gz::https://github.com/anthony-tuininga/cx_Freeze/archive/$pkgver.tar.gz"
+ python3.7.patch)
+sha512sums=('95d70c23678080fec96df78658aeaaeb81ce0660ce242a363699d6b82d926d021519f9b67dc458b0d2e3c89230a582cfec6862a2346bf0deacc636ce125c0c96'
+ '9009d617213bcf57124b32b1680fa1a2282885ff27fdc6c14482c3db34b2859d2e6cdc724c114a2ccd3a90f11c83e3c3837d1df58d13a041ab1d2439804cb1d4')
+
+prepare() {
+ cd cx_Freeze-$pkgver
+ patch -p1 -i ../python3.7.patch
+}
+
+build() {
+ cd cx_Freeze-$pkgver
+ python setup.py build
+ python2 setup.py build
+}
+
+check() {
+ cd cx_Freeze-$pkgver
+ python setup.py nosetests || warning "Tests failed"
+ python2 setup.py nosetests
+}
+
+package_python-cx_freeze() {
+ depends=('python')
+ conflicts=('cx_freeze' 'python2-cx_freeze')
+
+ cd cx_Freeze-$pkgver
+ python setup.py install --root "$pkgdir" --optimize 1 --skip-build
+}
+
+package_python2-cx_freeze() {
+ depends=('python2')
+ conflicts=('cx_freeze' 'python-cx_freeze')
+ replaces=('cx_freeze')
+
+ cd cx_Freeze-$pkgver
+ python2 setup.py install --root "$pkgdir" --optimize 1 --skip-build
+
+ # Python 2 fix
+ find "$pkgdir" -name qotd.py -exec sed -i '0,/on/s//on2/' {} \;
+}
Copied: python-cx_freeze/repos/community-x86_64/python3.7.patch (from rev 379261, python-cx_freeze/trunk/python3.7.patch)
===================================================================
--- python3.7.patch (rev 0)
+++ python3.7.patch 2018-09-10 19:42:12 UTC (rev 379262)
@@ -0,0 +1,23 @@
+--- orig/cx_Freeze-5.1.1/cx_Freeze/freezer.py 2017-12-09 23:11:29.000000000 +0100
++++ cx_Freeze-5.1.1/cx_Freeze/freezer.py 2018-08-31 13:41:19.028655982 +0200
+@@ -550,13 +550,18 @@
+ # the file is up to date so we can safely set this value to zero
+ if module.code is not None:
+ if module.file is not None and os.path.exists(module.file):
+- mtime = os.stat(module.file).st_mtime
++ stat = os.stat(module.file)
++ mtime = stat.st_mtime
++ size = stat.st_size & 0xFFFFFFFF
+ else:
+ mtime = time.time()
++ size = 0
+ if sys.version_info[:2] < (3, 3):
+ header = magic + struct.pack("<i", int(mtime))
++ elif sys.version_info[:2] == (3, 7):
++ header = magic + struct.pack("<iii",0, int(mtime), size)
+ else:
+- header = magic + struct.pack("<ii", int(mtime), 0)
++ header = magic + struct.pack("<ii", int(mtime), size)
+ data = header + marshal.dumps(module.code)
+
+ # if the module should be written to the file system, do so
More information about the arch-commits
mailing list