me
/
guix
Archived
1
0
Fork 0

gnu: python2-setuptools: Downgrade to 41.0.1.

* gnu/packages/python-xyz.scm (python2-setuptools): Define older version
instead of inheriting from python-setuptools.
(python-setuptools)[properties]: Record python2-variant.
master
Ricardo Wurmus 2021-02-05 23:26:51 +01:00
parent a60be5c5ff
commit 8cc13fcff5
No known key found for this signature in database
GPG Key ID: 197A5888235FACAC
1 changed files with 46 additions and 2 deletions

View File

@ -1181,10 +1181,54 @@ Python 3 support.")
(license (list license:psfl ; setuptools itself (license (list license:psfl ; setuptools itself
license:expat ; six, appdirs, pyparsing license:expat ; six, appdirs, pyparsing
license:asl2.0 ; packaging is dual ASL2/BSD-2 license:asl2.0 ; packaging is dual ASL2/BSD-2
license:bsd-2)))) license:bsd-2))
(properties `((python2-variant . ,(delay python2-setuptools))))))
;; Newer versions of setuptools no longer support Python 2.
(define-public python2-setuptools (define-public python2-setuptools
(package-with-python2 python-setuptools)) (package
(name "python2-setuptools")
(version "41.0.1")
(source
(origin
(method url-fetch)
(uri (pypi-uri "setuptools" version ".zip"))
(sha256
(base32
"04sns22y2hhsrwfy1mha2lgslvpjsjsz8xws7h2rh5a7ylkd28m2"))
(modules '((guix build utils)))
(snippet
'(begin
;; Remove included binaries which are used to build self-extracting
;; installers for Windows.
;; TODO: Find some way to build them ourself so we can include them.
(for-each delete-file (find-files "setuptools" "^(cli|gui).*\\.exe$"))
#t))))
(build-system python-build-system)
;; FIXME: Tests require pytest, which itself relies on setuptools.
;; One could bootstrap with an internal untested setuptools.
(arguments
`(#:tests? #f))
(native-inputs
`(("unzip" ,unzip)))
(home-page "https://pypi.org/project/setuptools/")
(synopsis
"Library designed to facilitate packaging Python projects")
(description
"Setuptools is a fully-featured, stable library designed to facilitate
packaging Python projects, where packaging includes:
Python package and module definitions,
distribution package metadata,
test hooks,
project installation,
platform-specific details,
Python 3 support.")
;; TODO: setuptools now bundles the following libraries:
;; packaging, pyparsing, six and appdirs. How to unbundle?
(license (list license:psfl ; setuptools itself
license:expat ; six, appdirs, pyparsing
license:asl2.0 ; packaging is dual ASL2/BSD-2
license:bsd-2))))
;; The setuptools provided by Python 3.7.4 is too new for Tensorflow. ;; The setuptools provided by Python 3.7.4 is too new for Tensorflow.
(define-public python-setuptools-for-tensorflow (define-public python-setuptools-for-tensorflow