* Permissions error during libhandy build - looking for tips
@ 2019-07-07 16:41 Jonathan Frederickson
2019-07-07 18:47 ` Jonathan Brielmaier
0 siblings, 1 reply; 5+ messages in thread
From: Jonathan Frederickson @ 2019-07-07 16:41 UTC (permalink / raw)
To: guix-devel
[-- Attachment #1: Type: text/plain, Size: 797 bytes --]
Hi! I'm trying to package libhandy for Guix, but I'm running into some
issues. libhandy uses Meson for builds - I'm not super familiar
with it, but it looks like something during the installation process is
trying to write to a path in /gnu/store that it doesn't have
permissions to write to.
I'm still fairly new to Guix packaging so it's not obvious to me why
this is failing at the moment. I've attached the build log and what I
have so far for the package definition. If anyone has advice that could
be helpful here, it would be highly appreciated!
(This package also has tests that look like they require access to an
X server, which fail - I think this is expected? I've just disabled
tests for the time being, but is there any way to actually run tests
like that during a build in Guix?)
[-- Attachment #2: pnr4lf4db2s0dpqzclhfg0326fpzgk-libhandy-v0.0.9.drv.bz2 --]
[-- Type: application/x-bzip, Size: 10114 bytes --]
[-- Attachment #3: libhandy.scm --]
[-- Type: text/x-scheme, Size: 1651 bytes --]
(define-module (libhandy)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
#:use-module (guix build-system meson)
#:use-module (guix download)
#:use-module (gnu packages glib)
#:use-module (gnu packages gtk)
#:use-module (gnu packages gnome)
#:use-module (gnu packages xml)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages cmake)
#:use-module (gnu packages gettext))
(define-public libhandy
(package
(name "libhandy")
(version "v0.0.9")
(source
(origin
(method url-fetch)
(uri (string-append "https://source.puri.sm/Librem5/libhandy/-/archive/"
version
"/libhandy-"
version
".tar.gz"))
(sha256
(base32 "18wqyfj33a184d0b030wlx9i5m67bpv2vp803nyglbj8m9pc1wx9"))))
(build-system meson-build-system)
(arguments
`(#:tests? #f))
(inputs
`(("gobject-introspection" ,gobject-introspection)
("gtk-doc" ,gtk-doc)
("glib" ,glib)
("gladeui" ,libglade)
("gnome-desktop" ,gnome-desktop)
("gtk+" ,gtk+)
("libxml2" ,libxml2)
("pkg-config" ,pkg-config)
("vala" ,vala)
("glade" ,glade3)))
(native-inputs
`(("glib:bin" ,glib "bin")
("gettext" ,gettext-minimal)))
(home-page "https://source.puri.sm/Librem5/libhandy")
(synopsis "A library full of GTK+ widgets for mobile phones")
(description "The aim of The handy library is to help with developing UI for mobile devices
using GTK+/GNOME.")
(license license:lgpl2.1)))
libhandy
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Permissions error during libhandy build - looking for tips
2019-07-07 16:41 Permissions error during libhandy build - looking for tips Jonathan Frederickson
@ 2019-07-07 18:47 ` Jonathan Brielmaier
2019-07-07 21:40 ` Jonathan Frederickson
0 siblings, 1 reply; 5+ messages in thread
From: Jonathan Brielmaier @ 2019-07-07 18:47 UTC (permalink / raw)
To: guix-devel
On 7/7/19 6:41 PM, Jonathan Frederickson wrote:
> Hi! I'm trying to package libhandy for Guix, but I'm running into some
> issues. libhandy uses Meson for builds - I'm not super familiar
> with it, but it looks like something during the installation process is
> trying to write to a path in /gnu/store that it doesn't have
> permissions to write to.
Hallo Jonathan,
I had a quick look at the log file and found this line:
PermissionError: [Errno 13] Permission denied:
'/gnu/store/m4jn72l561mppfh12br1vcrp9x9y812p-glade-3.22.1/lib/glade/modules/libglade-handy.so'
It tries to install the libglade-handy.so to the glade package, which is
forbidden. m4jn72l561mppfh12br1vcrp9x9y812p-glade-3.22.1 is a different
package, which you can't change during the install process of libhandy...
So there are two options from here:
- bring meson to install libglade-handy.so to the libhandy package
- don't intall libglade-handy.so at all
> I'm still fairly new to Guix packaging so it's not obvious to me why
> this is failing at the moment. I've attached the build log and what I
> have so far for the package definition. If anyone has advice that could
> be helpful here, it would be highly appreciated!
0.0.10 is out, I think we should package this version.
I would change this:
(origin
(method url-fetch)
(uri (string-append
"https://source.puri.sm/Librem5/libhandy/-/archive/"
version
"/libhandy-"
version
".tar.gz"))
to an origin based on git-fetch from a tag. This is usually better in
terms of reproducibility:
(source (origin
(method git-fetch)
(uri (git-reference
(url "https://source.puri.sm/Librem5/libhandy")
(commit version)))
(file-name (git-file-name name version))
> (This package also has tests that look like they require access to an
> X server, which fail - I think this is expected? I've just disabled
> tests for the time being, but is there any way to actually run tests
> like that during a build in Guix?)
I don't how to do this. For me it would be oke to disable the tests or
better to try to run those who doesn't require an X server.
By the way: Am I right in the assumption that you are interested in the
Librem 5?
Happy Hacking
Jonathan
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Permissions error during libhandy build - looking for tips
2019-07-07 18:47 ` Jonathan Brielmaier
@ 2019-07-07 21:40 ` Jonathan Frederickson
2019-07-08 9:23 ` Jonathan Brielmaier
0 siblings, 1 reply; 5+ messages in thread
From: Jonathan Frederickson @ 2019-07-07 21:40 UTC (permalink / raw)
To: Jonathan Brielmaier; +Cc: guix-devel
On Sun, 7 Jul 2019 20:47:06 +0200
Jonathan Brielmaier <jonathan.brielmaier@web.de> wrote:
> It tries to install the libglade-handy.so to the glade package, which
> is forbidden. m4jn72l561mppfh12br1vcrp9x9y812p-glade-3.22.1 is a
> different package, which you can't change during the install process
> of libhandy...
Ahh, yeah, makes sense. I noticed that store path is different than
the one for the glade package in my profile, so I thought Guix might
have extended the glade package somehow... guess not.
> So there are two options from here:
> - bring meson to install libglade-handy.so to the libhandy package
> - don't intall libglade-handy.so at all
Is the former the usual method for providing libraries like this? If
I'm interpreting this correctly, meson somehow found the path to the
glade package during the build, and I'd have to figure out how and
override that to ensure libglade-handy.so ends up in the build tree for
the libhandy package?
Assuming that's the case, am I correct in thinking that Glade (the UI
editor) will then be able to find libglade-handy.so because it'll be in
my profile?
> 0.0.10 is out, I think we should package this version.
You're right; I started attempting this before 0.0.10 came out, but
whenever I submit the package I'll pull in the latest version.
> I would change this:
> (origin
> (method url-fetch)
> (uri (string-append
> "https://source.puri.sm/Librem5/libhandy/-/archive/"
> version
> "/libhandy-"
> version
> ".tar.gz"))
>
> to an origin based on git-fetch from a tag. This is usually better in
> terms of reproducibility:
>
> (source (origin
> (method git-fetch)
> (uri (git-reference
> (url "https://source.puri.sm/Librem5/libhandy")
> (commit version)))
> (file-name (git-file-name name version))
Ah, I forgot that the parameter to "commit" could also be a tag. I'll
adjust that.
> By the way: Am I right in the assumption that you are interested in
> the Librem 5?
Yup! I saw someone having trouble installing libhandy in one of their
chatrooms, and I was thinking it might be interesting to try and get
some of their software running with Guix. (Who knows, maybe we could
run Guix System on the Librem 5 once it's out!)
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Permissions error during libhandy build - looking for tips
2019-07-07 21:40 ` Jonathan Frederickson
@ 2019-07-08 9:23 ` Jonathan Brielmaier
2019-07-08 15:53 ` Jonathan Brielmaier
0 siblings, 1 reply; 5+ messages in thread
From: Jonathan Brielmaier @ 2019-07-08 9:23 UTC (permalink / raw)
To: Jonathan Frederickson; +Cc: guix-devel
On 7/7/19 11:40 PM, Jonathan Frederickson wrote:>> So there are two
options from here:
>> - bring meson to install libglade-handy.so to the libhandy package
>> - don't intall libglade-handy.so at all
>
> Is the former the usual method for providing libraries like this? If
> I'm interpreting this correctly, meson somehow found the path to the
> glade package during the build, and I'd have to figure out how and
> override that to ensure libglade-handy.so ends up in the build tree for
> the libhandy package?
Usually in guix libraries also go in the same package and libglade-handy
gives the Glade "editor" libhandy "functionality". Sometimes we split up
packages in different "subpackages", but I don't think it's required
here. Libhandy will end up in the closure of GNOME sooner or later and
Glade is already in there (over libpeas -> totem).
> Assuming that's the case, am I correct in thinking that Glade (the UI
> editor) will then be able to find libglade-handy.so because it'll be in
> my profile?
Hmm, I'm not sure here, but you could try it :)
>> 0.0.10 is out, I think we should package this version.
>
> You're right; I started attempting this before 0.0.10 came out, but
> whenever I submit the package I'll pull in the latest version.
Fine :)
>> By the way: Am I right in the assumption that you are interested in
>> the Librem 5?
>
> Yup! I saw someone having trouble installing libhandy in one of their
> chatrooms, and I was thinking it might be interesting to try and get
> some of their software running with Guix. (Who knows, maybe we could
> run Guix System on the Librem 5 once it's out!)
As I (also) per ordered a Librem 5, I dream as well from running Guix
system on it. Maybe I'll open a tracker bug to track all the things we
need to run Guix on Librem 5 :)
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2019-07-08 15:54 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-07-07 16:41 Permissions error during libhandy build - looking for tips Jonathan Frederickson
2019-07-07 18:47 ` Jonathan Brielmaier
2019-07-07 21:40 ` Jonathan Frederickson
2019-07-08 9:23 ` Jonathan Brielmaier
2019-07-08 15:53 ` Jonathan Brielmaier
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).