* bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate @ 2022-07-20 10:45 Maxime Devos 2022-07-20 10:59 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM " Maxime Devos ` (3 more replies) 0 siblings, 4 replies; 16+ messages in thread From: Maxime Devos @ 2022-07-20 10:45 UTC (permalink / raw) To: 56661 [-- Attachment #1.1.1: Type: text/plain, Size: 4338 bytes --] Hi, (the SLIM + Mate might be irrelevant, untested) I am using Guix System and Guix Home. In Guix Home, I've added the "emacs" and "emacs-magit" packages (and some others): > (home-environment > (packages > (specifications->packages > (list "git" "irssi" "evolution" "openssh" "gnupg" "htop" > "bash" "coreutils" "bash-completion" > "emacs" "emacs-magit" "emacs-paredit" > "icedove" "gnunet" "seahorse" #;"icedove-wayland"))) > (services > (list (service > home-bash-service-type > (home-bash-configuration > (aliases > '(("grep" . "grep --color=auto") > ("ll" . "ls -l") > ("ls" . "ls -p --color=auto"))) > (bashrc > (list (local-file ".bashrc" "bashrc"))) > (bash-profile > (list (local-file > ".bash_profile" > "bash_profile")))))))) For completeness, here is the .bash_profile and .bashrc (unmodified from base installation, except for removing a redundant alias): > # Honor per-interactive-shell startup file > if [ -f ~/.bashrc ]; then . ~/.bashrc; fi and > # Bash initialization for interactive non-login shells and > # for remote shells (info "(bash) Bash Startup Files"). > > # Export 'SHELL' to child processes. Programs such as 'screen' > # honor it and otherwise use /bin/sh. > export SHELL > > if [[ $- != *i* ]] > then > # We are being invoked from a non-interactive shell. If this > # is an SSH session (as in "ssh host command"), source > # /etc/profile so we get PATH and other essential variables. > [[ -n "$SSH_CLIENT" ]] && source /etc/profile > > # Don't do anything else. > return > fi > > # Source the system-wide file. > source /etc/bashrc > > # Adjust the prompt depending on whether we're in 'guix environment'. > if [ -n "$GUIX_ENVIRONMENT" ] > then > PS1='\u@\h \w [env]\$ ' > else > PS1='\u@\h \w\$ ' > fi After a "guix home reconfigure" and after a few reboots, I tried out emacs-magit, but there was no match for the "M-x magit-status". It turned out that $EMACSLOADPATH was unset. However, it is set in ~/.guix-home/profile/etc/profile: > # Source this file to define all the relevant environment variables in > Bash > # for this profile. You may want to define the 'GUIX_PROFILE' environment > # variable to point to the "visible" name of the profile, like this: > # > # GUIX_PROFILE=/path/to/profile ; \ > # source /path/to/profile/etc/profile > # > # When GUIX_PROFILE is undefined, the various environment variables refer > # to this specific profile generation. > > export > PATH="${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry8dxdm98ipk7d-profile}/bin:${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry> > export > GIT_EXEC_PATH="${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry8dxdm98ipk7d-profile}/libexec/git-core" > export > BASH_LOADABLES_PATH="${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry8dxdm98ipk7d-profile}/lib/bash${BASH_LOADABLES_PATH:+:}$BA> > export > INFOPATH="${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry8dxdm98ipk7d-profile}/share/info${INFOPATH:+:}$INFOPATH" > export > EMACSLOADPATH="${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry8dxdm98ipk7d-profile}/share/emacs/site-lisp${EMACSLOADPATH:+:}$E> > export > XDG_DATA_DIRS="${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry8dxdm98ipk7d-profile}/share${XDG_DATA_DIRS:+:}$XDG_DATA_DIRS" (nevermind the >, that's just me not making the terminal wide enough before copying) Weirdly, EMACSLOADPATH is not set (tested in a terminal), but PATH, GIT_EXEC_PATH, BASH_LOADABLES_PATH, INFOPATH and XDG_DATA_DIRS are set. Also, inside a login shell (bash --login) (started inside the graphical environment), EMACSLOADPATH is not set. Also, if I do "source ~/.guix-home/setup-environment", then $EMACSLOADPATH" is set. TBI ... Greetings, Maxime. [-- Attachment #1.1.2: OpenPGP public key --] [-- Type: application/pgp-keys, Size: 929 bytes --] [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 236 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate 2022-07-20 10:45 bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate Maxime Devos @ 2022-07-20 10:59 ` Maxime Devos 2022-07-20 12:08 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM " Andrew Tropin ` (2 subsequent siblings) 3 siblings, 0 replies; 16+ messages in thread From: Maxime Devos @ 2022-07-20 10:59 UTC (permalink / raw) To: 56661, control [-- Attachment #1.1.1: Type: text/plain, Size: 132 bytes --] retitle 56661 EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate Correction, I am using SDDM, not SLIM. [-- Attachment #1.1.2: OpenPGP public key --] [-- Type: application/pgp-keys, Size: 929 bytes --] [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 236 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate 2022-07-20 10:45 bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate Maxime Devos 2022-07-20 10:59 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM " Maxime Devos @ 2022-07-20 12:08 ` Andrew Tropin 2022-07-20 12:30 ` Maxime Devos 2022-07-22 10:24 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate Maxime Devos 2022-07-30 11:16 ` bug#56661: [PATCH] build-self: Try printing nicer error messages Maxime Devos 3 siblings, 1 reply; 16+ messages in thread From: Andrew Tropin @ 2022-07-20 12:08 UTC (permalink / raw) To: Maxime Devos, 56661 [-- Attachment #1: Type: text/plain, Size: 6453 bytes --] On 2022-07-20 12:45, Maxime Devos wrote: > Hi, > > (the SLIM + Mate might be irrelevant, untested) > > I am using Guix System and Guix Home. In Guix Home, I've added the > "emacs" and "emacs-magit" packages (and some others): > >> (home-environment >> (packages >> (specifications->packages >> (list "git" "irssi" "evolution" "openssh" "gnupg" "htop" >> "bash" "coreutils" "bash-completion" >> "emacs" "emacs-magit" "emacs-paredit" >> "icedove" "gnunet" "seahorse" #;"icedove-wayland"))) >> (services >> (list (service >> home-bash-service-type >> (home-bash-configuration >> (aliases >> '(("grep" . "grep --color=auto") >> ("ll" . "ls -l") >> ("ls" . "ls -p --color=auto"))) >> (bashrc >> (list (local-file ".bashrc" "bashrc"))) >> (bash-profile >> (list (local-file >> ".bash_profile" >> "bash_profile")))))))) > > For completeness, here is the .bash_profile and .bashrc (unmodified from > base installation, except for removing a redundant alias): > >> # Honor per-interactive-shell startup file >> if [ -f ~/.bashrc ]; then . ~/.bashrc; fi Hi Maxime, According to the documentation to get all the environment variables set correctly you either need to manage your login shell with Guix Home or do additional configuration of your shell: https://guix.gnu.org/manual/devel/en/html_node/Configuring-the-Shell.html From what I see you manage bash with Guix Home, so according to the source code your bash_profile should look differently from what you've posted and must contain `source ~/.profile` in it: https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/home/services/shells.scm#n440 This line makes your login shell source .profile, which sources setup-environment, which sources ~/.guix-home/profile/etc/profile, which sets EMACSLOADPATH. Additionally, I've built the home environment you provided and it contains the code I mentioned above. Make sure that ~/.bash_profile and ~/.guix-home/files/.bash_profile point to the same file in the store. > > and > >> # Bash initialization for interactive non-login shells and >> # for remote shells (info "(bash) Bash Startup Files"). >> >> # Export 'SHELL' to child processes. Programs such as 'screen' >> # honor it and otherwise use /bin/sh. >> export SHELL >> >> if [[ $- != *i* ]] >> then >> # We are being invoked from a non-interactive shell. If this >> # is an SSH session (as in "ssh host command"), source >> # /etc/profile so we get PATH and other essential variables. >> [[ -n "$SSH_CLIENT" ]] && source /etc/profile >> >> # Don't do anything else. >> return >> fi >> >> # Source the system-wide file. >> source /etc/bashrc >> >> # Adjust the prompt depending on whether we're in 'guix environment'. >> if [ -n "$GUIX_ENVIRONMENT" ] >> then >> PS1='\u@\h \w [env]\$ ' >> else >> PS1='\u@\h \w\$ ' >> fi > > After a "guix home reconfigure" and after a few reboots, I tried out > emacs-magit, but there was no match for the "M-x magit-status". It > turned out that $EMACSLOADPATH was unset. However, it is set in > ~/.guix-home/profile/etc/profile: > >> # Source this file to define all the relevant environment variables in >> Bash >> # for this profile. You may want to define the 'GUIX_PROFILE' environment >> # variable to point to the "visible" name of the profile, like this: >> # >> # GUIX_PROFILE=/path/to/profile ; \ >> # source /path/to/profile/etc/profile >> # >> # When GUIX_PROFILE is undefined, the various environment variables refer >> # to this specific profile generation. >> >> export >> PATH="${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry8dxdm98ipk7d-profile}/bin:${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry> >> export >> GIT_EXEC_PATH="${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry8dxdm98ipk7d-profile}/libexec/git-core" >> export >> BASH_LOADABLES_PATH="${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry8dxdm98ipk7d-profile}/lib/bash${BASH_LOADABLES_PATH:+:}$BA> >> export >> INFOPATH="${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry8dxdm98ipk7d-profile}/share/info${INFOPATH:+:}$INFOPATH" >> export >> EMACSLOADPATH="${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry8dxdm98ipk7d-profile}/share/emacs/site-lisp${EMACSLOADPATH:+:}$E> >> export >> XDG_DATA_DIRS="${GUIX_PROFILE:-/gnu/store/ll0p9k6yp5070svjhwry8dxdm98ipk7d-profile}/share${XDG_DATA_DIRS:+:}$XDG_DATA_DIRS" > > (nevermind the >, that's just me not making the terminal wide enough > before copying) > > Weirdly, EMACSLOADPATH is not set (tested in a terminal), but PATH, > GIT_EXEC_PATH, BASH_LOADABLES_PATH, INFOPATH and XDG_DATA_DIRS are set. > Also, inside a login shell (bash --login) (started inside the graphical > environment), EMACSLOADPATH is not set. > > Also, if I do "source ~/.guix-home/setup-environment", then > $EMACSLOADPATH" is set. > > TBI ... > > Greetings, > Maxime. > > > -----BEGIN PGP PUBLIC KEY BLOCK----- > > xjMEX4ch6BYJKwYBBAHaRw8BAQdANPb/d6MrGnGi5HyvODCkBUJPRjiFQcRU5V+m > xvMaAa/NL01heGltZSBEZXZvcyA8bWF4aW1lLmRldm9zQHN0dWRlbnQua3VsZXV2 > ZW4uYmU+wpAEExYIADgWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCX4ch6AIbAwUL > CQgHAwUVCgkICwUWAgMBAAIeAQIXgAAKCRBJ4+4iGRcl7japAQC3opZ2KGWzWmRc > /gIWSu0AAcfMwyinFEEPa/QhUt2CogD/e2RdF4CYAgaRHJJmZ9WU7piKbLZ7llB4 > LzgezVDHggzNJU1heGltZSBEZXZvcyA8bWF4aW1lZGV2b3NAdGVsZW5ldC5iZT7C > kAQTFggAOBYhBMHzPuIMUo/bfdcBH0nj7iIZFyXuBQJf56ycAhsDBQsJCAcDBRUK > CQgLBRYCAwEAAh4BAheAAAoJEEnj7iIZFyXujpQBAKV1SwDDl4f24rXciDlB9L8W > ycZt30CgbewMSRQk4mvbAP9dFMbVVixYBd6C8cfhR+NsOBGiOJnQABlUmgNuqGFJ > Dc44BF+HIegSCisGAQQBl1UBBQEBB0BOlzIWiJzgobMF6/cqwLaLk7jIcFSZ++c0 > k9cCNT6YXwMBCAfCeAQYFggAIBYhBMHzPuIMUo/bfdcBH0nj7iIZFyXuBQJfhyHo > AhsMAAoJEEnj7iIZFyXuMr0BAJc8cl5PGvVmVuSQVKjleNl4DK1/XAaPAYPe34AE > fZJPAP9IqLCQhH/FeJanHqBP8gNdGNI2qn8RnnLVfRJgUjZ1BA== > =OVqp > -----END PGP PUBLIC KEY BLOCK----- -- Best regards, Andrew Tropin [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 832 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate 2022-07-20 12:08 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM " Andrew Tropin @ 2022-07-20 12:30 ` Maxime Devos 2022-07-20 17:47 ` Andrew Tropin 0 siblings, 1 reply; 16+ messages in thread From: Maxime Devos @ 2022-07-20 12:30 UTC (permalink / raw) To: Andrew Tropin, 56661 [-- Attachment #1.1.1: Type: text/plain, Size: 3901 bytes --] On 20-07-2022 14:08, Andrew Tropin wrote: > Hi Maxime, > > According to the documentation to get all the environment variables set > correctly you either need to manage your login shell with Guix Home or > do additional configuration of your shell: > https://guix.gnu.org/manual/devel/en/html_node/Configuring-the-Shell.html I am not using a login shell, though I suppose there might be one under the hood somewhere (IIRC, and if it hasn't changed, some login managers are wrapped in Guix System to insert a bash --login in-between). Even if I am using a (non-login) shell, there's still an issue: if I start an application via the graphical things, they don't get all the environment variables (I tested this by opening a terminal that starts bash and doing "echo $EMACSLOADPATH", but that a shell is used for the test seems irrelevant here to me). > From what I see you manage bash with Guix Home, I am not. I just keep the default ~/.bash_profile etc that a fresh Guix System install gave me and the only reason bash_profile things appear in the home configuration is because "guix home import" generated that. I'm not managing anything, just keeping the defaults. > so according to the > source code your bash_profile should look differently from what you've > posted and must contain `source ~/.profile` in it: ~/.bash_profile does contain that line: # Set up the system, user profile, and related variables. # /etc/profile will be sourced by bash automatically # Set up the home environment profile. if [ -f ~/.profile ]; then source ~/.profile; fi # Honor per-interactive-shell startup file if [ -f ~/.bashrc ]; then source ~/.bashrc; fi # Honor per-interactive-shell startup file if [ -f ~/.bashrc ]; then . ~/.bashrc; fi However, .bash_profile (the one from the local-file) does not: # Honor per-interactive-shell startup file if [ -f ~/.bashrc ]; then . ~/.bashrc; fi > https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/home/services/shells.scm#n440 > > This line makes your login shell I am not using a login shell but a graphical environment -- the only reason I actually use a shell at all is because I find it more convenient to open a terminal and type "emacs" than to look in the graphical desktop thingy for the Emacs icon. Also, I'm not finding Emacs here even though in the previous installation of Guix System (GDM + Mate IIRC, without Guix Home but with "guix install ...". Icedove isn't appearing there either, though the browser is. I recall that it login shells were not necessary on Guix System + ~/.guix-profile (without Guix Home), at least for the desktop environment combination I used back then, though it was required on my Debian system to do "bash --login". I can do "bash --login" on my Guix System + Guix Home setup to start a login shell, but that would be a regression. > source .profile, which sources > setup-environment, which sources ~/.guix-home/profile/etc/profile, which > sets EMACSLOADPATH. > > Additionally, I've built the home environment you provided and it > contains the code I mentioned above. > > Make sure that ~/.bash_profile and ~/.guix-home/files/.bash_profile > point to the same file in the store. antipode@antipode ~$ ls -l .bash_profile lrwxrwxrwx 1 antipode users 56 19 jul 22:14 .bash_profile -> /gnu/store/1cq87qf8zccxlnkjwifcyhawmxvy7wfw-bash_profile antipode@antipode ~$ ls -l ~/.guix-home/files/.bash_profile lrwxrwxrwx 1 root root 56 1 jan 1970 /home/antipode/.guix-home/files/.bash_profile -> /gnu/store/1cq87qf8zccxlnkjwifcyhawmxvy7wfw-bash_profile They do. Also, shouldn't ~/.bash_profile point to ~/.guix-home/files/.bash_profile instead of directly to the store, to be more atomic (unrelated to #56661 though), like done for symlinks in /etc in Guix System? Greetings, Maxime. [-- Attachment #1.1.2: OpenPGP public key --] [-- Type: application/pgp-keys, Size: 929 bytes --] [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 236 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate 2022-07-20 12:30 ` Maxime Devos @ 2022-07-20 17:47 ` Andrew Tropin 2022-07-22 9:28 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM " Maxime Devos 2022-07-22 9:32 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM " Maxime Devos 0 siblings, 2 replies; 16+ messages in thread From: Andrew Tropin @ 2022-07-20 17:47 UTC (permalink / raw) To: Maxime Devos, 56661 [-- Attachment #1: Type: text/plain, Size: 5192 bytes --] On 2022-07-20 14:30, Maxime Devos wrote: > On 20-07-2022 14:08, Andrew Tropin wrote: >> Hi Maxime, >> >> According to the documentation to get all the environment variables set >> correctly you either need to manage your login shell with Guix Home or >> do additional configuration of your shell: >> https://guix.gnu.org/manual/devel/en/html_node/Configuring-the-Shell.html > > I am not using a login shell, though I suppose there might be one under > the hood somewhere (IIRC, and if it hasn't changed, some login managers > are wrapped in Guix System to insert a bash --login in-between). Even if > I am using a (non-login) shell, there's still an issue: if I start an > application via the graphical things, they don't get all the environment > variables (I tested this by opening a terminal that starts bash and > doing "echo $EMACSLOADPATH", but that a shell is used for the test seems > irrelevant here to me). > >> From what I see you manage bash with Guix Home, > I am not. I just keep the default ~/.bash_profile etc that a fresh Guix > System install gave me and the only reason bash_profile things appear in > the home configuration is because "guix home import" generated that. I'm > not managing anything, just keeping the defaults. You are ;) Declaring home-bash-service-type in home environment means that Guix Home will generate and install bash configurations, which means you are managing bash configurations with Guix Home. >> so according to the >> source code your bash_profile should look differently from what you've >> posted and must contain `source ~/.profile` in it: > > ~/.bash_profile does contain that line: > > # Set up the system, user profile, and related variables. > # /etc/profile will be sourced by bash automatically > # Set up the home environment profile. > if [ -f ~/.profile ]; then source ~/.profile; fi > > # Honor per-interactive-shell startup file > if [ -f ~/.bashrc ]; then source ~/.bashrc; fi > # Honor per-interactive-shell startup file > if [ -f ~/.bashrc ]; then . ~/.bashrc; fi You can remove your original bash_profile, because it's just duplicates last two lines, Guix Home adds the same content as skeletons provided during system installation and a little more. > > However, .bash_profile (the one from the local-file) does not: > > # Honor per-interactive-shell startup file > if [ -f ~/.bashrc ]; then . ~/.bashrc; fi > > >> https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/home/services/shells.scm#n440 >> >> This line makes your login shell > > I am not using a login shell but a graphical environment -- the only > reason I actually use a shell at all is because I find it more > convenient to open a terminal and type "emacs" than to look in the > graphical desktop thingy for the Emacs icon. Also, I'm not finding Emacs > here even though in the previous installation of Guix System (GDM + Mate > IIRC, without Guix Home but with "guix install ...". Icedove isn't > appearing there either, though the browser is. > > I recall that it login shells were not necessary on Guix System + > ~/.guix-profile (without Guix Home), at least for the desktop > environment combination I used back then, though it was required on my > Debian system to do "bash --login". I can do "bash --login" on my Guix > System + Guix Home setup to start a login shell, but that would be a > regression. > I'm not sure how your login/display manager works, but for X11 session sourcing ~/.profile from ~/.xsession should do the trick. Put the following content to your ~/.xsession: --8<---------------cut here---------------start------------->8--- . ~/.profile --8<---------------cut here---------------end--------------->8--- Or add the following service to your home environment: --8<---------------cut here---------------start------------->8--- (simple-service 'xsession-init-file home-files-service-type `((".xsession" ,(plain-file "xsession" ". ~/.profile")))) --8<---------------cut here---------------end--------------->8--- >> source .profile, which sources >> setup-environment, which sources ~/.guix-home/profile/etc/profile, which >> sets EMACSLOADPATH. >> >> Additionally, I've built the home environment you provided and it >> contains the code I mentioned above. >> >> Make sure that ~/.bash_profile and ~/.guix-home/files/.bash_profile >> point to the same file in the store. > > antipode@antipode ~$ ls -l .bash_profile > lrwxrwxrwx 1 antipode users 56 19 jul 22:14 .bash_profile -> > /gnu/store/1cq87qf8zccxlnkjwifcyhawmxvy7wfw-bash_profile > > antipode@antipode ~$ ls -l ~/.guix-home/files/.bash_profile > lrwxrwxrwx 1 root root 56 1 jan 1970 > /home/antipode/.guix-home/files/.bash_profile -> > /gnu/store/1cq87qf8zccxlnkjwifcyhawmxvy7wfw-bash_profile > > They do. Also, shouldn't ~/.bash_profile point to > ~/.guix-home/files/.bash_profile instead of directly to the store, to be > more atomic (unrelated to #56661 though), like done for symlinks in /etc > in Guix System? No. Activation is not atomic process anyway. -- Best regards, Andrew Tropin [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 832 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate 2022-07-20 17:47 ` Andrew Tropin @ 2022-07-22 9:28 ` Maxime Devos 2022-07-22 10:17 ` Maxime Devos 2022-07-22 9:32 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM " Maxime Devos 1 sibling, 1 reply; 16+ messages in thread From: Maxime Devos @ 2022-07-22 9:28 UTC (permalink / raw) To: Andrew Tropin, 56661 [-- Attachment #1.1.1: Type: text/plain, Size: 2006 bytes --] On 20-07-2022 19:47, Andrew Tropin wrote: > I'm not sure how your login/display manager works, but for X11 session > sourcing ~/.profile from ~/.xsession should do the trick. > > Put the following content to your ~/.xsession: > --8<---------------cut here---------------start------------->8--- > . ~/.profile > --8<---------------cut here---------------end--------------->8--- > > Or add the following service to your home environment: > --8<---------------cut here---------------start------------->8--- > (simple-service > 'xsession-init-file > home-files-service-type > `((".xsession" ,(plain-file "xsession" ". ~/.profile")))) > --8<---------------cut here---------------end--------------->8--- Tweaking .xsession was not necessary in my previous Guix System without Home setup, so this seems like a work-around to me, not a solution. However, possibly this is a bug in the setup of the login manager I used (previously I used another one), so I will try a different login manager as possibly Guix Home is not related here. > They do. Also, shouldn't ~/.bash_profile point to > ~/.guix-home/files/.bash_profile instead of directly to the store, to be > more atomic (unrelated to #56661 though), like done for symlinks in /etc > in Guix System? > No. > > Activation is not atomic process anyway. I know it is not atomic. That's the issue I noted, an issue that seems to have a partial solution I also noted. With current file system APIs, it cannot be made fully atomic, but as done for Guix System things, it can at least be made _partially_ atomic -- i.e., when no files are added or removed relative to the previous generation, the symlink switching is atomic. (A form of 'Perfect enemy of the good' -- if perfect (= 100% atomic) cannot be found, then that's no reason to throw away good (= mostly atomic).) (Also an instance of is-ought: it is not atomic, but that doesn't mean it should be non-atomic.) Greetings, Maxime. [-- Attachment #1.1.2: OpenPGP public key --] [-- Type: application/pgp-keys, Size: 929 bytes --] [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 236 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate 2022-07-22 9:28 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM " Maxime Devos @ 2022-07-22 10:17 ` Maxime Devos 0 siblings, 0 replies; 16+ messages in thread From: Maxime Devos @ 2022-07-22 10:17 UTC (permalink / raw) To: Andrew Tropin, 56661 [-- Attachment #1.1.1: Type: text/plain, Size: 349 bytes --] On 22-07-2022 11:28, Maxime Devos wrote: > However, possibly this is a bug in the setup of the login manager I > used (previously I used another one), so I will try a different login > manager as possibly Guix Home is not related here. For GDM, the issue does not occur (and I don't have to create ~/.xsession). Greetings, Maxime. [-- Attachment #1.1.2: OpenPGP public key --] [-- Type: application/pgp-keys, Size: 929 bytes --] [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 236 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate 2022-07-20 17:47 ` Andrew Tropin 2022-07-22 9:28 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM " Maxime Devos @ 2022-07-22 9:32 ` Maxime Devos 2022-07-22 13:03 ` Andrew Tropin 1 sibling, 1 reply; 16+ messages in thread From: Maxime Devos @ 2022-07-22 9:32 UTC (permalink / raw) To: Andrew Tropin, 56661 [-- Attachment #1.1.1: Type: text/plain, Size: 494 bytes --] On 20-07-2022 19:47, Andrew Tropin wrote: > I'm not sure how your login/display manager works, but for X11 session > sourcing ~/.profile from ~/.xsession should do the trick. Me neither, and I don't particularly care. If this is something that needs to be done, shouldn't _Guix System_ create that file by default, for the same reason that Guix System creates a ~/.profile and ~/.bash_profile by default? I don't see why I would have to do that myself. Greetings, Maxime [-- Attachment #1.1.2: OpenPGP public key --] [-- Type: application/pgp-keys, Size: 929 bytes --] [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 236 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate 2022-07-22 9:32 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM " Maxime Devos @ 2022-07-22 13:03 ` Andrew Tropin 2022-07-22 13:13 ` bug#56661: SDDM does not do the equivalent of 'login shell --login', unlike other login managers Maxime Devos 0 siblings, 1 reply; 16+ messages in thread From: Andrew Tropin @ 2022-07-22 13:03 UTC (permalink / raw) To: Maxime Devos, 56661 [-- Attachment #1: Type: text/plain, Size: 1088 bytes --] On 2022-07-22 11:32, Maxime Devos wrote: > On 20-07-2022 19:47, Andrew Tropin wrote: > >> I'm not sure how your login/display manager works, but for X11 session >> sourcing ~/.profile from ~/.xsession should do the trick. > Me neither, and I don't particularly care. > > If this is something that needs to be done, shouldn't _Guix System_ > create that file by default, for the same reason that Guix System > creates a ~/.profile and ~/.bash_profile by default? I don't see why I > would have to do that myself. It's a tricky question, because it's a case on the edge of Home/System. From one point of view it should be handled by some home service, which will create a proper ~/.xsession or extend it and generic mechanism, from some display managers will automatically source it, but on the other hand maybe adjusting system services for other DMs, which doesn't work "out of the box" yet is a way to go. I don't have much experience with X11, and don't see a whole picture, so it's hard to tell which option is better. -- Best regards, Andrew Tropin [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 832 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: SDDM does not do the equivalent of 'login shell --login', unlike other login managers 2022-07-22 13:03 ` Andrew Tropin @ 2022-07-22 13:13 ` Maxime Devos 0 siblings, 0 replies; 16+ messages in thread From: Maxime Devos @ 2022-07-22 13:13 UTC (permalink / raw) To: Andrew Tropin, 56661 [-- Attachment #1.1.1.1: Type: text/plain, Size: 2952 bytes --] On 22-07-2022 15:03, Andrew Tropin wrote: > It's a tricky question, because it's a case on the edge of Home/System. > From one point of view it should be handled by some home service, which > will create a proper ~/.xsession or extend it and generic mechanism, Such a mechanism already exists for GDM and SLiM, see later (though it doesn't create ~/.xessionrc, it's more stateless, and it is independent of Guix Home). I don't see why Guix Home should handle things, it doesn't seem to have anything to handle (unless you go for the alternative, more stateful, solution you are proposing?). > from some display managers will automatically source it, but on the > other hand maybe adjusting system services for other DMs, which doesn't > work "out of the box" yet is a way to go. I don't have much experience > with X11, and don't see a whole picture, so it's hard to tell which > option is better. I think I've found a solution that works for Guix System, independent of Guix Home (doesn't depend on Guix Home and doesn't interfere with Guix Home and doesn't require Guix System and Guix Home to interact), as written in another response (thread is getting a bit long!): > On 22-07-2022 12:24, Maxime Devos wrote: >> retitle 56661 SDDM does not do the equivalent of 'login shell >> --login', unlike other login managers >> thanks >> >> A digged a little, and found that: >> >> For GDM, things work, for SDDM, they don't. >> >> There is a 'xinitrc' procedure in gnu/services/xorg.scm that >> generates a configuration file that has a fallback .xsession that >> does a --login. This is used by gdm-wayland-session-wrapper, >> <gdm-configuration> and slim-shepherd-service. However, nothing >> similar appears to be done for SDDM. So it appears that the SDDM >> service needs to be tweaked to use xinitrc or such. > > It appears that SDDM supports xinitrc files, but it looks for them > (see data/scripts/Xsession) in $HOME/.xsessionrc and > /etc/X11/xinit/xinitrc.d, which do not exist in Guix. There is no > option for overriding the xinitrc. However, it is possible to > override the Xsession script used, so we can give SDDM a modified > Xsession script that uses Guix' xinitrc. TBC: the 'xinitrc' that Guix generates does not override the ~/.xinitrc written by the user (if any) -- IIUC, the generated wrapper looks for ~/.xinitrc and if it exists, it runs that, but if it doesn't exist, it has a fallback. Also, TBC, it doesn't create ~/.xsessionrc (unlike what you seem to be proposing), the relevant code just tells the login manager to look at /gnu/store/...-the-generated-xinitrc. It seems to work for GDM and presumably also for SLiM, which has similar code. As such, I would expect it to work without problems for SDDM as well (please write SDDM in the subject line, the original SLiM is incorrect, I actually used SDDM). Greetings, Maxime [-- Attachment #1.1.1.2: Type: text/html, Size: 3954 bytes --] [-- Attachment #1.1.2: OpenPGP public key --] [-- Type: application/pgp-keys, Size: 929 bytes --] [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 236 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate 2022-07-20 10:45 bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate Maxime Devos 2022-07-20 10:59 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM " Maxime Devos 2022-07-20 12:08 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM " Andrew Tropin @ 2022-07-22 10:24 ` Maxime Devos 2022-07-22 10:44 ` Maxime Devos 2022-07-30 11:16 ` bug#56661: [PATCH] build-self: Try printing nicer error messages Maxime Devos 3 siblings, 1 reply; 16+ messages in thread From: Maxime Devos @ 2022-07-22 10:24 UTC (permalink / raw) To: 56661 [-- Attachment #1.1.1: Type: text/plain, Size: 608 bytes --] retitle 56661 SDDM does not do the equivalent of 'login shell --login', unlike other login managers thanks A digged a little, and found that: For GDM, things work, for SDDM, they don't. There is a 'xinitrc' procedure in gnu/services/xorg.scm that generates a configuration file that has a fallback .xsession that does a --login. This is used by gdm-wayland-session-wrapper, <gdm-configuration> and slim-shepherd-service. However, nothing similar appears to be done for SDDM. So it appears that the SDDM service needs to be tweaked to use xinitrc or such. Greetings, Maxime [-- Attachment #1.1.2: OpenPGP public key --] [-- Type: application/pgp-keys, Size: 929 bytes --] [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 236 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate 2022-07-22 10:24 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate Maxime Devos @ 2022-07-22 10:44 ` Maxime Devos 2022-07-22 11:00 ` bug#56661: SDDM does not do the equivalent of 'login shell --login', unlike other login managers Maxime Devos 2022-07-22 13:15 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate Andrew Tropin 0 siblings, 2 replies; 16+ messages in thread From: Maxime Devos @ 2022-07-22 10:44 UTC (permalink / raw) To: 56661 [-- Attachment #1.1.1: Type: text/plain, Size: 1069 bytes --] On 22-07-2022 12:24, Maxime Devos wrote: > retitle 56661 SDDM does not do the equivalent of 'login shell > --login', unlike other login managers > thanks > > A digged a little, and found that: > > For GDM, things work, for SDDM, they don't. > > There is a 'xinitrc' procedure in gnu/services/xorg.scm that generates > a configuration file that has a fallback .xsession that does a > --login. This is used by gdm-wayland-session-wrapper, > <gdm-configuration> and slim-shepherd-service. However, nothing > similar appears to be done for SDDM. So it appears that the SDDM > service needs to be tweaked to use xinitrc or such. It appears that SDDM supports xinitrc files, but it looks for them (see data/scripts/Xsession) in $HOME/.xsessionrc and /etc/X11/xinit/xinitrc.d, which do not exist in Guix. There is no option for overriding the xinitrc. However, it is possible to override the Xsession script used, so we can give SDDM a modified Xsession script that uses Guix' xinitrc. I'll give that a try. Greetings, Maxime [-- Attachment #1.1.2: OpenPGP public key --] [-- Type: application/pgp-keys, Size: 929 bytes --] [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 236 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: SDDM does not do the equivalent of 'login shell --login', unlike other login managers 2022-07-22 10:44 ` Maxime Devos @ 2022-07-22 11:00 ` Maxime Devos 2022-07-22 13:15 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate Andrew Tropin 1 sibling, 0 replies; 16+ messages in thread From: Maxime Devos @ 2022-07-22 11:00 UTC (permalink / raw) To: 56661 [-- Attachment #1.1.1: Type: text/plain, Size: 1263 bytes --] On 22-07-2022 12:44, Maxime Devos wrote: > > On 22-07-2022 12:24, Maxime Devos wrote: >> retitle 56661 SDDM does not do the equivalent of 'login shell >> --login', unlike other login managers >> thanks >> >> A digged a little, and found that: >> >> For GDM, things work, for SDDM, they don't. >> >> There is a 'xinitrc' procedure in gnu/services/xorg.scm that >> generates a configuration file that has a fallback .xsession that >> does a --login. This is used by gdm-wayland-session-wrapper, >> <gdm-configuration> and slim-shepherd-service. However, nothing >> similar appears to be done for SDDM. So it appears that the SDDM >> service needs to be tweaked to use xinitrc or such. > > It appears that SDDM supports xinitrc files, but it looks for them > (see data/scripts/Xsession) in $HOME/.xsessionrc and > /etc/X11/xinit/xinitrc.d, which do not exist in Guix. There is no > option for overriding the xinitrc. However, it is possible to > override the Xsession script used, so we can give SDDM a modified > Xsession script that uses Guix' xinitrc. I'll give that a try. > Actually, I'll be doing other things first, but for anyone interested, this sounds like a likely solution to me. Greetings, Maxime. [-- Attachment #1.1.2: OpenPGP public key --] [-- Type: application/pgp-keys, Size: 929 bytes --] [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 236 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate 2022-07-22 10:44 ` Maxime Devos 2022-07-22 11:00 ` bug#56661: SDDM does not do the equivalent of 'login shell --login', unlike other login managers Maxime Devos @ 2022-07-22 13:15 ` Andrew Tropin 1 sibling, 0 replies; 16+ messages in thread From: Andrew Tropin @ 2022-07-22 13:15 UTC (permalink / raw) To: Maxime Devos, 56661 [-- Attachment #1: Type: text/plain, Size: 1232 bytes --] On 2022-07-22 12:44, Maxime Devos wrote: > On 22-07-2022 12:24, Maxime Devos wrote: >> retitle 56661 SDDM does not do the equivalent of 'login shell >> --login', unlike other login managers >> thanks >> >> A digged a little, and found that: >> >> For GDM, things work, for SDDM, they don't. >> >> There is a 'xinitrc' procedure in gnu/services/xorg.scm that generates >> a configuration file that has a fallback .xsession that does a >> --login. This is used by gdm-wayland-session-wrapper, >> <gdm-configuration> and slim-shepherd-service. However, nothing >> similar appears to be done for SDDM. So it appears that the SDDM >> service needs to be tweaked to use xinitrc or such. The idea looks good to me. > > It appears that SDDM supports xinitrc files, but it looks for them > (see data/scripts/Xsession) in $HOME/.xsessionrc and > /etc/X11/xinit/xinitrc.d, which do not exist in Guix. There is no > option for overriding the xinitrc. However, it is possible to > override the Xsession script used, so we can give SDDM a modified > Xsession script that uses Guix' xinitrc. I'll give that a try. Just a note: .xsessionrc is debian-specific IIRC -- Best regards, Andrew Tropin [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 832 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: [PATCH] build-self: Try printing nicer error messages. 2022-07-20 10:45 bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate Maxime Devos ` (2 preceding siblings ...) 2022-07-22 10:24 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate Maxime Devos @ 2022-07-30 11:16 ` Maxime Devos 2022-07-30 11:17 ` Maxime Devos 3 siblings, 1 reply; 16+ messages in thread From: Maxime Devos @ 2022-07-30 11:16 UTC (permalink / raw) To: 56661 [-- Attachment #1.1.1: Type: text/plain, Size: 191 bytes --] This (reviewed!) patch would be helpful for debugging <https://debbugs.gnu.org/cgi/bugreport.cgi?bug=56836> and many other "guix pull: You found a bug" reports. Greetings, Maxime. [-- Attachment #1.1.2: OpenPGP public key --] [-- Type: application/pgp-keys, Size: 929 bytes --] [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 236 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
* bug#56661: [PATCH] build-self: Try printing nicer error messages. 2022-07-30 11:16 ` bug#56661: [PATCH] build-self: Try printing nicer error messages Maxime Devos @ 2022-07-30 11:17 ` Maxime Devos 0 siblings, 0 replies; 16+ messages in thread From: Maxime Devos @ 2022-07-30 11:17 UTC (permalink / raw) To: 56661 [-- Attachment #1.1.1: Type: text/plain, Size: 256 bytes --] On 30-07-2022 13:16, Maxime Devos wrote: > This (reviewed!) patch would be helpful for debugging > <https://debbugs.gnu.org/cgi/bugreport.cgi?bug=56836> and many other > "guix pull: You found a bug" reports. > Nevermind sent to the wrong number. [-- Attachment #1.1.2: OpenPGP public key --] [-- Type: application/pgp-keys, Size: 929 bytes --] [-- Attachment #2: OpenPGP digital signature --] [-- Type: application/pgp-signature, Size: 236 bytes --] ^ permalink raw reply [flat|nested] 16+ messages in thread
end of thread, other threads:[~2022-07-30 11:18 UTC | newest] Thread overview: 16+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2022-07-20 10:45 bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM + Mate Maxime Devos 2022-07-20 10:59 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM " Maxime Devos 2022-07-20 12:08 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM " Andrew Tropin 2022-07-20 12:30 ` Maxime Devos 2022-07-20 17:47 ` Andrew Tropin 2022-07-22 9:28 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM " Maxime Devos 2022-07-22 10:17 ` Maxime Devos 2022-07-22 9:32 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SLIM " Maxime Devos 2022-07-22 13:03 ` Andrew Tropin 2022-07-22 13:13 ` bug#56661: SDDM does not do the equivalent of 'login shell --login', unlike other login managers Maxime Devos 2022-07-22 10:24 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate Maxime Devos 2022-07-22 10:44 ` Maxime Devos 2022-07-22 11:00 ` bug#56661: SDDM does not do the equivalent of 'login shell --login', unlike other login managers Maxime Devos 2022-07-22 13:15 ` bug#56661: EMACSLOADPATH not set when using Guix System + Guix Home + SDDM + Mate Andrew Tropin 2022-07-30 11:16 ` bug#56661: [PATCH] build-self: Try printing nicer error messages Maxime Devos 2022-07-30 11:17 ` Maxime Devos
Code repositories for project(s) associated with this external index https://git.savannah.gnu.org/cgit/guix.git This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.