Guix and Reform

Hi all,

Has anyone experimented yet with using Guix on the Reform, either as a foreign-distro package manager or as the actual operating system? I feel like Reform is an interesting use case since building the system image has special requirements. It would be cool to have the Reform system configuration defined in a guix package, which is just guile scheme.

I do not have my Reform in hand yet so cannot try it yet myself. But I’m curious to see whether or not this community is interested in looking into it.

4 Likes

I started doing this on the Pinebook Pro a while ago but ran into some issues (and my Pinebook is dead at the moment, haven’t had time to debug it): I was having issues getting it to boot off the NVME drive. It was a while ago and my memory is fuzzy, but I think it would be wonderful to have Guix running on the Reform!

There should be no problem with using Guix as a package manager; I did it on armhf before, and the aarch64 substitute availability for binary packages is improving currently.

As a complete operating system, the first thing I wonder about is whether the linux-libre kernel is sufficient to operate the Reform. If not, we would need to define a custom kernel with the appropriate patches.

1 Like

Yeah so that would mean somehow making the guix definition version of this file, correct?

I know nothing about kernels, nor about booting arm machines; it would be nice to bring people together on the Reform and on the Guix side to discuss it. Linux-libre is modified to disable loading non-free firmware. From what I understood, this makes it impossible to use the hdmi output of the Reform, but all other functionality should be available. The Linux kernel packages are defined in the linux module; for instance linux-libre-arm64-generic with a few specific configuration options.

Hi Andreas,
I also don’t know anything about kernels or even patching them. However, it seems like it’s possible to patch the kernel given the existence of the nonguix channel of packages – though I might be mistaken.

If I’m correct in my assumptions we could initiate a “reform” guix channel that has all reform-specific versions of things that we need, including a patched version of the libre kernel if that’s possible.

One sticky issue will be discussing this with actual Guix people in their own forums. There is a policy of not recommending or really discussing non-free software in those places. For us this is kind of unavoidable due to the few exceptions in the Reform system. I imagine, however, that we can get most of the way there.

:wave: I also plan to run Guix System on my Reform once it arrives. I don’t have any aarch64 experience though (prhaps I should have gotten an iMX.8 development board or something). I’d be surprised if getting Guix System to work would require anything that didn’t meet the Free Software Distribution Guidelines that Guix follows. I was under the impression that any non-free fimware needed was loaded before control was passed to the user’s operating system. I think we should try to get support in Guix proper as a first choice before resorting to a separate channel.

I do anticipate having to get creative with the following constraint though: I would like to run my system without an SD card and with an encrypted btrfs filesystem on NVMe. My experience on x86_64 hardware is that Guix configuration is more straight forward if the bootloader loads the kernal and initramfs directly from /gnu/store, not a separate /boot filesystem. I don’t know much about uboot. Does it have support of luks and btrfs? In the case where it doesn’t, I think I’d what to chain load grub from uboot, and then use that to boot the system.

Looks like it will be a fun ride :rocket: . I can’t wait!

2 Likes

Nice to see you here, @jackhill! Indeed I am also confident that it should be possible to make most of the functionality of the Reform machine available in a fully free distribution - after all, this is the point of the endeavour, free hardware for running free software! And clearly the more is upstreamed to the kernel and uboot, the easier it will be.

At least with booting from an SD card, we can be sure to not break anything definitely ;-). I would be happy to get a Guix system running in any way, then one could still look at more involved setups.

2 Likes

Hi,

I’m also interested in getting Guix system running on my Reform. Has anyone started working on this? If not, does anyone know of good docs on how to port Guix to it? I looked in the Guix manual and cookbook but didn’t find any “here’s how you port Guix to a new system” sections :slightly_smiling_face:.

Nice to hear of all the interest. Glad to know I’m not alone, then.

I’ve been trying to get it running. I wrote some thinking here: Re: Guix on the MNT Reform

I’ve started working on it but have run into some issues so far. They might be easy to deal with though so I’ll try to see if I can make sense of them before braindumping too much here.

2 Likes

Some updates: I’ve gotten the u-boot fork to compile now: Re: Guix on the MNT Reform

Probably wouldn’t be too much work to fill in the rest then…

2 Likes

Looks like the Reform’s reliance on the ddr4 firmware blob means that we won’t be able to have Reform support in Guix proper… it’s not letting me post updates linking to that thread due to some misaligned anti-spam feature on here annoyingly, but you can see it by clicking through the thread on the link I already put above.

However, I suspect we could get it shipped with the nonguix repo.

2 Likes

Hello everyone,

It’s been some time since I posted here, but I wanted to check in and see: has anyone been able to get Guix installed on their Reform? I would love to have a system config for it if you have one available.

I am also interested in this as I am considering a reform and would love to run guix on it

1 Like

Ok after some snooping around, I found the following repository. I don’t know anything about its provenance or how to run it. Anyone else familiar with this project?

Looks like @vagrantc has something to do with it…might want to ask them.

The real source is a branch in the official Guix git repository:
https://git.savannah.gnu.org/cgit/guix.git/log/?h=wip-mnt-reform
I have not tried it out yet.

Here is what Vagrant says about it:
https://lists.gnu.org/archive/html/guix-devel/2022-11/msg00286.html
So we do not yet have a complete image to run, and may never get there with the FSDG problems.

The package manager, however, can be installed in a matter of minutes using the official shell script
https://git.savannah.gnu.org/cgit/guix.git/plain/etc/guix-install.sh
and just works.

2 Likes

It is certainly plausible to get a workable image with guix, as long as you bring your own u-boot, though I have not yet actually tried it yet.

HDMI output still requires blobs, which linux-libre from Guix will not support, though you could also provide your own linux kernel if you need HDMI.

But most of the functionality was working for me with that old kernel. Would be good to refresh with a newer kernel version.

1 Like

Hi! Thanks for the update. Forgive my ignorance here. How might one accomplish what you’ve proposed given a guix system config? Would we have to pull in a reference to a different kernel from non-guix or similar? Same for u-boot?

I’d imagine @minute would be open to hosting the config on the mnt repo

I think it would be plausible to get most of the kernel patches merged into guix master; that’s what I worked on in the wip-mnt-reform branch.

Das U-Boot will have to come from somewhere else, either a channel specifically for the mnt/reform or maybe non-guix … or just manually installed from the binaries provided by the MNT folks.

If you want a kernel with HDMI and whatnot, you would probably have to use a non-guix or similar channel.