aboutsummaryrefslogtreecommitdiff
path: root/gn/packages/python.scm
diff options
context:
space:
mode:
authorpjotrp2020-02-10 12:21:33 -0600
committerpjotrp2020-02-10 12:21:33 -0600
commit5df680178c01cd7db0f1d4a766a868dc08317e4b (patch)
treee16e4ac62a5422ef83f9ef59397df0458d58063a /gn/packages/python.scm
parentf7b75fe1730e6e5e77768d332f9f3946b5218c8c (diff)
parent5a69fb0666a2bf53b13ab9490b3ed44e5dc944b4 (diff)
downloadguix-bioinformatics-5df680178c01cd7db0f1d4a766a868dc08317e4b.tar.gz
Update
Diffstat (limited to 'gn/packages/python.scm')
-rw-r--r--gn/packages/python.scm153
1 files changed, 101 insertions, 52 deletions
diff --git a/gn/packages/python.scm b/gn/packages/python.scm
index b69dd91..60558a2 100644
--- a/gn/packages/python.scm
+++ b/gn/packages/python.scm
@@ -488,58 +488,107 @@ Python 3 support.")
; pinned QmZLWsPHLFTU3hWAfdTwj3RXFrS8Ma7KEixne1suWuYqeG recursively
(define-public python2-htmlgen-gn ; guix obsolete
-(package
- (name "python2-htmlgen-gn")
- (version "2.2.2")
- (source (origin
- (method url-fetch)
- ;; http://files.genenetwork.org/software/contrib/htmlgen-2.2.2-gn.tar.gz
- (uri (string-append
- "http://ipfs.genenetwork.org/ipfs/QmZLWsPHLFTU3hWAfdTwj3RXFrS8Ma7KEixne1suWuYqeG/htmlgen-" version "-gn.tar.gz"))
- (sha256
- (base32
- "1lwsk56rymhrma46cbyh3g64ksmq1vsih3qkrc2vh0lpba825y7r"))
- ;;(patches (list
- ;; (search-patch "python2-htmlgen-Applied-Deb-patch.patch")
- ;; (search-patch "python2-htmlgen-Fix-test-for-random.patch")
- ))
- (build-system python-build-system)
- (outputs '("out"))
- (native-inputs
- `(("make" ,gnu-make)
- ))
- (propagated-inputs
- `(("python2" ,python-2)))
- (arguments
- `(#:phases (modify-phases %standard-phases
- (replace 'build
- (lambda _
- (system* "python2" "-m" "compileall" ".")))
- (replace 'install
- (lambda* (#:key outputs #:allow-other-keys)
- (let* ((out (assoc-ref outputs "out"))
- (include (string-append out "/include"))
- (lib2 (string-append out "/lib/htmlgen"))
- (lib (string-append (assoc-ref %outputs "out") "/lib/python2.7/site-packages/htmlgen"))
- (pkgconfig (string-append out "/lib/pkgconfig"))
- (doc (string-append out "/share/doc")))
- ;; Install libs and headers.
- ;; (copy-file "HTMLgen.pyc" "HTMLgen2.pyc")
- (install-file "HTMLgen.pyc" lib)
- (install-file "HTMLgen2.pyc" lib)
- (install-file "imgsize.pyc" lib)
- (install-file "ImageH.pyc" lib)
- (install-file "ImagePaletteH.pyc" lib)
- (install-file "__init__.pyc" lib)
- ))) ; install
- ) ; phases
- #:tests? #f))
- (home-page
- "https://packages.debian.org/unstable/python/python-htmlgen")
- (synopsis "Genenetwork version of Python2 HTMLgen (defunkt
-project)")
- (description #f)
- (license #f)))
+ (package
+ (name "python2-htmlgen-gn")
+ (version "2.2.2")
+ (source (origin
+ (method url-fetch)
+ ;; http://files.genenetwork.org/software/contrib/htmlgen-2.2.2-gn.tar.gz
+ (uri (string-append
+ "http://ipfs.genenetwork.org/ipfs/QmZLWsPHLFTU3hWAfdTwj3RXFrS8Ma7KEixne1suWuYqeG/htmlgen-" version "-gn.tar.gz"))
+ (sha256
+ (base32
+ "1lwsk56rymhrma46cbyh3g64ksmq1vsih3qkrc2vh0lpba825y7r"))
+ ;;(patches (list
+ ;; (search-patch "python2-htmlgen-Applied-Deb-patch.patch")
+ ;; (search-patch "python2-htmlgen-Fix-test-for-random.patch")
+ ))
+ (build-system python-build-system)
+ (arguments
+ `(#:python ,python-2
+ #:tests? #f
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'modernize-imports
+ (lambda _
+ (substitute* "HTMLgen.py"
+ (("whrandom") "random"))
+ (substitute* "HTMLcalendar.py"
+ (("import regex") "import re as regex"))
+ (substitute* "HTMLutil.py"
+ (("import string, regex") "import re as regex\nimport string"))
+ (substitute* "HTMLtest.py"
+ (("import string, regex, regsub") "import re as regex\nimport string")
+ (("regsub.split") "re.split"))
+ #t))
+ (replace 'build
+ (lambda _
+ (invoke "python" "-m" "compileall" ".")))
+ (replace 'check
+ (lambda* (#:key (tests? '()) #:allow-other-keys)
+ (if tests?
+ (invoke "python" "HTMLtest.py")
+ #t)))
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (lib (string-append out "/lib/python2.7/site-packages/htmlgen/")))
+ ;; Install libs and headers.
+ (for-each (lambda (file)
+ (install-file file lib))
+ (find-files "." "\\.py[c]?$"))
+ #t))))))
+ (home-page "https://packages.debian.org/unstable/python/python-htmlgen")
+ (synopsis "Genenetwork version of Python2 HTMLgen (defunkt project)")
+ (description #f)
+ (license #f)))
+
+(define-public python2-htmlgen-2.2
+ (package
+ (name "python2-htmlgen-2.2")
+ (version "2.2.2")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://debian/pool/main/h/htmlgen/htmlgen_" version ".orig.tar.gz"))
+ (sha256
+ (base32
+ "186kb434q6z84g31ysvzi4kcfcvl3pmm57k4jlng4ccgls94x6wb"))))
+ (build-system python-build-system)
+ (arguments
+ `(#:python ,python-2
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'modernize-imports
+ (lambda _
+ (substitute* "HTMLgen.py"
+ (("whrandom") "random"))
+ (substitute* "HTMLcalendar.py"
+ (("import regex") "import re as regex"))
+ (substitute* "HTMLutil.py"
+ (("import string, regex") "import re as regex\nimport string"))
+ (substitute* "HTMLtest.py"
+ (("import string, regex, regsub") "import re as regex\nimport string")
+ (("regsub.split") "re.split"))
+ #t))
+ (replace 'build
+ (lambda _
+ (invoke "python" "-m" "compileall" ".")))
+ (replace 'check
+ (lambda _
+ (invoke "python" "HTMLtest.py")))
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (lib (string-append out "/lib/python2.7/site-packages/htmlgen/")))
+ ;; Install libs and headers.
+ (for-each (lambda (file)
+ (install-file file lib))
+ (find-files "." "\\.py[c]?$"))
+ #t))))))
+ (home-page "https://packages.debian.org/unstable/python/python-htmlgen")
+ (synopsis "Genenetwork version of Python2 HTMLgen (defunkt project)")
+ (description #f)
+ (license #f)))
; penguin2:~/tmp$ env IPFS_PATH=/export/ipfs/ ipfs add -r Imaging/
; added QmV8Rew1re8gBTLsaqMU4bd7euFUPEpjiD572mtoz6KhPn Imaging/Imaging-1.1.6-gn.tar.gz