unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
* Missing QT platform plugin for Wayland, GRUB menu-entry, and service/package definitions
@ 2023-01-23  4:28 Genevieve Mendoza
  2023-02-03  8:42 ` Timo Wilken
  0 siblings, 1 reply; 2+ messages in thread
From: Genevieve Mendoza @ 2023-01-23  4:28 UTC (permalink / raw)
  To: help-guix

Hello,

I've started using Guix recently, and have accumulated a lot of
questions since I started (it's been a good experience though - and I
really appreciate the great documentation!) I'm listing them below in
ascending order of complexity:

1) I've noticed that there are service definitions which automatically
pull in the packages they require, with the main example being
desktop-services. I set up some of my own home services, e.g. for
Pipewire, and they work fine if I also have Pipewire installed
(via my profile or home environment). If I don't, then they can't find
the binary and fail. Is there a way to have them specify required
packages that I missed in the docs?

2) I also want to run Nextcloud, and I'd like to run it under Wayland.
I made sure to install qtwayland-5 alongside it. However, I still get
an error message about missing the "Qt platform plugin "wayland"".
I found another bug report which stated that installing qtwayland-5
did solve the problem, and it also was all I needed back on Arch,
so it feels likely I'm doing something wrong here. I'd appreciate any
suggestions!

    https://mail.gnu.org/archive/html/bug-guix/2021-11/msg00216.html

2) Alternate menu-entries specified in my OS configuration seem to
fail to boot by default, but I thought I'd ask if I'm doing something
wrong before filing an issue. I have the following:

    (menu-entry
      (label "Arch") ;; menu entry name, not partition label
      (linux "(hd0,gpt5)/boot/vmlinuz-linux")
      (linux-arguments '("root=PARTUUID=[partuuid]" "rw"))
      (initrd "(hd0,gpt5)/boot/initramfs-linux.img"))

which creates this GRUB entry, which does not boot:

    menuentry "Arch" {
      search --file --set /root(hd0,gpt5)/boot/vmlinuz-linux
      linux /root(hd0,gpt5)/boot/vmlinuz-linux root=PARTUUID=...
      initrd /root(hd0,gpt5)/boot/initramfs-linux.img
    }

Since I did not specify (device), I expected it to create the
following, which successfully boots:

    menuentry "Arch" {
      linux (hd0,gpt5)/boot/vmlinuz-linux root=PARTUUID=[partuuid] rw
      initrd (hd0,gpt5)/boot/initramfs-linux.img
    }

3) I tried packaging some rust apps which are not in the repositories.
I needed to use two 'hacks' to succeed:

Some have a minimum supported rust above 1.60, so I did the following:

    (define rust-1.65 (@@ (gnu packages rust) rust-1.65))

The cargo build system would then fail due to "invalid inclusion of
reserved file name Cargo.toml.orig," a test added to Cargo in the
following patch: https://github.com/rust-lang/cargo/pull/10551.

I tried adding a step to delete Cargo.toml.orig, based on Nicolas
Graves's code in issue 25327 (https://issues.guix.gnu.org/25327#5):

    #:phases (modify-phases %standard-phases
      (add-before 'package 'hacky-delete
        (lambda _
          (delete-file "Cargo.toml.orig")
          #t)))

I was then able to successfully build. This raised a few questions:

a) Is there a better known workaround than this?

b) I couldn't find much discussion in the mailing lists - is cargo
packaging with more recent rust versions in progress, or is
there nobody currently working on it? (I don't mean to sound entitled
in asking this - just wondering the context!)

c) Semi-related - when packaging, I had to also package some more
recent dependency crates, including some platform-specific Windows
crates. In the cargo build system file, I found the following comment:

> Building a package definition does not require actually building /
> checking any dependent crates. This can be a benefit ... the build
> will not fail if cargo ends up internally ignoring the dependency.

However, I noticed that various crates had #:skip-build? #t and
various others had it set to false, and I couldn't make sense of
when or why to set it. What are the best practices for this option?

Best regards,

Genevieve


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

* Re: Missing QT platform plugin for Wayland, GRUB menu-entry, and service/package definitions
  2023-01-23  4:28 Missing QT platform plugin for Wayland, GRUB menu-entry, and service/package definitions Genevieve Mendoza
@ 2023-02-03  8:42 ` Timo Wilken
  0 siblings, 0 replies; 2+ messages in thread
From: Timo Wilken @ 2023-02-03  8:42 UTC (permalink / raw)
  To: Genevieve Mendoza; +Cc: help-guix

Hi Genevieve,

On Sun, Jan 22, 2023 at 10:28:30PM -0600, Genevieve Mendoza wrote:
> 1) I've noticed that there are service definitions which automatically
> pull in the packages they require, with the main example being
> desktop-services. I set up some of my own home services, e.g. for
> Pipewire, and they work fine if I also have Pipewire installed
> (via my profile or home environment). If I don't, then they can't find
> the binary and fail. Is there a way to have them specify required
> packages that I missed in the docs?

How do you refer to these packages in your own home services? The
standard way, as far as I know, is to use G-expressions. Here's an
example of a shepherd service I use that runs "nm-applet":

    (shepherd-service
     (documentation "Applet that provides a GUI for network connections.")
     (provision '(nm-applet))
     (start #~(make-forkexec-constructor
               (list #$(file-append network-manager-applet "/bin/nm-applet"))))
     (stop #~(make-kill-destructor)))

The #$(file-append package "/bin/exe") inside the G-expression will
resolve to the full /gnu/store/...-pipewire-0.3.36/bin/pipewire path,
and it ought to stop that path from being garbage-collected as long as
the home environment generation it belongs to exists.

See "info guix -n 'Shepherd Services'" for more specific examples, and
see "info guix -n G-Expressions" for more general information on
G-expressions.

I hope that helps, and I'm sorry I don't have any experience with the
other things you mentioned.

Cheers,
Timo


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

end of thread, other threads:[~2023-02-03  8:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-23  4:28 Missing QT platform plugin for Wayland, GRUB menu-entry, and service/package definitions Genevieve Mendoza
2023-02-03  8:42 ` Timo Wilken

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).