Can't seem to use make due to glib-compile-schemas

So I’ve been trying to compile the gnome 40 version of dash-to-dock (found at Port to GNOME 40. by ewlsh · Pull Request #1402 · micheleg/dash-to-dock · GitHub) on my nix 21.05 setup as I have on a number of other distros. I’ve added gnumake to my environment yet when running it in the directory i get the error:

glib-compile-schemas ./schemas/ make: glib-compile-schemas: No such file or directory make: *** [Makefile:40: schemas/gschemas.compiled] Error 127

I’m probably missing something obvious here but if so I can’t seem to fix it.

thanks in advance for any help!

1 Like

That is in glib package. Also note we have gnomeExtensions.dash-to-dock: switch to fork to make it work with GNOME 40 by mohe2015 · Pull Request #135293 · NixOS/nixpkgs · GitHub merged to unstable.

2 Likes

I’m having the same problem trying to compile Material Shell (GitHub - material-shell/material-shell: A modern desktop interface for Linux. Improve your user experience and get rid of the anarchy of traditional desktop workflows. Designed to simplify navigation and reduce the need to manipulate windows in order to improve productivity. It's meant to be 100% predictable and bring the benefits of tools coveted by professionals to everyone.):

$ make
cp -r schemas dist
glib-compile-schemas dist/schemas/
make: glib-compile-schemas: No such file or directory
make: *** [Makefile:8: schemas] Error 127

I have both gnumake and glib installed. I’m running NixOS 21.11.

Any ideas?

glib-compile-schemas is part of dev output of glib package. Installation will not include dev output by default.

For environment.systemPackages, you can have it included in the buildEnv result using environment.extraOutputsToInstall = [ "dev" ]; option. Or just explicitly install glib.dev.

But I would not recommend that. Globally installing libraries is considered a bad practice. The Nix way is to use nix-shell -p glib, which will include dev output for glib (since nix-shell essentially puts the packages into buildInputs).

And do not even try nix-env, unless you find pain convenient.

5 Likes

Thanks very much @jtojnar that makes sense!