unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#39292] [PATCH 01/10] gnu: Add python-pymediainfo
@ 2020-03-07 15:11 Sebastian Schott
  2020-03-07 15:11 ` [bug#39292] [PATCH 10/10] gnu: Add rapid-photo-downloader Sebastian Schott
  0 siblings, 1 reply; 8+ messages in thread
From: Sebastian Schott @ 2020-03-07 15:11 UTC (permalink / raw)
  To: 39292; +Cc: Sebastian Schott

* gnu/packages/python-xyz.scm (python-pymediainfo): New variable.
---
 gnu/packages/python-xyz.scm | 46 +++++++++++++++++++++++++++++++++++++
 1 file changed, 46 insertions(+)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index bd107f9648..c1f1c7fa0e 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -70,6 +70,7 @@
 ;;; Copyright © 2019 Mădălin Ionel Patrașcu <madalinionel.patrascu@mdc-berlin.de>
 ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
 ;;; Copyright © 2020 sirgazil <sirgazil@zoho.com>
+;;; Copyright © 2020 Sebastian Schott <sschott@mailbox.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -170,6 +171,51 @@
   #:use-module (srfi srfi-1)
   #:use-module (srfi srfi-26))
 
+(define-public python-pymediainfo
+  (package
+    (name "python-pymediainfo")
+    (version "4.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "pymediainfo" version))
+       (sha256
+        (base32
+         "0mhpxs7vlqx8w75z93dy7nnvx89kwfdjkla03l19an15rlyqyspd"))))
+    (build-system python-build-system)
+    (native-inputs
+     `(("python-setuptools-scm" ,python-setuptools-scm)
+       ("python-pytest" ,python-pytest)))
+    (inputs
+     `(("libmediainfo" ,libmediainfo)))
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'patch-libmediainfo
+           (lambda _
+             (substitute* "pymediainfo/__init__.py"
+               (("libmediainfo.so.0")
+                (string-append (assoc-ref %build-inputs "libmediainfo")
+                               "/lib/libmediainfo.so.0")))
+             #t))
+         (replace 'check
+           (lambda _
+             ;; Extend PYTHONPATH so the built package will be found.
+             (setenv "PYTHONPATH"
+                     (string-append (getcwd) "/build/lib:"
+                                    (getenv "PYTHONPATH")))
+             ;; Skip the only failing test "test_parse_url"
+             (invoke "pytest" "-vv" "-k" "not test_parse_url")
+             #t)))))
+    (home-page
+     "https://github.com/sbraz/pymediainfo")
+    (synopsis
+     "Python wrapper for the mediainfo library")
+    (description
+     "Python wrapper for the mediainfo library to access the technical and tag
+data for video and audio files.")
+    (license license:expat)))
+
 (define-public python-psutil
   (package
     (name "python-psutil")
-- 
2.24.0

^ permalink raw reply related	[flat|nested] 8+ messages in thread
* [bug#39292] Re: [bug#39292] [PATCH 10/10] gnu: Add rapid-photo-downloader
@ 2020-02-02  9:36 Sebastian Schott
  2020-02-02 10:11 ` Christopher Baines
  0 siblings, 1 reply; 8+ messages in thread
From: Sebastian Schott @ 2020-02-02  9:36 UTC (permalink / raw)
  To: 39292@debbugs.gnu.org; +Cc: mail@cbaines.net

[-- Attachment #1: Type: text/html, Size: 841 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread
* [bug#39292] [PATCH 01/10] gnu: Add python-pymediainfo
@ 2020-01-26 17:24 Sebastian Schott
  2020-01-26 17:24 ` [bug#39292] [PATCH 10/10] gnu: Add rapid-photo-downloader Sebastian Schott
  0 siblings, 1 reply; 8+ messages in thread
From: Sebastian Schott @ 2020-01-26 17:24 UTC (permalink / raw)
  To: 39292; +Cc: Sebastian Schott

* gnu/packages/python-xyz.scm (python-pymediainfo): New variable.
---
 gnu/packages/python-xyz.scm | 41 +++++++++++++++++++++++++++++++++++++
 1 file changed, 41 insertions(+)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 2c308796e7..9f5cb20095 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -166,6 +166,47 @@
   #:use-module (srfi srfi-1)
   #:use-module (srfi srfi-26))
 
+(define-public python-pymediainfo
+  (package
+    (name "python-pymediainfo")
+    (version "4.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "pymediainfo" version))
+       (sha256
+        (base32
+         "0mhpxs7vlqx8w75z93dy7nnvx89kwfdjkla03l19an15rlyqyspd"))))
+    (build-system python-build-system)
+    (native-inputs
+     `(("python-setuptools-scm" ,python-setuptools-scm)
+       ("python-pytest" ,python-pytest)
+       ("python-pytest-runner" ,python-pytest-runner)))
+    (inputs
+     `(("libmediainfo" ,libmediainfo)))
+    (arguments
+     `(#:phases (modify-phases %standard-phases
+                  (add-after 'unpack 'patch-libmediainfo
+                    (lambda _
+                      (substitute* "pymediainfo/__init__.py"
+                        (("libmediainfo.so.0")
+                         (string-append (assoc-ref %build-inputs "libmediainfo")
+                                        "/lib/libmediainfo.so.0")))))
+                  (replace 'check
+                    (lambda _
+                      ;; Extend PYTHONPATH so the built package will be found.
+                      (setenv "PYTHONPATH"
+                              (string-append (getcwd) "/build/lib:"
+                                             (getenv "PYTHONPATH")))
+                      (invoke "pytest" "-vv" "-k" "not test_parse_url"))))))
+    (home-page
+     "https://github.com/sbraz/pymediainfo")
+    (synopsis
+     "Python wrapper for the mediainfo library")
+    (description
+     "Python wrapper for the mediainfo library to access the technical and tag data for video and audio files.")
+    (license license:expat)))
+
 (define-public python-psutil
   (package
     (name "python-psutil")
-- 
2.24.0

^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2020-03-15 17:00 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <87sgjtgtju.fsf@cbaines.net>
2020-02-23 10:40 ` [bug#39292] [PATCH 10/10] gnu: Add rapid-photo-downloader Sebastian Schott
2020-02-23 16:55   ` Christopher Baines
2020-03-07 15:09     ` Sebastian Schott
2020-03-15 16:59       ` bug#39292: " Christopher Baines
2020-03-07 15:11 [bug#39292] [PATCH 01/10] gnu: Add python-pymediainfo Sebastian Schott
2020-03-07 15:11 ` [bug#39292] [PATCH 10/10] gnu: Add rapid-photo-downloader Sebastian Schott
  -- strict thread matches above, loose matches on Subject: below --
2020-02-02  9:36 [bug#39292] " Sebastian Schott
2020-02-02 10:11 ` Christopher Baines
2020-01-26 17:24 [bug#39292] [PATCH 01/10] gnu: Add python-pymediainfo Sebastian Schott
2020-01-26 17:24 ` [bug#39292] [PATCH 10/10] gnu: Add rapid-photo-downloader Sebastian Schott
2020-01-27  8:49   ` Christopher Baines

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).