Guile, geiser and emacs

Good day all!

I am experiencing an interesting problem with emacs and guile when using geiser/geiser-guile. This is on a Gentoo installation. Long story short - I want to learn more guile in order to be able to wrangle my guix configuration more effectively (rather than cargo culting other configs!), and my desktop install is Gentoo.

So this is the problem:

I have emacs-30 and guile 3.0 installed, with the standard flags. I use the geiser and geiser-guile packages, with minimal configuration setup. The Geiser repl starts with no issues, and seems to be working properly. The problem I have manifests itself when load a simple scheme file and try to eval-sexp-before-point. I get an error:

ice-9/boot-9.scm:1676:22: In procedure raise-exception:
Unbound variable: ge:compile

ge:compile is a function in geiser-guile.

The load-path seems to be sane:

("/home/paul/.emacs.d/elpa/geiser-guile-20240920.35/src" "/usr/share/guile/3.0" "/usr/share/guile/site/3.0" "/usr/share/guile/site" "/usr/share/guile")

…and that is the correct location for the geiser-guile package.

I use the same configuration for emacs on my laptop with Guix - there, everything works as expected. I can’t identify any significant difference in the dotfiles between the two systems, so I am at a bit of a loss.

Have any of you experienced this before, or could you recommend areas for further exploration?

Thanks in advance!

Hi Paul,

Don’t know much about Gentoo, but curious if the problem happens if you use the Gentoo emacs packages for geiser and geiser-guile.

Worse case scenario is you can pollute your Gentoo with Guix (package manager) and it should work better and give you access to more libraries. You will most likely need this for hacking on your Guix config from Gentoo anyway.

Hi @trev - Thanks for the comment and suggestions.

I actually use the emacs packages, so you are right - it would be interesting to see if the gentoo distributed packages behave differently. I will give it a try.

Regarding hacking on my Guix config, I normally ssh into the laptop from my desktop, and do everything from there! The activity in emacs on the desktop is all about getting better with scheme, so I can read other configurations and wrangle my own more efficiently. I am trying to avoid putting the Guix package manager on top of Gentoo, but may go this way at some point in the future if necessary.

1 Like

I found the problem. In my configuration, I set up ispell and have the line

(setenv “LANG” “en_GB”)

The system defined LANG is en_GB.utf8, so this change seems to be causing problems. In fact, since the system has this variable defined already, I took it out of my config, and everything is working as expected.

One bonus I had from my last re-organisation of my emacs config - I moved each package into a sub file, so bisecting the config was straight forward!

3 Likes