From unknown Sat Jun 21 03:30:56 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#63716 <63716@debbugs.gnu.org> To: bug#63716 <63716@debbugs.gnu.org> Subject: Status: 30.0.50; Unable to install external packages with Nix after recent native-compilation changes Reply-To: bug#63716 <63716@debbugs.gnu.org> Date: Sat, 21 Jun 2025 10:30:56 +0000 retitle 63716 30.0.50; Unable to install external packages with Nix after r= ecent native-compilation changes reassign 63716 emacs submitter 63716 Brian Leung severity 63716 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Thu May 25 07:47:45 2023 Received: (at submit) by debbugs.gnu.org; 25 May 2023 11:47:45 +0000 Received: from localhost ([127.0.0.1]:46169 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q29RY-0003SP-On for submit@debbugs.gnu.org; Thu, 25 May 2023 07:47:45 -0400 Received: from lists.gnu.org ([209.51.188.17]:54498) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q29RW-0003S5-Iw for submit@debbugs.gnu.org; Thu, 25 May 2023 07:47:43 -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 1q29RQ-0006pj-L7 for bug-gnu-emacs@gnu.org; Thu, 25 May 2023 07:47:41 -0400 Received: from mout01.posteo.de ([185.67.36.65]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q29RO-0004o3-C9 for bug-gnu-emacs@gnu.org; Thu, 25 May 2023 07:47:36 -0400 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id A39FE240028 for ; Thu, 25 May 2023 13:47:30 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1685015250; bh=aWmUkUeb5Vn07G4GJi3ah6NlcVoJeBbnivxMy+PARL8=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:From; b=ZoKtib6X9t++O258bLIudrcNuUhHL7oarHA1euzNiJ3FSyVUdZOMAQk1EzBH4I+so gLeitf4bXRjbbNJPAE1igW6GDelNwUbSDpDeYAnzfxgzUhMY3MjMg134he0Uy83aMx YaMpTWBF9//Y/dpJSH5UFrVh1bhUhMGwF7GG8ur2fzYuPDQnjOfFfDYmNo3O044K7n rvCN2XKMM0UbBXAcHAWlnIGH6+uD+FrNz81zes3zy+Iiy7io/5HuYvIDB7qg5ErUY0 cKXOB3rJu+5BqYnAOOuq1saQZObb48K29G3kY4HYzMjeRsWNu47sgAjZllmhnb6uc7 Wtm+x1vWZtwew== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4QRmWP3Rw0z9rxV; Thu, 25 May 2023 13:47:29 +0200 (CEST) From: Brian Leung To: bug-gnu-emacs@gnu.org Subject: 30.0.50; Unable to install external packages with Nix after recent native-compilation changes Date: Thu, 25 May 2023 11:12:58 +0000 Message-ID: <878rdcab04.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain; format=flowed Received-SPF: pass client-ip=185.67.36.65; envelope-from=leungbk@posteo.net; helo=mout01.posteo.de X-Spam_score_int: -33 X-Spam_score: -3.4 X-Spam_bar: --- X-Spam_report: (-3.4 / 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, HEXHASH_WORD=1, RCVD_IN_DNSWL_MED=-2.3, 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 Cc: Andrea Corallo 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 (--) Starting with the recent batch of native-comp commits ending with and including Emacs commit b2b2be98da5825e6bc130999ffe38f5ed615586a, using the Nix package manager I cannot install an Emacs containing natively-compiled external packages. (I have no problems on Emacs commit f4de81af8fc54ef278cdb76fbc5885ed7d05b2d7, which is the commit immediately preceding the first of the recent native-comp commits) Building core Emacs (with native compilation) is successful, but I encounter problems upon running (https://github.com/nixos/nixpkgs/blob/8fbdc4e6114795323ad2b74d13e1c842c5618b78/pkgs/build-support/emacs/melpa.nix#L99-L102): > emacs --batch -Q \ > -l "$elpa2nix" \ > -f elpa2nix-install-package \ > "$archive" "$out/share/emacs/site-lisp/elpa" This fails when trying to run package-tar-file-info (https://github.com/nixos/nixpkgs/blob/8fbdc4e6114795323ad2b74d13e1c842c5618b78/pkgs/build-support/emacs/elpa2nix.el#L14-L15). The full backtrace is here: > Error: error ("Can't find define-package in > vterm-20230417.424/vterm-pkg.el") > mapbacktrace(#f(compiled-function (evald func args flags) > #)) > debug-early-backtrace() > debug-early(error (error "Can't find define-package in > vterm-20230417.424/vterm-pkg.el")) > error("Can't find define-package in %s" > "vterm-20230417.424/vterm-pkg.el") > package-tar-file-info() > (if (derived-mode-p 'tar-mode) (package-tar-file-info) > (package-buffer-info)) > (let ((pkg-desc (if (derived-mode-p 'tar-mode) > (package-tar-file-info) (package-buffer-info)))) > (package-unpack pkg-desc) pkg-desc) > elpa2nix-install-from-buffer() > (progn (if is-tar (insert-file-contents-literally file) > (insert-file-contents file)) (if is-tar (progn (tar-mode))) > (elpa2nix-install-from-buffer)) > (unwind-protect (progn (if is-tar > (insert-file-contents-literally file) (insert-file-contents > file)) (if is-tar (progn (tar-mode))) > (elpa2nix-install-from-buffer)) (and (buffer-name > temp-buffer) (kill-buffer temp-buffer))) > (save-current-buffer (set-buffer temp-buffer) (unwind-protect > (progn (if is-tar (insert-file-contents-literally file) > (insert-file-contents file)) (if is-tar (progn (tar-mode))) > (elpa2nix-install-from-buffer)) (and (buffer-name > temp-buffer) (kill-buffer temp-buffer)))) > (let ((temp-buffer (generate-new-buffer " *temp*" t))) > (save-current-buffer (set-buffer temp-buffer) (unwind-protect > (progn (if is-tar (insert-file-contents-literally file) > (insert-file-contents file)) (if is-tar (progn (tar-mode))) > (elpa2nix-install-from-buffer)) (and (buffer-name > temp-buffer) (kill-buffer temp-buffer))))) > (let ((is-tar (string-match "\\.tar\\'" file))) (let > ((temp-buffer (generate-new-buffer " *temp*" t))) > (save-current-buffer (set-buffer temp-buffer) (unwind-protect > (progn (if is-tar (insert-file-contents-literally file) > (insert-file-contents file)) (if is-tar (progn (tar-mode))) > (elpa2nix-install-from-buffer)) (and (buffer-name > temp-buffer) (kill-buffer temp-buffer)))))) > elpa2nix-install-file("/build/packages/vterm-20230417.424.tar") > (progn (setq package-user-dir elpa) (elpa2nix-install-file > archive)) > (let ((archive x0) (elpa x2)) (progn (setq package-user-dir > elpa) (elpa2nix-install-file archive))) > (if (null x3) (let ((archive x0) (elpa x2)) (progn (setq > package-user-dir elpa) (elpa2nix-install-file archive)))) > (let* ((x2 (car-safe x1)) (x3 (cdr-safe x1))) (if (null x3) > (let ((archive x0) (elpa x2)) (progn (setq package-user-dir > elpa) (elpa2nix-install-file archive))))) > (if (consp x1) (let* ((x2 (car-safe x1)) (x3 (cdr-safe x1))) > (if (null x3) (let ((archive x0) (elpa x2)) (progn (setq > package-user-dir elpa) (elpa2nix-install-file archive)))))) > (let* ((x0 (car-safe command-line-args-left)) (x1 (cdr-safe > command-line-args-left))) (if (consp x1) (let* ((x2 (car-safe > x1)) (x3 (cdr-safe x1))) (if (null x3) (let ((archive x0) > (elpa x2)) (progn (setq package-user-dir elpa) > (elpa2nix-install-file archive))))))) > (if (consp command-line-args-left) (let* ((x0 (car-safe > command-line-args-left)) (x1 (cdr-safe > command-line-args-left))) (if (consp x1) (let* ((x2 (car-safe > x1)) (x3 (cdr-safe x1))) (if (null x3) (let ((archive x0) > (elpa x2)) (progn (setq package-user-dir elpa) > (elpa2nix-install-file archive)))))))) > elpa2nix-install-package() > command-line-1(("-l" > "/nix/store/4jj63z4v1xp13rh2md053dccq920hd45-elpa2nix.el" > "-f" "elpa2nix-install-package" > "/build/packages/vterm-20230417.424.tar" > "/nix/store/rf3rsbn6sa1l5v8pbsk02g0nrm5a7pnr-emacs-vterm-20230417.424/share/emacs/site-lisp/elpa")) > command-line() > normal-top-level() I do not encounter any problems if I do not native-compile, or if I use an earlier commit as I mentioned. Unlike the possibly-related and unresolved bug#63288, the error I am now getting appears to be consistently reproducible when I revert ea9831bb3cb4878273f6f848051c9b8c3c76d5f1, which in a Nix sandbox would non-deterministically cause external packages to fail during native compilation. I have also noticed the same error occurring when I leave ea9831bb3cb4878273f6f848051c9b8c3c76d5f1 unreverted, though I haven't tested this latter scenario often enough to be sure that ea9831bb3cb4878273f6f848051c9b8c3c76d5f1 has no impact since I was worried that the non-determinism would complicate things. CCing Andrea Corallo. From debbugs-submit-bounces@debbugs.gnu.org Sat May 27 02:37:24 2023 Received: (at control) by debbugs.gnu.org; 27 May 2023 06:37:24 +0000 Received: from localhost ([127.0.0.1]:51284 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q2nYJ-0000Xp-KP for submit@debbugs.gnu.org; Sat, 27 May 2023 02:37:24 -0400 Received: from eggs.gnu.org ([209.51.188.92]:36644) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q2nYH-0000XW-2A; Sat, 27 May 2023 02:37:21 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q2nYA-0000h4-8K; Sat, 27 May 2023 02:37:14 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=C4im0cbbWcJrI4wuwfCBRS0l2KHDUqXbbuWxUzD/1Tg=; b=q1R3lCX/RJxB480SXqN6 f15L2p57QCVfCeUdMAfgrAVvy276rSGH02pRyIgkei5hZIZ91PYOCRiG/eRx7XQnaDeJ3Ml9Fge3D F7A+nGPPZrRJcP+0PTTPpMm6vO7AYev6Xa3GWWOSN9nZjC0sJ2hE42tnuVPVDLYeHYL9ayke6/egD 7MHLe0XX4w1TNs0Lb6muVWEMXTdw3wqS2tgDA/GzIWHvdC4Gq1nvHJVSlrrvSjByMSPBw7bic9cgj aiGntlZ/c+d4nUQrt1MeXk4wotHpKK0JbvapnynuKaKWFBKYHvGWRNYwIxWpk+ODOFZAp73+sHpbM dgc8E3Z1+Cg5zw==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q2nY9-0001zC-Lv; Sat, 27 May 2023 02:37:14 -0400 Date: Sat, 27 May 2023 09:37:47 +0300 Message-Id: <83bki6jn44.fsf@gnu.org> From: Eli Zaretskii To: Ruijie Yu , Andrea Corallo In-Reply-To: (bug-gnu-emacs@gnu.org) Subject: Re: bug#63742: 30.0.50; [BUG] package.el having a hard time References: MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control Cc: 63742@debbugs.gnu.org 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: -3.3 (---) merge 63742 63679 63716 63710 thanks > Date: Sat, 27 May 2023 11:10:24 +0800 > From: Ruijie Yu via "Bug reports for GNU Emacs, > the Swiss army knife of text editors" > > I have recompiled Emacs master yesterday, but this build has had a hard > time processing my init.el file (saying that PKG-pkg.el files are not > found, where they indeed are). I wasn't able to reproduce this exact > problem, but upon digging further, I found one issue which I can > reproduce it reliably in -Q environment, and which is probably related > to the other unreproducible issue. > > $ cd $(mktemp -d) > $ HOME=$PWD XDG_CONFIG_HOME=$HOME/.config emacs -Q > M-x package-initialize RET > M-x list-packages RET > ;; And wait for it to finish listing packages from gnu and nongnu > > / n xr RET > ;; find some package to install, any package suffices > i x SPC > ;; Install it > > Observe the error message shown in the minibuffer. The following is the > full message from trying to install the package. > > --8<---------------cut here---------------start------------->8--- > Packages to install: 1 (xr-1.23). Proceed? (y or n) y > Operation [ Install 1 ] started > Setting ‘package-selected-packages’ temporarily since "emacs -q" would overwrite customizations > Contacting host: elpa.gnu.org:443 [2 times] > Parsing tar file...done > Extracting...done > INFO Scraping files for loaddefs...done > GEN xr-autoloads.el > package-unpack: Wrong type argument: package-desc, nil > --8<---------------cut here---------------end--------------->8--- Does the problem go away if you rebuild without native-compilation? If yes, this is a known problem (bug#63679), and Andrea (CC'ed) is aware of that, I think. From debbugs-submit-bounces@debbugs.gnu.org Sun May 28 13:45:52 2023 Received: (at control) by debbugs.gnu.org; 28 May 2023 17:45:52 +0000 Received: from localhost ([127.0.0.1]:54628 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q3KSk-0000PM-GX for submit@debbugs.gnu.org; Sun, 28 May 2023 13:45:52 -0400 Received: from eggs.gnu.org ([209.51.188.92]:35068) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q3GOW-0001oz-6S for control@debbugs.gnu.org; Sun, 28 May 2023 09:25:12 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q3GOQ-0000fy-OB for control@debbugs.gnu.org; Sun, 28 May 2023 09:25:06 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:Subject:To:From:in-reply-to: references; bh=q0hJ/wyzt5OQ5sqFoP4e5+iLTjVjin3fw3avmA9MkMU=; b=lxbuTmDnBToRs0 z4QeIIiUHWyyDlOoZDI+faFfvEhodgs3jRaf2pAAJ+R1KbcvJrn+xAuvIuBBcv4NnZJbAJFtaZFUp h3kRarUquuGNDaFL+MWXpWnZzCdLfF8xICllivqd1Ex5OaHgzlksPpNn3n34kbNWqGciqdoY5k+Zp QFyYle9mAo3AD7UjRchpkUPOUGizM5f7vkUbraBK2dPFz6ZvBhbC3bl1+Hv15t03nsWCC/D6uZPgV 3/s4Ylk8eVxXJjycvLQk286amW59CR91I6rRvXfd2be/zSlRuDDki7x5jdC0wVmm2iI76HdjpwR1l l05qnSlyUrLbN+C5fQFg==; Received: from acorallo by fencepost.gnu.org with local (Exim 4.90_1) (envelope-from ) id 1q3GOH-00026C-3T for control@debbugs.gnu.org; Sun, 28 May 2023 09:25:06 -0400 From: Andrea Corallo To: control@debbugs.gnu.org Subject: control message for bug #63674 Date: Sun, 28 May 2023 09:24:57 -0400 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-Mailman-Approved-At: Sun, 28 May 2023 13:45:49 -0400 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: -3.3 (---) merge 63710 63742 quit From unknown Sat Jun 21 03:30:56 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Tue, 04 Jul 2023 11:24:05 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator