From unknown Sun Jun 22 11:38:37 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#62955 <62955@debbugs.gnu.org> To: bug#62955 <62955@debbugs.gnu.org> Subject: Status: Guix Home Breaks Some Foreign Distros Reply-To: bug#62955 <62955@debbugs.gnu.org> Date: Sun, 22 Jun 2025 18:38:37 +0000 retitle 62955 Guix Home Breaks Some Foreign Distros reassign 62955 guix submitter 62955 Zacchaeus Scheffer severity 62955 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Wed Apr 19 16:50:28 2023 Received: (at submit) by debbugs.gnu.org; 19 Apr 2023 20:50:28 +0000 Received: from localhost ([127.0.0.1]:35984 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ppEl2-0004tp-5t for submit@debbugs.gnu.org; Wed, 19 Apr 2023 16:50:28 -0400 Received: from lists.gnu.org ([209.51.188.17]:53120) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ppEkz-0004td-Ld for submit@debbugs.gnu.org; Wed, 19 Apr 2023 16:50:27 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ppEkx-0002jJ-JX for bug-guix@gnu.org; Wed, 19 Apr 2023 16:50:23 -0400 Received: from mail-pl1-x632.google.com ([2607:f8b0:4864:20::632]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ppEkv-00043i-JX for bug-guix@gnu.org; Wed, 19 Apr 2023 16:50:23 -0400 Received: by mail-pl1-x632.google.com with SMTP id d9443c01a7336-1a6762fd23cso3879825ad.3 for ; Wed, 19 Apr 2023 13:50:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1681937419; x=1684529419; h=mime-version:message-id:date:subject:to:from:from:to:cc:subject :date:message-id:reply-to; bh=QssWAlHSTO2mpfh2CvLqvyuPmn3npy8c2uiN7n7adKw=; b=A1BLiMfZzG+OMKyJur+3Nk/82rWbbIngza82OAlCqgiqN+8wnOvxCUbwMDcZ94RWkP sHmBuVSJTOSWKn9+O0teeK850AdFWkwVY9yrrF7RTpv4WsUMsk7+rFy1iyYFbmWii2wQ 2dXRW7C5SDeL3IdwtIuzu1VpeGWzHSKI+fo6gH/FOcd4cZLfAVfBDkRGa8MuYPfr9W0G xEoII/vywmmR/S/TF0GG9PAS7RLvHT2csnkozZms853QSIdmVINahbZsqDuPF7dcG9qS bzYynI+bVXuTS7zz5t3IoqdjV2Zfsga4SeVQLKLCONlcnke6W6lMlWFFQBX63Cktl39Y 2rXA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681937419; x=1684529419; h=mime-version:message-id:date:subject:to:from:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=QssWAlHSTO2mpfh2CvLqvyuPmn3npy8c2uiN7n7adKw=; b=U/FvNXEItSBkbr+FeZzdk4qzHaKzBqQqaiU9y30/Hfk5ItDhYC6cCe74Ag9OfX62Jb aGsd0/fGomPE+Hyz+jRAD+hklwLN7bSR9M8btiNlkA+/CfVMwcZXeZcCGnxeyeYIQDjG m31RtlQZFcqg5rFjOreP6fxadc8JPbsy/sY+2YCcRjbDZ2fAViB8eWRhkYexj63CLrAb O3EtIIYSO2guiQWBdKjYli82k8LKimRPdkf46Hus0gGH0L6lIDR1CWp9iMaRkt16f9EA Xu6Y+py40DcRf/pH2GdfeiKK57VaVMEyga0+nh2KsMwnssQF40M64po/ss24l1lwUSj7 +tzg== X-Gm-Message-State: AAQBX9c+nIZTKKB4nv5/9EYGTOo+GTbZpyb46KD8a9gFLr72AUwqtJ1o 3FEIawPV6eyDzEU6FkTRwq/GOSmlzIA= X-Google-Smtp-Source: AKy350baL9SmDumNJFBxjDRFvchJ3xpaK8if3vry7VJG9eoAlfE+9Ly4iZ4vr33b+jjHe1DhRLCTiA== X-Received: by 2002:a17:903:2094:b0:1a1:d624:2fe2 with SMTP id d20-20020a170903209400b001a1d6242fe2mr5262563plc.17.1681937419119; Wed, 19 Apr 2023 13:50:19 -0700 (PDT) Received: from igor ([192.147.44.15]) by smtp.gmail.com with ESMTPSA id bf5-20020a170902b90500b001a6f7744a27sm4253782plb.87.2023.04.19.13.50.18 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 19 Apr 2023 13:50:18 -0700 (PDT) From: Zacchaeus Scheffer To: bug-guix@gnu.org Subject: Guix Home Breaks Some Foreign Distros Date: Wed, 19 Apr 2023 13:50:17 -0700 Message-ID: <871qkfiol2.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::632; envelope-from=zaccysc@gmail.com; helo=mail-pl1-x632.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) Hi all! $HOME/PROFILE/setup-environment contains the following lines: case $XDG_CONFIG_DIRS in *$HOME_ENVIRONMENT/profile/etc/xdg*) ;; *) export XDG_CONFIG_DIRS=$HOME_ENVIRONMENT/profile/etc/xdg:$XDG_CONFIG_DIRS ;; esac There are two bugs in this code. Both bugs revolve around what happens if XDG_CONFIG_DIRS is unset, as is the case in some foreign distros. The first problem is if, XDG_CONFIG_DIRS is unset, and $HOME_ENVIRONMENT/profile/etc/xdg does not exist, then the conditional resolves to "is the empty string in the empty string", so XDG_CONFIG_DIRS is prepended with $HOME_ENVIRONMENT/profile/etc/xdg, despite it not existing. I'm not sure if incuding a nonexistant path in XDG_CONFIG_DIRS should cause problems, but this scenario is not mentioned in the XDG specifications[1], so some programs are bound to crash because of this. The second problem (more important) relates to how XDG_CONFIG_DIRS is interpreted if empty vs set to a value. As per the xdg specifications[1], if XDG_CONFIG_DIRS is unset, then a value of /etc/xdg should be used. When an empty XDG_CONFIG_DIRS is set by guix home, programs find a non-empty value and ignore /etc/xdg. The above problem means that when I do a guix home reconfigure on my Librem 5 running PureOS, I get a black screen as Phosh fails to start as it needs files in /etc/xdg. I can fix it by adding: XDG_CONFIG_DIRS="$XDG_CONFIG_DIRS:/etc/xdg" to my .zlogin. A similar issue can be seen with the lines regarding XDG_DATA_DIRS in $HOME/PROFILE/setup-environment. I think a good step to resovling this issue is to set empty variables to their default value first. Maybe something like the following in gnu/home/services.scm:267 ... [ -f $PROFILE_FILE ] && . $PROFILE_FILE [ -z "$XDG_DATA_DIRS"] && XDG_DATA_DIRS=/usr/local/share/:/usr/share/ [ -z "$XDG_CONFIG_DIRS"] && XDG_CONFIG_DIRS=/etc/xdg case $XDG_DATA_DIRS in ... This addresses the second problem, but not the first. Someone may find a more elegant way to deal with both issues. -Zacchae [1] https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html From debbugs-submit-bounces@debbugs.gnu.org Wed Apr 19 17:05:52 2023 Received: (at 62955) by debbugs.gnu.org; 19 Apr 2023 21:05:53 +0000 Received: from localhost ([127.0.0.1]:36003 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ppEzw-0005Q9-K4 for submit@debbugs.gnu.org; Wed, 19 Apr 2023 17:05:52 -0400 Received: from mail-pj1-f44.google.com ([209.85.216.44]:44761) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ppEzv-0005Pw-Cf for 62955@debbugs.gnu.org; Wed, 19 Apr 2023 17:05:51 -0400 Received: by mail-pj1-f44.google.com with SMTP id z11-20020a17090abd8b00b0024721c47ceaso91360pjr.3 for <62955@debbugs.gnu.org>; Wed, 19 Apr 2023 14:05:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1681938345; x=1684530345; h=mime-version:message-id:date:to:from:from:to:cc:subject:date :message-id:reply-to; bh=IfrzWTFTgaQMpJi/55v+iyLfAWkBugaMGZgUNutuq1Y=; b=WhhgRlM9vrCw7IrKvJpQ0I780E6xk9I/sIBNmiMCRE/o8mIvfMZOW7153Bxas0Yn6x itSjo4ZAZVDIFO7AuvXuasF329tevbdhasxVluHAVLgfsjcXJU8VGgqJNuQWCplRlmhW LxxRWJ8qp564hnJftQ8PCZCPEz5SN5fVogsvcWRZweBDQpgyknmRY+gWJvP24+Uw3M+5 q+PH7m2QO7hISe1q1D9yFjpYxGXVKug6klW9t/xbIRzlKdJK9poP+KQC63F1rUvMTYA8 IoBJZV8bKEOgC+sFDaKFoRGZf960X7kA3szxivsFh6z4wEd0WUOdiL3C2WRtRlv8pW02 EwUw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681938345; x=1684530345; h=mime-version:message-id:date:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=IfrzWTFTgaQMpJi/55v+iyLfAWkBugaMGZgUNutuq1Y=; b=NBBpbUy9xL56hzWQAb5yJziU3vPcFbmY+9huIXZ5EmTWeJqDnBqYNpsXhjQeBLs6hJ xibUvkowrJvLB/n08F2JMc3B5ZxUwlKgYaOUB/2u1SUBmGhKyqq+Rt30HsCSdmX5g9+H qsRq0QbQHrlMEMU0t9+bhbqHwGJ5g8mscjIhlc4KHKcoH+PgiJ9YDdCvQ/+vNNuDC0ae XckyI/JDkGM3eidUFOkkFTZ5R4Dbr1cB2iqUe0ASi4iCEJ/ZWZ/xqSJd2j9z0UlGF1HV 7UW9xFP34cw5AGA9DFprz8cHQqU7HNRzoxz33fjPFGFaJRfRUiaqcq23IhHfyGYvQV3I ymRw== X-Gm-Message-State: AAQBX9cSgpvmNU2P8UCd14MyIyYGTHjHrqHkSTSFRdLxfTwHbM1/0i65 BpiTRavz8kiCREt1QNsBuXdyJhCPybU= X-Google-Smtp-Source: AKy350Ycwu1I6or+ZEuIAjAfGKGYabTlN6sBijkVrq6IGQ97Y9cM0yRrKVStGflinQRRf61NtBevMQ== X-Received: by 2002:a05:6a20:7d8e:b0:ef:53b5:fa01 with SMTP id v14-20020a056a207d8e00b000ef53b5fa01mr5720802pzj.49.1681938345216; Wed, 19 Apr 2023 14:05:45 -0700 (PDT) Received: from igor ([192.147.44.15]) by smtp.gmail.com with ESMTPSA id w11-20020a6556cb000000b00502e20b4777sm10788577pgs.9.2023.04.19.14.05.44 for <62955@debbugs.gnu.org> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 19 Apr 2023 14:05:44 -0700 (PDT) From: Zacchaeus Scheffer To: 62955@debbugs.gnu.org Date: Wed, 19 Apr 2023 14:05:44 -0700 Message-ID: <87wn27h9av.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 2.0 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: And just like that, i find there is already a discussion of some of this in 56050, though the fact that non-existant paths can be added by guix home to those variables is seems to be missing from that [...] Content analysis details: (2.0 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (zaccysc[at]gmail.com) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record 0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [209.85.216.44 listed in wl.mailspike.net] -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.216.44 listed in list.dnswl.org] 0.0 RCVD_IN_MSPIKE_WL Mailspike good senders 1.8 MISSING_SUBJECT Missing Subject: header 0.2 NO_SUBJECT Extra score for no subject X-Debbugs-Envelope-To: 62955 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 1.0 (+) And just like that, i find there is already a discussion of some of this in 56050, though the fact that non-existant paths can be added by guix home to those variables is seems to be missing from that discussion. Could someone merge the threads? (I assume I can't do that.) -Zacchae