Sean Whitton <spwhit...@spwhitton.name> writes:

> Hello,
>
> On Wed 16 Jul 2025 at 11:59am -07, Xiyue Deng wrote:
>
>> This makes the development easier so that I don't have to sbuild it
>> every time to test (which takes ~20min for me).  Also, running the
>> script needs a working emacs executable (I'm using `/usr/bin/emacs')
>> which is not available yet during build (or it can some built emacs
>> executable in some build-path, but I think it's a bit too fragile).
>
> That wouldn't be fragile, and it's what we should be doing.  We don't
> want to use /usr/bin/emacs.  We want to be sure we are using the latest
> information, from the thing we are building.
>
>> And I realize that because I removed the vendored lisp functions to get
>> the built-in package information, the script currently cannot work until
>> Emacs with the backported package.el is released.  So probably we should
>> upload -6 first (in experimental)?
>
> This would also be solved by using the Emacs that's part of the build.
>

Well the trial-and-error took a while due to build time (which was why I
preferred external emacs at first :P).

Now it uses the emacs-nox binary in the build tree to generate the
built-in package info.  I have some concerns about this as this now
depends on the upstream source code layout structure to find the built
emacs executable and it could break if that changes, though on the other
hand this layout change may not happen much in the foreseeable future ;)

As a side note, I also tried to use the emacs executable from the
install trees which I think the location should be stable, however the
`override_dh_auto_install' will cleanup the install trees at the
beginning as well as at the end, so the install trees are not available
outside of that build rule - which is probably by design.  Maybe in the
future we can open this up for customization like running this script
before clean up.

Anyway, my branch is now updated and the updated patches are attached.

> -- 
> Sean Whitton

-- 
Regards,
Xiyue Deng
From afaa5643e735be6df86559861b05855506ee362a Mon Sep 17 00:00:00 2001
From: Xiyue Deng <manp...@gmail.com>
Date: Wed, 25 Jun 2025 10:55:48 -0700
Subject: [PATCH 1/4] Generate debian/emacs-common-substvars

---
 debian/emacs-common-substvars | 81 +++++++++++++++++++++++++++++++++++
 1 file changed, 81 insertions(+)
 create mode 100644 debian/emacs-common-substvars

diff --git a/debian/emacs-common-substvars b/debian/emacs-common-substvars
new file mode 100644
index 00000000000..d8bc408d80c
--- /dev/null
+++ b/debian/emacs-common-substvars
@@ -0,0 +1,81 @@
+# Package name and version on each line in comments for tracking.
+#
+# elpa-allout (= 2.3),
+# elpa-allout-widgets (= 1.0),
+# elpa-ansi-color (= 3.4.2),
+# elpa-antlr-mode (= 2.2.3),
+# elpa-auth-source-pass (= 5.0.0),
+# elpa-backtrace (= 1.0),
+# elpa-bind-key (= 2.4.1),
+# elpa-cc-mode (= 5.33.1),
+# elpa-cedet (= 2.0),
+# elpa-cfengine (= 1.4),
+# elpa-cl-generic (= 1.0),
+# elpa-cl-lib (= 1.0),
+# elpa-cl-print (= 1.0),
+# elpa-compat (= 30.1.9999),
+# elpa-ede (= 2.0),
+# elpa-ediff (= 2.81.6),
+# elpa-editorconfig (= 0.11.0),
+# elpa-eglot (= 1.17.30),
+# elpa-eieio (= 1.4),
+# elpa-eieio-core (= 1.4),
+# elpa-eldoc (= 1.15.0),
+# elpa-epg (= 1.0.0),
+# elpa-erc (= 5.6.0.30.1),
+# elpa-eshell (= 2.4.2),
+# elpa-external-completion (= 0.1),
+# elpa-faceup (= 0.0.6),
+# elpa-feedmail (= 11),
+# elpa-find-cmd (= 0.6),
+# elpa-flymake (= 1.3.7),
+# elpa-flymake-proc (= 1.0),
+# elpa-foldout (= 1.10),
+# elpa-gnus (= 5.13),
+# elpa-idlwave (= 6.1.22),
+# elpa-image-dired (= 0.5),
+# elpa-info-xref (= 3),
+# elpa-isearchb (= 1.5),
+# elpa-js (= 9),
+# elpa-json (= 1.5),
+# elpa-jsonrpc (= 1.0.25),
+# elpa-let-alist (= 1.0.6),
+# elpa-map (= 3.3.1),
+# elpa-meta-mode (= 1.0),
+# elpa-mh-e (= 8.6~snapshot),
+# elpa-mixal-mode (= 0.4),
+# elpa-nadvice (= 1.0),
+# elpa-ntlm (= 2.1.0),
+# elpa-org (= 9.7.11),
+# elpa-package (= 1.1.0),
+# elpa-peg (= 1.0.1),
+# elpa-project (= 0.11.1),
+# elpa-ps-mode (= 1.1.9),
+# elpa-pulse (= 1.0),
+# elpa-python (= 0.28),
+# elpa-ruby-mode (= 1.2),
+# elpa-ruby-ts-mode (= 0.2),
+# elpa-semantic (= 2.2),
+# elpa-seq (= 2.24),
+# elpa-so-long (= 1.1.2),
+# elpa-soap-client (= 3.2.3),
+# elpa-sql (= 3.6),
+# elpa-srecode (= 1.2),
+# elpa-svg (= 1.1),
+# elpa-tabulated-list (= 1.0),
+# elpa-thunk (= 1.0),
+# elpa-tildify (= 4.6.1),
+# elpa-track-changes (= 1.2),
+# elpa-tramp (= 2.7.1.30.1),
+# elpa-transient (= 0.7.2.2),
+# elpa-use-package (= 2.4.6),
+# elpa-vera-mode (= 2.28),
+# elpa-verilog-mode (= 2024.3.1.121933719),
+# elpa-viper (= 3.14.2),
+# elpa-which-key (= 3.6.0),
+# elpa-whitespace (= 13.2.2),
+# elpa-window-tool-bar (= 0.2.1),
+# elpa-xref (= 1.7.0),
+emacs:Provides=elpa-allout (= 2.3), elpa-allout-widgets (= 1.0), elpa-ansi-color (= 3.4.2), elpa-antlr-mode (= 2.2.3), elpa-auth-source-pass (= 5.0.0), elpa-backtrace (= 1.0), elpa-bind-key (= 2.4.1), elpa-cc-mode (= 5.33.1), elpa-cedet (= 2.0), elpa-cfengine (= 1.4), elpa-cl-generic (= 1.0), elpa-cl-lib (= 1.0), elpa-cl-print (= 1.0), elpa-compat (= 30.1.9999), elpa-ede (= 2.0), elpa-ediff (= 2.81.6), elpa-editorconfig (= 0.11.0), elpa-eglot (= 1.17.30), elpa-eieio (= 1.4), elpa-eieio-core (= 1.4), elpa-eldoc (= 1.15.0), elpa-epg (= 1.0.0), elpa-erc (= 5.6.0.30.1), elpa-eshell (= 2.4.2), elpa-external-completion (= 0.1), elpa-faceup (= 0.0.6), elpa-feedmail (= 11), elpa-find-cmd (= 0.6), elpa-flymake (= 1.3.7), elpa-flymake-proc (= 1.0), elpa-foldout (= 1.10), elpa-gnus (= 5.13), elpa-idlwave (= 6.1.22), elpa-image-dired (= 0.5), elpa-info-xref (= 3), elpa-isearchb (= 1.5), elpa-js (= 9), elpa-json (= 1.5), elpa-jsonrpc (= 1.0.25), elpa-let-alist (= 1.0.6), elpa-map (= 3.3.1), elpa-meta-mode (= 1.0), elpa-mh-e (= 8.6~snapshot), elpa-mixal-mode (= 0.4), elpa-nadvice (= 1.0), elpa-ntlm (= 2.1.0), elpa-org (= 9.7.11), elpa-package (= 1.1.0), elpa-peg (= 1.0.1), elpa-project (= 0.11.1), elpa-ps-mode (= 1.1.9), elpa-pulse (= 1.0), elpa-python (= 0.28), elpa-ruby-mode (= 1.2), elpa-ruby-ts-mode (= 0.2), elpa-semantic (= 2.2), elpa-seq (= 2.24), elpa-so-long (= 1.1.2), elpa-soap-client (= 3.2.3), elpa-sql (= 3.6), elpa-srecode (= 1.2), elpa-svg (= 1.1), elpa-tabulated-list (= 1.0), elpa-thunk (= 1.0), elpa-tildify (= 4.6.1), elpa-track-changes (= 1.2), elpa-tramp (= 2.7.1.30.1), elpa-transient (= 0.7.2.2), elpa-use-package (= 2.4.6), elpa-vera-mode (= 2.28), elpa-verilog-mode (= 2024.3.1.121933719), elpa-viper (= 3.14.2), elpa-which-key (= 3.6.0), elpa-whitespace (= 13.2.2), elpa-window-tool-bar (= 0.2.1), elpa-xref (= 1.7.0),
+emacs:Breaks=elpa-allout (<< 2.3), elpa-allout-widgets (<< 1.0), elpa-ansi-color (<< 3.4.2), elpa-antlr-mode (<< 2.2.3), elpa-auth-source-pass (<< 5.0.0), elpa-backtrace (<< 1.0), elpa-bind-key (<< 2.4.1), elpa-cc-mode (<< 5.33.1), elpa-cedet (<< 2.0), elpa-cfengine (<< 1.4), elpa-cl-generic (<< 1.0), elpa-cl-lib (<< 1.0), elpa-cl-print (<< 1.0), elpa-compat (<< 30.1.9999), elpa-ede (<< 2.0), elpa-ediff (<< 2.81.6), elpa-editorconfig (<< 0.11.0), elpa-eglot (<< 1.17.30), elpa-eieio (<< 1.4), elpa-eieio-core (<< 1.4), elpa-eldoc (<< 1.15.0), elpa-epg (<< 1.0.0), elpa-erc (<< 5.6.0.30.1), elpa-eshell (<< 2.4.2), elpa-external-completion (<< 0.1), elpa-faceup (<< 0.0.6), elpa-feedmail (<< 11), elpa-find-cmd (<< 0.6), elpa-flymake (<< 1.3.7), elpa-flymake-proc (<< 1.0), elpa-foldout (<< 1.10), elpa-gnus (<< 5.13), elpa-idlwave (<< 6.1.22), elpa-image-dired (<< 0.5), elpa-info-xref (<< 3), elpa-isearchb (<< 1.5), elpa-js (<< 9), elpa-json (<< 1.5), elpa-jsonrpc (<< 1.0.25), elpa-let-alist (<< 1.0.6), elpa-map (<< 3.3.1), elpa-meta-mode (<< 1.0), elpa-mh-e (<< 8.6~snapshot), elpa-mixal-mode (<< 0.4), elpa-nadvice (<< 1.0), elpa-ntlm (<< 2.1.0), elpa-org (<< 9.7.11), elpa-package (<< 1.1.0), elpa-peg (<< 1.0.1), elpa-project (<< 0.11.1), elpa-ps-mode (<< 1.1.9), elpa-pulse (<< 1.0), elpa-python (<< 0.28), elpa-ruby-mode (<< 1.2), elpa-ruby-ts-mode (<< 0.2), elpa-semantic (<< 2.2), elpa-seq (<< 2.24), elpa-so-long (<< 1.1.2), elpa-soap-client (<< 3.2.3), elpa-sql (<< 3.6), elpa-srecode (<< 1.2), elpa-svg (<< 1.1), elpa-tabulated-list (<< 1.0), elpa-thunk (<< 1.0), elpa-tildify (<< 4.6.1), elpa-track-changes (<< 1.2), elpa-tramp (<< 2.7.1.30.1), elpa-transient (<< 0.7.2.2), elpa-use-package (<< 2.4.6), elpa-vera-mode (<< 2.28), elpa-verilog-mode (<< 2024.3.1.121933719), elpa-viper (<< 3.14.2), elpa-which-key (<< 3.6.0), elpa-whitespace (<< 13.2.2), elpa-window-tool-bar (<< 0.2.1), elpa-xref (<< 1.7.0),
+emacs:Replaces=elpa-allout (<< 2.3), elpa-allout-widgets (<< 1.0), elpa-ansi-color (<< 3.4.2), elpa-antlr-mode (<< 2.2.3), elpa-auth-source-pass (<< 5.0.0), elpa-backtrace (<< 1.0), elpa-bind-key (<< 2.4.1), elpa-cc-mode (<< 5.33.1), elpa-cedet (<< 2.0), elpa-cfengine (<< 1.4), elpa-cl-generic (<< 1.0), elpa-cl-lib (<< 1.0), elpa-cl-print (<< 1.0), elpa-compat (<< 30.1.9999), elpa-ede (<< 2.0), elpa-ediff (<< 2.81.6), elpa-editorconfig (<< 0.11.0), elpa-eglot (<< 1.17.30), elpa-eieio (<< 1.4), elpa-eieio-core (<< 1.4), elpa-eldoc (<< 1.15.0), elpa-epg (<< 1.0.0), elpa-erc (<< 5.6.0.30.1), elpa-eshell (<< 2.4.2), elpa-external-completion (<< 0.1), elpa-faceup (<< 0.0.6), elpa-feedmail (<< 11), elpa-find-cmd (<< 0.6), elpa-flymake (<< 1.3.7), elpa-flymake-proc (<< 1.0), elpa-foldout (<< 1.10), elpa-gnus (<< 5.13), elpa-idlwave (<< 6.1.22), elpa-image-dired (<< 0.5), elpa-info-xref (<< 3), elpa-isearchb (<< 1.5), elpa-js (<< 9), elpa-json (<< 1.5), elpa-jsonrpc (<< 1.0.25), elpa-let-alist (<< 1.0.6), elpa-map (<< 3.3.1), elpa-meta-mode (<< 1.0), elpa-mh-e (<< 8.6~snapshot), elpa-mixal-mode (<< 0.4), elpa-nadvice (<< 1.0), elpa-ntlm (<< 2.1.0), elpa-org (<< 9.7.11), elpa-package (<< 1.1.0), elpa-peg (<< 1.0.1), elpa-project (<< 0.11.1), elpa-ps-mode (<< 1.1.9), elpa-pulse (<< 1.0), elpa-python (<< 0.28), elpa-ruby-mode (<< 1.2), elpa-ruby-ts-mode (<< 0.2), elpa-semantic (<< 2.2), elpa-seq (<< 2.24), elpa-so-long (<< 1.1.2), elpa-soap-client (<< 3.2.3), elpa-sql (<< 3.6), elpa-srecode (<< 1.2), elpa-svg (<< 1.1), elpa-tabulated-list (<< 1.0), elpa-thunk (<< 1.0), elpa-tildify (<< 4.6.1), elpa-track-changes (<< 1.2), elpa-tramp (<< 2.7.1.30.1), elpa-transient (<< 0.7.2.2), elpa-use-package (<< 2.4.6), elpa-vera-mode (<< 2.28), elpa-verilog-mode (<< 2024.3.1.121933719), elpa-viper (<< 3.14.2), elpa-which-key (<< 3.6.0), elpa-whitespace (<< 13.2.2), elpa-window-tool-bar (<< 0.2.1), elpa-xref (<< 1.7.0),
-- 
2.50.0

From fb40b35102e5147df733f44e7f1f34930d04c7d1 Mon Sep 17 00:00:00 2001
From: Xiyue Deng <manp...@gmail.com>
Date: Tue, 15 Jul 2025 15:50:22 -0700
Subject: [PATCH 2/4] Add substvars to emacs-common in debian/control

---
 debian/control | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/debian/control b/debian/control
index 86cd8976b46..2a1364ffd54 100644
--- a/debian/control
+++ b/debian/control
@@ -191,8 +191,12 @@ Breaks:
  emacs-gtk (<< 1:25),
  emacs-lucid (<< 1:25),
  emacs-nox (<< 1:25),
+ ${emacs:Breaks}
 Replaces:
- emacs-bin-common (<< 1:28)
+ emacs-bin-common (<< 1:28),
+ ${emacs:Replaces}
+Provides:
+ ${emacs:Provides}
 Description: GNU Emacs editor's shared, architecture independent infrastructure
  GNU Emacs is the extensible self-documenting text editor.
  This package contains the architecture independent infrastructure
-- 
2.50.0

From 2ff1a91178ea8d429c5c46c367411b1f3bb12695 Mon Sep 17 00:00:00 2001
From: Xiyue Deng <manp...@gmail.com>
Date: Wed, 25 Jun 2025 14:04:49 -0700
Subject: [PATCH 3/4] Build using GCC 12 from Bookworm

---
 debian/control | 4 ++--
 debian/rules   | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/debian/control b/debian/control
index 2a1364ffd54..ddfa1cae0ea 100644
--- a/debian/control
+++ b/debian/control
@@ -9,7 +9,7 @@ Build-Depends:
  bsd-mailx | mailx,
  ca-certificates,
  dbus-x11,
- gcc-14,
+ gcc-12,
  debhelper-compat (= 13),
  dpkg-dev (>> 1.10.0),
  git,
@@ -19,7 +19,7 @@ Build-Depends:
  libasound2-dev [!hurd-i386 !kfreebsd-i386 !kfreebsd-amd64],
  libcairo-dev,
  libdbus-1-dev,
- libgccjit-14-dev,
+ libgccjit-12-dev,
  libgif-dev,
  libgmp-dev,
  libgnutls28-dev,
diff --git a/debian/rules b/debian/rules
index d7b121609ab..35d3849afdf 100755
--- a/debian/rules
+++ b/debian/rules
@@ -325,7 +325,7 @@ confflags_lucid += --without-gsettings
 define cfg_tree
   cd $(1) && \
     CFLAGS="$(CFLAGS)" CPPFLAGS="$(CPPFLAGS)" LDFLAGS="$(LDFLAGS)" \
-    CC=gcc-14 \
+    CC=gcc-12 \
     REL_ALLOC=no \
       $(CURDIR)/debian/build-src/configure $(confflags) $(2)
 endef
-- 
2.50.0

From 9c92f2fc94a7495c614a3b6b85eb0f2b11bc7067 Mon Sep 17 00:00:00 2001
From: Xiyue Deng <manp...@gmail.com>
Date: Wed, 25 Jun 2025 13:23:50 -0700
Subject: [PATCH 4/4] Backport to bookworm

---
 debian/changelog | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index 8ac59267ed0..969284a613d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+emacs (1:30.1+1-6~1.gbpa971e1~bpo12+0manphiz1) UNRELEASED; urgency=medium
+
+  * Backport to Bookworm.
+  * Test substvars
+
+ -- Xiyue Deng <manp...@gmail.com>  Tue, 15 Jul 2025 11:36:24 -0700
+
 emacs (1:30.1+1-6~1.gbpa971e1) UNRELEASED; urgency=medium
 
   ** SNAPSHOT build @a971e1d025da05b8e8a8e8024a8354bc06159e3a **
-- 
2.50.0

Attachment: signature.asc
Description: PGP signature

Reply via email to