marienz / nix-doom-emacs-unstraightened

Builds Doom Emacs using Nix
Apache License 2.0
47 stars 3 forks source link

XWidgets support issue: #6

Closed simple-coderxx closed 3 months ago

simple-coderxx commented 4 months ago

Greetings, First of all, thank you so much for making this tool, having nix-doom-emacs broken has been very frustrating, but your tool seems to solve this issue very well, other than a few modules and flags that are broken or are missing an extra dependency, this installs doom emacs very well, so thanks again. Anyways, I am not sure how to build doom emacs with your tool, to be built with xwidgets support?

Here's what I used to use as an emacs overlay:

      (import (builtins.fetchTarball
        {
          url = https://github.com/nix-community/emacs-overlay/archive/e32ea52fb7488de5a89f93dafe3050c30dab21fd.tar.gz;
          sha256 = "1gf69nx2ajddvfdajbinlxyxj0r0z45sr3j40ilvvl8hv8iybrld";
        }))
      (self: super:
        {
          emacs29-withXwidgets = super.emacs29.override
            {
              withXwidgets = true;
              withGTK3 = true;
            };
        })
marienz commented 4 months ago

(Glancing at nixpkgs, looks like it's enabling Xwidgets by default on Linux with pgtk or gtk3, and there's emacs29-gtk3 enabling gtk3. So you may be able to use pkgs.emacs29-gtk3 from nixpkgs instead of your `emacs29-withXwidgets.)

I'd expect your emacs29-withXwidgets to work if passed into Unstraightened as emacs = pkgs.emacs29-withXwidgets (using either the Home Manager or overlay install instructions from the readme). If that's not working, can you please clarify?

If you're using the "Test run" instructions (nix run .#doom-example from a checkout of Unstraightened), it'd take some editing of flake.nix to get emacs29-withXwidgets in there (I can help with that).

If you're managing your packages in some other way, can you please clarify how you've added Unstraightened (without Xwidgets) to it, assuming you did get that working? I'm new enough to Nix I haven't really figured out how people typically manage their packages if they're not using a flake with nixosConfigurations and/or homeConfigurations...

marienz commented 3 months ago

I'm closing this for now, but happy to lend a hand and/or improve my documentation if you can provide steps to reproduce (a minimal configuration + commands to build/run it).