* [PATCH] Add sonata and python-mpd2
@ 2016-02-18 21:26 Christopher Baines
2016-02-18 21:26 ` [PATCH 1/2] gnu: Add python-mpd2 Christopher Baines
` (2 more replies)
0 siblings, 3 replies; 21+ messages in thread
From: Christopher Baines @ 2016-02-18 21:26 UTC (permalink / raw)
To: guix-devel
A couple of patches to package sonata (a music player daemon (mpd) client using
GTK3 and python). python-mpd2 was the only missing dependency.
[PATCH 1/2] gnu: Add python-mpd2
[PATCH 2/2] gnu: Add sonata
^ permalink raw reply [flat|nested] 21+ messages in thread
* [PATCH 1/2] gnu: Add python-mpd2
2016-02-18 21:26 [PATCH] Add sonata and python-mpd2 Christopher Baines
@ 2016-02-18 21:26 ` Christopher Baines
2016-02-18 22:00 ` Leo Famulari
2016-02-18 21:26 ` [PATCH 2/2] gnu: Add sonata Christopher Baines
2016-09-10 11:31 ` [PATCH] " Christopher Baines
2 siblings, 1 reply; 21+ messages in thread
From: Christopher Baines @ 2016-02-18 21:26 UTC (permalink / raw)
To: guix-devel
* gnu/packages/python.scm (python-mpd2): New variable
* gnu/packages/python.scm Import lgpl3.
---
gnu/packages/python.scm | 35 ++++++++++++++++++++++++++++++++---
1 file changed, 32 insertions(+), 3 deletions(-)
diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 24af2d8..73dab38 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -36,9 +36,9 @@
(define-module (gnu packages python)
#:use-module ((guix licenses)
#:select (asl2.0 bsd-4 bsd-3 bsd-2 non-copyleft cc0 x11 x11-style
- gpl2 gpl2+ gpl3+ lgpl2.0+ lgpl2.1 lgpl2.1+ lgpl3+ agpl3+
- isc mpl2.0 psfl public-domain unlicense x11-style
- zpl2.1))
+ gpl2 gpl2+ gpl3+ lgpl2.0+ lgpl2.1 lgpl2.1+ lgpl3 lgpl3+
+ agpl3+ isc mpl2.0 psfl public-domain unlicense
+ x11-style zpl2.1))
#:use-module ((guix licenses) #:select (expat zlib) #:prefix license:)
#:use-module (gnu packages)
#:use-module (gnu packages attr)
@@ -758,6 +758,35 @@ have been used.")
(package-with-python2 python-mock))
+(define-public python-mpd2
+ (package
+ (name "python-mpd2")
+ (version "0.5.5")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (pypi-uri "python-mpd2" version))
+ (sha256
+ (base32
+ "0laypd7h1j14b4vrmiayqlzdsh2j5hc3zv4l0fqvbrbw9y6763ii"))))
+ (build-system python-build-system)
+ (arguments
+ `(#:phases
+ (alist-replace
+ 'check
+ (lambda _ (zero? (system* "python" "mpd_test.py")))
+ %standard-phases)))
+ (inputs
+ `(("python-setuptools" ,python-setuptools)
+ ("python-mock" ,python-mock)
+ ("python-unittest2" ,python-unittest2)))
+ (home-page
+ "https://github.com/Mic92/python-mpd2")
+ (synopsis "Python MPD client library")
+ (description "A Python MPD client library")
+ (license lgpl3)))
+
+
(define-public python-setuptools
(package
(name "python-setuptools")
--
2.7.0
^ permalink raw reply related [flat|nested] 21+ messages in thread
* [PATCH 2/2] gnu: Add sonata
2016-02-18 21:26 [PATCH] Add sonata and python-mpd2 Christopher Baines
2016-02-18 21:26 ` [PATCH 1/2] gnu: Add python-mpd2 Christopher Baines
@ 2016-02-18 21:26 ` Christopher Baines
2016-02-18 23:57 ` Leo Famulari
2016-02-20 18:49 ` Thompson, David
2016-09-10 11:31 ` [PATCH] " Christopher Baines
2 siblings, 2 replies; 21+ messages in thread
From: Christopher Baines @ 2016-02-18 21:26 UTC (permalink / raw)
To: guix-devel
* gnu/packages/mpd.scm (sonata): New variable.
---
gnu/packages/mpd.scm | 30 ++++++++++++++++++++++++++++++
1 file changed, 30 insertions(+)
diff --git a/gnu/packages/mpd.scm b/gnu/packages/mpd.scm
index b5a0d94..2696f21 100644
--- a/gnu/packages/mpd.scm
+++ b/gnu/packages/mpd.scm
@@ -27,8 +27,11 @@
#:use-module (guix download)
#:use-module (guix utils)
#:use-module (guix build-system gnu)
+ #:use-module (guix build-system python)
#:use-module (gnu packages avahi)
#:use-module (gnu packages boost)
+ #:use-module (gnu packages gtk)
+ #:use-module (gnu packages gettext)
#:use-module (gnu packages icu4c)
#:use-module (gnu packages readline)
#:use-module (gnu packages compression)
@@ -39,6 +42,7 @@
#:use-module (gnu packages mp3)
#:use-module (gnu packages ncurses)
#:use-module (gnu packages pkg-config)
+ #:use-module (gnu packages python)
#:use-module (gnu packages autotools)
#:use-module (gnu packages pulseaudio)
#:use-module (gnu packages databases)
@@ -239,3 +243,29 @@ information about tracks being played to a scrobbler, such as Libre.FM.")
;; instead.
(home-page "http://mpd.wikia.com/wiki/Client:Mpdscribble")
(license license:gpl2+)))
+
+(define-public sonata
+ (package
+ (name "sonata")
+ (version "1.7b1")
+ (source (origin
+ (method url-fetch)
+ (uri
+ (string-append "https://github.com/multani/sonata/archive/v"
+ version ".tar.gz"))
+ (sha256
+ (base32
+ "07gq2nxqwxs0qyxjbay7k5j25zd386bn7wdr2dl1gk53diwnn7s0"))))
+ (build-system python-build-system)
+ (inputs `(("gettext" ,gnu-gettext)))
+ (propagated-inputs
+ `(("python-mpd2" ,python-mpd2)
+ ("gtk+" ,gtk+)
+ ("gobject-introspection" ,gobject-introspection)
+ ("python-pygobject" ,python-pygobject)))
+ (synopsis "Elegant client for the Music Player Daemon")
+ (description "Sonata is an elegant graphical client for the Music Player
+Daemon (MPD). It supports playlists, multiple profiles (connecting to different
+MPD servers, search and multimedia key support.")
+ (home-page "http://www.nongnu.org/sonata/")
+ (license license:gpl3+)))
--
2.7.0
^ permalink raw reply related [flat|nested] 21+ messages in thread
* Re: [PATCH 1/2] gnu: Add python-mpd2
2016-02-18 21:26 ` [PATCH 1/2] gnu: Add python-mpd2 Christopher Baines
@ 2016-02-18 22:00 ` Leo Famulari
2016-02-18 22:08 ` Christopher Baines
0 siblings, 1 reply; 21+ messages in thread
From: Leo Famulari @ 2016-02-18 22:00 UTC (permalink / raw)
To: Christopher Baines; +Cc: guix-devel
[-- Attachment #1: Type: text/plain, Size: 1892 bytes --]
On Thu, Feb 18, 2016 at 09:26:53PM +0000, Christopher Baines wrote:
> * gnu/packages/python.scm (python-mpd2): New variable
> * gnu/packages/python.scm Import lgpl3.
I actually have a patch for this in a WIP tree (attached). Based on the
differences, and the fact that I have already made the changes requested
below, I think my version of the patch should be used. My patch also
adds a python-2 version; when possible, it's preferred to add both
versions.
What do you think?
[...]
> +(define-public python-mpd2
> + (package
> + (name "python-mpd2")
> + (version "0.5.5")
> + (source
> + (origin
> + (method url-fetch)
> + (uri (pypi-uri "python-mpd2" version))
> + (sha256
> + (base32
> + "0laypd7h1j14b4vrmiayqlzdsh2j5hc3zv4l0fqvbrbw9y6763ii"))))
I'm glad to see we concur on this.
> + (build-system python-build-system)
> + (arguments
> + `(#:phases
> + (alist-replace
> + 'check
> + (lambda _ (zero? (system* "python" "mpd_test.py")))
> + %standard-phases)))
> + (inputs
> + `(("python-setuptools" ,python-setuptools)
> + ("python-mock" ,python-mock)
> + ("python-unittest2" ,python-unittest2)))
I don't believe that unittest2 is needed. I can build both
python-variants without it.
Setuptools is only needed for the python2-variant.
And, I think mock is only needed at build-time, so it would be a
native-input.
> + (home-page
> + "https://github.com/Mic92/python-mpd2")
> + (synopsis "Python MPD client library")
> + (description "A Python MPD client library")
Generally descriptions should be more descriptive than the synopsis.
> + (license lgpl3)))
I believe the license is lgpl3+, based on the "or later version" in
mpd.py.
> +
> +
> (define-public python-setuptools
> (package
> (name "python-setuptools")
> --
> 2.7.0
>
>
[-- Attachment #2: 0001-gnu-Add-python-mpd2.patch --]
[-- Type: text/x-diff, Size: 1933 bytes --]
From 03d428d2452a9a8b14e95e948939634cddcfd825 Mon Sep 17 00:00:00 2001
From: Leo Famulari <leo@famulari.name>
Date: Mon, 15 Feb 2016 04:33:49 -0500
Subject: [PATCH] gnu: Add python-mpd2.
* gnu/packages/python.scm (python-mpd2, python2-mpd2): New
* variables.
* gnu/packages/patches/python-mpd2-tests.patch: New file.
* gnu-system.am (dist_patch_DATA): Add it.
---
gnu/packages/python.scm | 31 +++++++++++++++++++++++++++++++
1 file changed, 31 insertions(+)
diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 8a44de9..7acb766 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -7821,3 +7821,34 @@ comparing Windows paths ignores casing.
(define-public python2-pathlib
(package-with-python2 python-pathlib))
+
+(define-public python-mpd2
+ (package
+ (name "python-mpd2")
+ (version "0.5.5")
+ (source (origin
+ (method url-fetch)
+ (uri (pypi-uri "python-mpd2" version))
+ (sha256
+ (base32
+ "0laypd7h1j14b4vrmiayqlzdsh2j5hc3zv4l0fqvbrbw9y6763ii"))))
+ (build-system python-build-system)
+ (arguments
+ '(#:phases
+ (modify-phases %standard-phases
+ (replace 'check
+ (lambda _ (zero? (system* "python" "mpd_test.py")))))))
+ (native-inputs `(("python-mock" ,python-mock)))
+ (home-page "https://github.com/Mic92/python-mpd2")
+ (synopsis "A Python MPD client library")
+ (description "Python-mpd2 is a Python library which provides a client
+interface for the Music Player Daemon.")
+ (license lgpl3+)
+ (properties `((python2-variant . ,(delay python2-mpd2))))))
+
+(define-public python2-mpd2
+ (let ((mpd2 (package-with-python2
+ (strip-python2-variant python-mpd2))))
+ (package (inherit mpd2)
+ (native-inputs `(("python2-setuptools" ,python2-setuptools)
+ ,@(package-native-inputs mpd2))))))
--
2.6.3
^ permalink raw reply related [flat|nested] 21+ messages in thread
* Re: [PATCH 1/2] gnu: Add python-mpd2
2016-02-18 22:00 ` Leo Famulari
@ 2016-02-18 22:08 ` Christopher Baines
2016-02-18 22:51 ` Leo Famulari
0 siblings, 1 reply; 21+ messages in thread
From: Christopher Baines @ 2016-02-18 22:08 UTC (permalink / raw)
To: Leo Famulari; +Cc: guix-devel
[-- Attachment #1: Type: text/plain, Size: 1550 bytes --]
On 18/02/16 22:00, Leo Famulari wrote:
> On Thu, Feb 18, 2016 at 09:26:53PM +0000, Christopher Baines wrote:
>> * gnu/packages/python.scm (python-mpd2): New variable
>> * gnu/packages/python.scm Import lgpl3.
>
> I actually have a patch for this in a WIP tree (attached). Based on the
> differences, and the fact that I have already made the changes requested
> below, I think my version of the patch should be used. My patch also
> adds a python-2 version; when possible, it's preferred to add both
> versions.
>
> What do you think?
That's fine by me.
>> + (build-system python-build-system)
>> + (arguments
>> + `(#:phases
>> + (alist-replace
>> + 'check
>> + (lambda _ (zero? (system* "python" "mpd_test.py")))
>> + %standard-phases)))
>> + (inputs
>> + `(("python-setuptools" ,python-setuptools)
>> + ("python-mock" ,python-mock)
>> + ("python-unittest2" ,python-unittest2)))
>
> I don't believe that unittest2 is needed. I can build both
> python-variants without it.
From looking at the source, I think its only needed for running the
tests with python2.6 [1].
1:
https://github.com/Mic92/python-mpd2/blob/6818984462552dbc7ca85d014f5cf9a8a1e81aec/mpd_test.py#L14
> Setuptools is only needed for the python2-variant.
>
> And, I think mock is only needed at build-time, so it would be a
> native-input.
I though native inputs had something to do with architectures, which I
guess won't matter here, so why is it not just an input?
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 949 bytes --]
^ permalink raw reply [flat|nested] 21+ messages in thread
* Re: [PATCH 1/2] gnu: Add python-mpd2
2016-02-18 22:08 ` Christopher Baines
@ 2016-02-18 22:51 ` Leo Famulari
0 siblings, 0 replies; 21+ messages in thread
From: Leo Famulari @ 2016-02-18 22:51 UTC (permalink / raw)
To: Christopher Baines; +Cc: guix-devel
On Thu, Feb 18, 2016 at 10:08:12PM +0000, Christopher Baines wrote:
> On 18/02/16 22:00, Leo Famulari wrote:
> > On Thu, Feb 18, 2016 at 09:26:53PM +0000, Christopher Baines wrote:
> >> * gnu/packages/python.scm (python-mpd2): New variable
> >> * gnu/packages/python.scm Import lgpl3.
> >
> > I actually have a patch for this in a WIP tree (attached). Based on the
> > differences, and the fact that I have already made the changes requested
> > below, I think my version of the patch should be used. My patch also
> > adds a python-2 version; when possible, it's preferred to add both
> > versions.
> >
> > What do you think?
>
> That's fine by me.
>
> >> + (build-system python-build-system)
> >> + (arguments
> >> + `(#:phases
> >> + (alist-replace
> >> + 'check
> >> + (lambda _ (zero? (system* "python" "mpd_test.py")))
> >> + %standard-phases)))
> >> + (inputs
> >> + `(("python-setuptools" ,python-setuptools)
> >> + ("python-mock" ,python-mock)
> >> + ("python-unittest2" ,python-unittest2)))
> >
> > I don't believe that unittest2 is needed. I can build both
> > python-variants without it.
>
> From looking at the source, I think its only needed for running the
> tests with python2.6 [1].
>
> 1:
> https://github.com/Mic92/python-mpd2/blob/6818984462552dbc7ca85d014f5cf9a8a1e81aec/mpd_test.py#L14
>
> > Setuptools is only needed for the python2-variant.
> >
> > And, I think mock is only needed at build-time, so it would be a
> > native-input.
>
> I though native inputs had something to do with architectures, which I
> guess won't matter here, so why is it not just an input?
The "native" part refers to the architecture of the build machine, which
is important when cross-compiling.
A side benefit is that end users shouldn't have to download
native-inputs when substituting. In some cases, that can save a lot of
bandwidth. So, we make build-time-only dependencies native-inputs. In
practice, I've seen packages end up with references to native-inputs in
their output, but that's not optimal.
Semi-relevant discussion of the problems of propagated-inputs:
http://lists.gnu.org/archive/html/guix-devel/2016-02/msg00810.html
^ permalink raw reply [flat|nested] 21+ messages in thread
* Re: [PATCH 2/2] gnu: Add sonata
2016-02-18 21:26 ` [PATCH 2/2] gnu: Add sonata Christopher Baines
@ 2016-02-18 23:57 ` Leo Famulari
2016-02-20 11:18 ` Andreas Enge
2016-02-20 18:49 ` Thompson, David
1 sibling, 1 reply; 21+ messages in thread
From: Leo Famulari @ 2016-02-18 23:57 UTC (permalink / raw)
To: Christopher Baines; +Cc: guix-devel
On Thu, Feb 18, 2016 at 09:26:54PM +0000, Christopher Baines wrote:
> * gnu/packages/mpd.scm (sonata): New variable.
It works! A little too well. I have no idea how it found the remote MPD
server on my LAN.
[...]
> + (inputs `(("gettext" ,gnu-gettext)))
Can somebody with more experience comment on whether or not this should
be propagated (assuming it's a runtime dependency, otherwise it should
be native)?
> + (propagated-inputs
> + `(("python-mpd2" ,python-mpd2)
> + ("gtk+" ,gtk+)
> + ("gobject-introspection" ,gobject-introspection)
> + ("python-pygobject" ,python-pygobject)))
> + (synopsis "Elegant client for the Music Player Daemon")
> + (description "Sonata is an elegant graphical client for the Music Player
> +Daemon (MPD). It supports playlists, multiple profiles (connecting to different
> +MPD servers, search and multimedia key support.")
> + (home-page "http://www.nongnu.org/sonata/")
> + (license license:gpl3+)))
^ permalink raw reply [flat|nested] 21+ messages in thread
* Re: [PATCH 2/2] gnu: Add sonata
2016-02-18 23:57 ` Leo Famulari
@ 2016-02-20 11:18 ` Andreas Enge
2016-02-20 12:37 ` Leo Famulari
0 siblings, 1 reply; 21+ messages in thread
From: Andreas Enge @ 2016-02-20 11:18 UTC (permalink / raw)
To: Leo Famulari; +Cc: guix-devel
On Thu, Feb 18, 2016 at 06:57:18PM -0500, Leo Famulari wrote:
> > + (inputs `(("gettext" ,gnu-gettext)))
> Can somebody with more experience comment on whether or not this should
> be propagated (assuming it's a runtime dependency, otherwise it should
> be native)?
It is most likely a native-input. You could run
guix gc --reference `./pre-inst-env guix build sonata`
to check whether gettext appears.
Andreas
^ permalink raw reply [flat|nested] 21+ messages in thread
* Re: [PATCH 2/2] gnu: Add sonata
2016-02-20 11:18 ` Andreas Enge
@ 2016-02-20 12:37 ` Leo Famulari
0 siblings, 0 replies; 21+ messages in thread
From: Leo Famulari @ 2016-02-20 12:37 UTC (permalink / raw)
To: Andreas Enge; +Cc: guix-devel
On Sat, Feb 20, 2016 at 12:18:34PM +0100, Andreas Enge wrote:
> On Thu, Feb 18, 2016 at 06:57:18PM -0500, Leo Famulari wrote:
> > > + (inputs `(("gettext" ,gnu-gettext)))
> > Can somebody with more experience comment on whether or not this should
> > be propagated (assuming it's a runtime dependency, otherwise it should
> > be native)?
>
> It is most likely a native-input. You could run
> guix gc --reference `./pre-inst-env guix build sonata`
> to check whether gettext appears.
Right! I haven't internalized this aspect of the system yet. Thanks for
the reminder!
Indeed, gettext is not referred to by sonata.
>
> Andreas
>
^ permalink raw reply [flat|nested] 21+ messages in thread
* Re: [PATCH 2/2] gnu: Add sonata
2016-02-18 21:26 ` [PATCH 2/2] gnu: Add sonata Christopher Baines
2016-02-18 23:57 ` Leo Famulari
@ 2016-02-20 18:49 ` Thompson, David
2016-02-29 7:18 ` Ricardo Wurmus
1 sibling, 1 reply; 21+ messages in thread
From: Thompson, David @ 2016-02-20 18:49 UTC (permalink / raw)
To: Christopher Baines; +Cc: guix-devel
On Thu, Feb 18, 2016 at 4:26 PM, Christopher Baines <mail@cbaines.net> wrote:
> * gnu/packages/mpd.scm (sonata): New variable.
This is really cool, thanks! Sonata was my main music player back in
the day and I'm glad to see that it's being maintained again. I
cleaned it up somewhat, built it, and ran it. I'm hesitant to push
the patch right now, though, and I hope someone who knows more about
Python can help me clear some things up.
I don't like that gtk+ and gobject-introspection need to be propagated
Could anyone familiar with creating Python bindings for C libraries
tell me if it would be possible to patch pygobject to include the
absolute path to the gtk+ and gobject-introspection libraries? This
has been the strategy for avoiding propagation of C libraries within
Guile packages, and I'm hoping it applies here.
Thanks,
- Dave
^ permalink raw reply [flat|nested] 21+ messages in thread
* Re: [PATCH 2/2] gnu: Add sonata
2016-02-20 18:49 ` Thompson, David
@ 2016-02-29 7:18 ` Ricardo Wurmus
0 siblings, 0 replies; 21+ messages in thread
From: Ricardo Wurmus @ 2016-02-29 7:18 UTC (permalink / raw)
To: Thompson, David; +Cc: guix-devel
Thompson, David <dthompson2@worcester.edu> writes:
> On Thu, Feb 18, 2016 at 4:26 PM, Christopher Baines <mail@cbaines.net> wrote:
>> * gnu/packages/mpd.scm (sonata): New variable.
>
> This is really cool, thanks! Sonata was my main music player back in
> the day and I'm glad to see that it's being maintained again. I
> cleaned it up somewhat, built it, and ran it. I'm hesitant to push
> the patch right now, though, and I hope someone who knows more about
> Python can help me clear some things up.
>
> I don't like that gtk+ and gobject-introspection need to be propagated
> Could anyone familiar with creating Python bindings for C libraries
> tell me if it would be possible to patch pygobject to include the
> absolute path to the gtk+ and gobject-introspection libraries? This
> has been the strategy for avoiding propagation of C libraries within
> Guile packages, and I'm hoping it applies here.
Yeah, propagating gtk+ is bad. I’d like to remove it from all packages
that currently do this. It bloats profiles and causes conflicts.
~~ Ricardo
^ permalink raw reply [flat|nested] 21+ messages in thread
* [PATCH] gnu: Add sonata
2016-02-18 21:26 [PATCH] Add sonata and python-mpd2 Christopher Baines
2016-02-18 21:26 ` [PATCH 1/2] gnu: Add python-mpd2 Christopher Baines
2016-02-18 21:26 ` [PATCH 2/2] gnu: Add sonata Christopher Baines
@ 2016-09-10 11:31 ` Christopher Baines
2016-09-10 11:31 ` Christopher Baines
2 siblings, 1 reply; 21+ messages in thread
From: Christopher Baines @ 2016-09-10 11:31 UTC (permalink / raw)
To: guix-devel
I've finally got around to updating the patch for sonata, sorry for the
long delay.
^ permalink raw reply [flat|nested] 21+ messages in thread
* [PATCH] gnu: Add sonata
2016-09-10 11:31 ` [PATCH] " Christopher Baines
@ 2016-09-10 11:31 ` Christopher Baines
2016-09-10 18:08 ` Leo Famulari
0 siblings, 1 reply; 21+ messages in thread
From: Christopher Baines @ 2016-09-10 11:31 UTC (permalink / raw)
To: guix-devel
* gnu/packages/mpd.scm (sonata): New variable.
---
gnu/packages/mpd.scm | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 52 insertions(+)
diff --git a/gnu/packages/mpd.scm b/gnu/packages/mpd.scm
index 279ec68..cc9d583 100644
--- a/gnu/packages/mpd.scm
+++ b/gnu/packages/mpd.scm
@@ -27,10 +27,14 @@
#:use-module (guix packages)
#:use-module (guix download)
#:use-module (guix utils)
+ #:use-module ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
#:use-module (guix build-system gnu)
#:use-module (guix build-system python)
#:use-module (gnu packages avahi)
#:use-module (gnu packages boost)
+ #:use-module (gnu packages gettext)
+ #:use-module (gnu packages gnome)
+ #:use-module (gnu packages gtk)
#:use-module (gnu packages icu4c)
#:use-module (gnu packages readline)
#:use-module (gnu packages compression)
@@ -263,3 +267,51 @@ interface for the Music Player Daemon.")
(package (inherit mpd2)
(native-inputs `(("python2-setuptools" ,python2-setuptools)
,@(package-native-inputs mpd2))))))
+
+(define-public sonata
+ (package
+ (name "sonata")
+ (version "1.7b1")
+ (source (origin
+ (method url-fetch)
+ (uri
+ (string-append "https://github.com/multani/sonata/archive/v"
+ version ".tar.gz"))
+ (file-name (string-append name "-" version ".tar.gz"))
+ (sha256
+ (base32
+ "07gq2nxqwxs0qyxjbay7k5j25zd386bn7wdr2dl1gk53diwnn7s0"))))
+ (build-system python-build-system)
+ (arguments
+ `(#:modules ((guix build gnu-build-system)
+ (guix build python-build-system)
+ ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
+ (guix build utils))
+ #:imported-modules (,@%gnu-build-system-modules
+ (guix build python-build-system)
+ (guix build glib-or-gtk-build-system))
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'install 'glib-or-gtk-wrap
+ (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap))
+ (add-after 'install 'wrap-sonata
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out"))
+ (gi-typelib-path (getenv "GI_TYPELIB_PATH")))
+ (wrap-program (string-append out "/bin/sonata")
+ `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path))))
+ #t)))))
+ (inputs
+ `(("gettext" ,gnu-gettext)
+ ("python-mpd2" ,python-mpd2)
+ ("gtk+" ,gtk+)
+ ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
+ ("gobject-introspection" ,gobject-introspection)
+ ("adwaita-icon-theme" ,adwaita-icon-theme)
+ ("python-pygobject" ,python-pygobject)))
+ (synopsis "Elegant client for the Music Player Daemon")
+ (description "Sonata is an elegant graphical client for the Music Player
+Daemon (MPD). It supports playlists, multiple profiles (connecting to different
+MPD servers, search and multimedia key support.")
+ (home-page "http://www.nongnu.org/sonata/")
+ (license license:gpl3+)))
--
2.9.3
^ permalink raw reply related [flat|nested] 21+ messages in thread
* Re: [PATCH] gnu: Add sonata
2016-09-10 11:31 ` Christopher Baines
@ 2016-09-10 18:08 ` Leo Famulari
2016-09-11 10:00 ` Christopher Baines
0 siblings, 1 reply; 21+ messages in thread
From: Leo Famulari @ 2016-09-10 18:08 UTC (permalink / raw)
To: Christopher Baines; +Cc: guix-devel
On Sat, Sep 10, 2016 at 12:31:33PM +0100, Christopher Baines wrote:
> * gnu/packages/mpd.scm (sonata): New variable.
Wow, I'm very happy to see this package fixed up :)
> + (inputs
> + `(("gettext" ,gnu-gettext)
All looks good to me except for the gettext issue discussed earlier.
$ guix gc --references $(./pre-inst-env guix build sonata)
substitute: warning: failed to install locale: Invalid argument
/gnu/store/62p7w5021dc0z8phyz4bilfgfjnxhzrq-sonata-1.7b1
/gnu/store/7dcbknnkd21k2wgc0irrn4w5r1kw1mw8-python-pygobject-3.20.0
/gnu/store/7l90h7hm54a92d6fiflwa14m8n5l6myk-at-spi2-core-2.20.1
/gnu/store/ac0zdn8jxn8dzn1pijwh2ab9psjq6fsq-shared-mime-info-1.6
/gnu/store/cmyllry2fvr7g2vjbcahgxn8nkpq228r-gsettings-desktop-schemas-3.20.0
/gnu/store/divvl90xbjma76lmhgfmwcp84lnz6ln6-gtk+-3.20.3
/gnu/store/dn2slclp4kf4mkk9pqamb9sdirac00sj-python-mpd2-0.5.5
/gnu/store/jfr7kjbhi8xirqx2sg4anh4ix61pg66z-adwaita-icon-theme-3.20
/gnu/store/l1s4cw9g58hmcpd2qgbckfl228143qzx-glib-2.48.0
/gnu/store/m473fzc84qsnqnqgb9l4hlardw4ymvbx-gdk-pixbuf+svg-2.34.0
/gnu/store/m4gc2wx4q9if1vrhgclpspdil7rqsn21-python-3.4.3
/gnu/store/rwfyznqxyqxzy242nklybqg5zpw5pl4q-pango-1.40.1
/gnu/store/vq1fk3zi8lkjds25h44y819aa19x78i3-atk-2.20.0
/gnu/store/w39sqjn61hvijpk7jagk1dm5plqq512n-gobject-introspection-1.48.0
/gnu/store/wa1yc835mb7pmmrj45xfgviqr5fbasqq-python-wrapper-3.4.3
/gnu/store/xp330hq98mz8qsqfwpqw0274zwb606c1-harfbuzz-1.2.4
/gnu/store/ykzwykkvr2c80rw4l1qh3mvfdkl7jibi-bash-4.3.42
The built package does not refer to gettext.
I altered the package to use gettext as a native-input, and then ran
sonata in a '--pure' environment, and it worked. Using strace, I
confirmed that sonata was not finding gettext on its own. I did not use
a container environment, since I couldn't figure out how to make the
graphical display work.
So, should we make gettext a native-input and add the package? :)
^ permalink raw reply [flat|nested] 21+ messages in thread
* [PATCH] gnu: Add sonata
2016-09-10 18:08 ` Leo Famulari
@ 2016-09-11 10:00 ` Christopher Baines
2016-09-11 10:00 ` Christopher Baines
0 siblings, 1 reply; 21+ messages in thread
From: Christopher Baines @ 2016-09-11 10:00 UTC (permalink / raw)
To: guix-devel
Yep, obviously didn't re-read the previous feedback thoroughly enough. gettext
is indeed only used at build time. I've attached an updated patch (with just
that change).
^ permalink raw reply [flat|nested] 21+ messages in thread
* [PATCH] gnu: Add sonata
2016-09-11 10:00 ` Christopher Baines
@ 2016-09-11 10:00 ` Christopher Baines
2016-09-11 15:08 ` Leo Famulari
2016-09-11 17:01 ` Alex Kost
0 siblings, 2 replies; 21+ messages in thread
From: Christopher Baines @ 2016-09-11 10:00 UTC (permalink / raw)
To: guix-devel
* gnu/packages/mpd.scm (sonata): New variable.
---
gnu/packages/mpd.scm | 53 ++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 53 insertions(+)
diff --git a/gnu/packages/mpd.scm b/gnu/packages/mpd.scm
index 279ec68..8b1b071 100644
--- a/gnu/packages/mpd.scm
+++ b/gnu/packages/mpd.scm
@@ -27,10 +27,14 @@
#:use-module (guix packages)
#:use-module (guix download)
#:use-module (guix utils)
+ #:use-module ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
#:use-module (guix build-system gnu)
#:use-module (guix build-system python)
#:use-module (gnu packages avahi)
#:use-module (gnu packages boost)
+ #:use-module (gnu packages gettext)
+ #:use-module (gnu packages gnome)
+ #:use-module (gnu packages gtk)
#:use-module (gnu packages icu4c)
#:use-module (gnu packages readline)
#:use-module (gnu packages compression)
@@ -263,3 +267,52 @@ interface for the Music Player Daemon.")
(package (inherit mpd2)
(native-inputs `(("python2-setuptools" ,python2-setuptools)
,@(package-native-inputs mpd2))))))
+
+(define-public sonata
+ (package
+ (name "sonata")
+ (version "1.7b1")
+ (source (origin
+ (method url-fetch)
+ (uri
+ (string-append "https://github.com/multani/sonata/archive/v"
+ version ".tar.gz"))
+ (file-name (string-append name "-" version ".tar.gz"))
+ (sha256
+ (base32
+ "07gq2nxqwxs0qyxjbay7k5j25zd386bn7wdr2dl1gk53diwnn7s0"))))
+ (build-system python-build-system)
+ (arguments
+ `(#:modules ((guix build gnu-build-system)
+ (guix build python-build-system)
+ ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
+ (guix build utils))
+ #:imported-modules (,@%gnu-build-system-modules
+ (guix build python-build-system)
+ (guix build glib-or-gtk-build-system))
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'install 'glib-or-gtk-wrap
+ (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap))
+ (add-after 'install 'wrap-sonata
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out"))
+ (gi-typelib-path (getenv "GI_TYPELIB_PATH")))
+ (wrap-program (string-append out "/bin/sonata")
+ `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path))))
+ #t)))))
+ (native-inputs
+ `(("gettext" ,gnu-gettext)))
+ (inputs
+ `(("python-mpd2" ,python-mpd2)
+ ("gtk+" ,gtk+)
+ ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
+ ("gobject-introspection" ,gobject-introspection)
+ ("adwaita-icon-theme" ,adwaita-icon-theme)
+ ("python-pygobject" ,python-pygobject)))
+ (synopsis "Elegant client for the Music Player Daemon")
+ (description "Sonata is an elegant graphical client for the Music Player
+Daemon (MPD). It supports playlists, multiple profiles (connecting to different
+MPD servers, search and multimedia key support.")
+ (home-page "http://www.nongnu.org/sonata/")
+ (license license:gpl3+)))
--
2.9.3
^ permalink raw reply related [flat|nested] 21+ messages in thread
* Re: [PATCH] gnu: Add sonata
2016-09-11 10:00 ` Christopher Baines
@ 2016-09-11 15:08 ` Leo Famulari
2016-09-12 16:04 ` Thompson, David
2016-09-11 17:01 ` Alex Kost
1 sibling, 1 reply; 21+ messages in thread
From: Leo Famulari @ 2016-09-11 15:08 UTC (permalink / raw)
To: Christopher Baines; +Cc: guix-devel
On Sun, Sep 11, 2016 at 11:00:37AM +0100, Christopher Baines wrote:
> * gnu/packages/mpd.scm (sonata): New variable.
Thanks! Pushed as 6c86cef5d36d613be0a62f8f18e276232abf51f0.
This will make it easier for my houseguests to control the stereo :)
^ permalink raw reply [flat|nested] 21+ messages in thread
* Re: [PATCH] gnu: Add sonata
2016-09-11 10:00 ` Christopher Baines
2016-09-11 15:08 ` Leo Famulari
@ 2016-09-11 17:01 ` Alex Kost
2016-09-11 18:11 ` Leo Famulari
2016-09-11 18:34 ` Christopher Baines
1 sibling, 2 replies; 21+ messages in thread
From: Alex Kost @ 2016-09-11 17:01 UTC (permalink / raw)
To: Christopher Baines; +Cc: guix-devel
Christopher Baines (2016-09-11 11:00 +0100) wrote:
> * gnu/packages/mpd.scm (sonata): New variable.
> ---
> gnu/packages/mpd.scm | 53 ++++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 53 insertions(+)
>
> diff --git a/gnu/packages/mpd.scm b/gnu/packages/mpd.scm
> index 279ec68..8b1b071 100644
> --- a/gnu/packages/mpd.scm
> +++ b/gnu/packages/mpd.scm
> @@ -27,10 +27,14 @@
> #:use-module (guix packages)
> #:use-module (guix download)
> #:use-module (guix utils)
> + #:use-module ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
This line is not needed. You use it in the #:modules argument in the
package definition, but it should not be put in the top level
'define-module' form.
> #:use-module (guix build-system gnu)
> #:use-module (guix build-system python)
> #:use-module (gnu packages avahi)
> #:use-module (gnu packages boost)
> + #:use-module (gnu packages gettext)
> + #:use-module (gnu packages gnome)
> + #:use-module (gnu packages gtk)
> #:use-module (gnu packages icu4c)
> #:use-module (gnu packages readline)
> #:use-module (gnu packages compression)
> @@ -263,3 +267,52 @@ interface for the Music Player Daemon.")
> (package (inherit mpd2)
> (native-inputs `(("python2-setuptools" ,python2-setuptools)
> ,@(package-native-inputs mpd2))))))
> +
> +(define-public sonata
> + (package
> + (name "sonata")
> + (version "1.7b1")
> + (source (origin
> + (method url-fetch)
> + (uri
> + (string-append "https://github.com/multani/sonata/archive/v"
> + version ".tar.gz"))
> + (file-name (string-append name "-" version ".tar.gz"))
> + (sha256
> + (base32
> + "07gq2nxqwxs0qyxjbay7k5j25zd386bn7wdr2dl1gk53diwnn7s0"))))
> + (build-system python-build-system)
> + (arguments
> + `(#:modules ((guix build gnu-build-system)
> + (guix build python-build-system)
> + ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
> + (guix build utils))
> + #:imported-modules (,@%gnu-build-system-modules
> + (guix build python-build-system)
> + (guix build glib-or-gtk-build-system))
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'install 'glib-or-gtk-wrap
> + (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap))
> + (add-after 'install 'wrap-sonata
> + (lambda* (#:key outputs #:allow-other-keys)
> + (let ((out (assoc-ref outputs "out"))
> + (gi-typelib-path (getenv "GI_TYPELIB_PATH")))
> + (wrap-program (string-append out "/bin/sonata")
> + `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path))))
> + #t)))))
> + (native-inputs
> + `(("gettext" ,gnu-gettext)))
> + (inputs
> + `(("python-mpd2" ,python-mpd2)
> + ("gtk+" ,gtk+)
> + ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
> + ("gobject-introspection" ,gobject-introspection)
> + ("adwaita-icon-theme" ,adwaita-icon-theme)
> + ("python-pygobject" ,python-pygobject)))
> + (synopsis "Elegant client for the Music Player Daemon")
> + (description "Sonata is an elegant graphical client for the Music Player
> +Daemon (MPD). It supports playlists, multiple profiles (connecting to different
> +MPD servers, search and multimedia key support.")
> + (home-page "http://www.nongnu.org/sonata/")
> + (license license:gpl3+)))
--
Alex
^ permalink raw reply [flat|nested] 21+ messages in thread
* Re: [PATCH] gnu: Add sonata
2016-09-11 17:01 ` Alex Kost
@ 2016-09-11 18:11 ` Leo Famulari
2016-09-11 18:34 ` Christopher Baines
1 sibling, 0 replies; 21+ messages in thread
From: Leo Famulari @ 2016-09-11 18:11 UTC (permalink / raw)
To: Alex Kost; +Cc: guix-devel
On Sun, Sep 11, 2016 at 08:01:19PM +0300, Alex Kost wrote:
> Christopher Baines (2016-09-11 11:00 +0100) wrote:
> > + #:use-module ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
>
> This line is not needed. You use it in the #:modules argument in the
> package definition, but it should not be put in the top level
> 'define-module' form.
Thanks Alex, I fixed it in a followup commit.
^ permalink raw reply [flat|nested] 21+ messages in thread
* Re: [PATCH] gnu: Add sonata
2016-09-11 17:01 ` Alex Kost
2016-09-11 18:11 ` Leo Famulari
@ 2016-09-11 18:34 ` Christopher Baines
1 sibling, 0 replies; 21+ messages in thread
From: Christopher Baines @ 2016-09-11 18:34 UTC (permalink / raw)
To: Alex Kost; +Cc: guix-devel
On 11/09/16 18:01, Alex Kost wrote:
> Christopher Baines (2016-09-11 11:00 +0100) wrote:
>
>> * gnu/packages/mpd.scm (sonata): New variable.
>> ---
>> gnu/packages/mpd.scm | 53 ++++++++++++++++++++++++++++++++++++++++++++++++++++
>> 1 file changed, 53 insertions(+)
>>
>> diff --git a/gnu/packages/mpd.scm b/gnu/packages/mpd.scm
>> index 279ec68..8b1b071 100644
>> --- a/gnu/packages/mpd.scm
>> +++ b/gnu/packages/mpd.scm
>> @@ -27,10 +27,14 @@
>> #:use-module (guix packages)
>> #:use-module (guix download)
>> #:use-module (guix utils)
>> + #:use-module ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
>
> This line is not needed. You use it in the #:modules argument in the
> package definition, but it should not be put in the top level
> 'define-module' form.
Ah, yep, that makes sense. Thanks Alex, and thanks for fixing Leo.
^ permalink raw reply [flat|nested] 21+ messages in thread
* Re: [PATCH] gnu: Add sonata
2016-09-11 15:08 ` Leo Famulari
@ 2016-09-12 16:04 ` Thompson, David
0 siblings, 0 replies; 21+ messages in thread
From: Thompson, David @ 2016-09-12 16:04 UTC (permalink / raw)
To: Leo Famulari; +Cc: guix-devel
On Sun, Sep 11, 2016 at 11:08 AM, Leo Famulari <leo@famulari.name> wrote:
> On Sun, Sep 11, 2016 at 11:00:37AM +0100, Christopher Baines wrote:
>> * gnu/packages/mpd.scm (sonata): New variable.
>
> Thanks! Pushed as 6c86cef5d36d613be0a62f8f18e276232abf51f0.
>
> This will make it easier for my houseguests to control the stereo :)
This is awesome. Thanks, everyone! Sonata used to be my music player
of choice many years ago until it became unmaintained, but it looks
like there is a new maintainer! I'll have to give it a go.
And using Sonata for visitors to control the stereo sounds like a
fantastic idea.
- Dave
^ permalink raw reply [flat|nested] 21+ messages in thread
end of thread, other threads:[~2016-09-12 16:06 UTC | newest]
Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-02-18 21:26 [PATCH] Add sonata and python-mpd2 Christopher Baines
2016-02-18 21:26 ` [PATCH 1/2] gnu: Add python-mpd2 Christopher Baines
2016-02-18 22:00 ` Leo Famulari
2016-02-18 22:08 ` Christopher Baines
2016-02-18 22:51 ` Leo Famulari
2016-02-18 21:26 ` [PATCH 2/2] gnu: Add sonata Christopher Baines
2016-02-18 23:57 ` Leo Famulari
2016-02-20 11:18 ` Andreas Enge
2016-02-20 12:37 ` Leo Famulari
2016-02-20 18:49 ` Thompson, David
2016-02-29 7:18 ` Ricardo Wurmus
2016-09-10 11:31 ` [PATCH] " Christopher Baines
2016-09-10 11:31 ` Christopher Baines
2016-09-10 18:08 ` Leo Famulari
2016-09-11 10:00 ` Christopher Baines
2016-09-11 10:00 ` Christopher Baines
2016-09-11 15:08 ` Leo Famulari
2016-09-12 16:04 ` Thompson, David
2016-09-11 17:01 ` Alex Kost
2016-09-11 18:11 ` Leo Famulari
2016-09-11 18:34 ` Christopher Baines
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.