On Tue, 12 Nov 2024 17:22:12 +0800 Bo YU <tsu.y...@gmail.com> wrote:
> > xxkb (1.11.1-3) unstable; urgency=medium
> > .
> >   * QA upload.
> >   * Add 0004-fix-ftbfs-on-gcc-14.patch to fix the ftbfs issue.
> >     (Closes: #1075694)
> >   * Set std-ver to 4.7.0.
> >   * Add Rules-Requires-Root on d/control.
> >   * Add doc-base for xxkb.
> >   * debian/rules: clean up Makefile explicitly.
> >   * debian/rules: update CDEBUGFLAGS to fix hardening issue.
>
> Oops, I forget the debdiff about this, sorry for that.
>

    $(MAKE) CDEBUGFLAGS="$(CFLAGS) $(LDFLAGS) $(CDEBUGFLAGS)"
will override the options in Imakefile: -Wall is missing.
I don't think that it is a good idea.

Maybe this patch is what we expect:
diff --git a/debian/patches/0003-Imakefile-enable-debug-flag.patch
b/debian/patches/0003-Imakefile-enable-debug-flag.patch
index e4909f6..319a0d9 100644
--- a/debian/patches/0003-Imakefile-enable-debug-flag.patch
+++ b/debian/patches/0003-Imakefile-enable-debug-flag.patch
@@ -15,7 +15,7 @@ index 931ca42..36010b8 100644
  #endif

 -CDEBUGFLAGS = -O2 -Wall
-+CDEBUGFLAGS = -O2 -Wall -g
++CDEBUGFLAGS = -O2 -Wall -g $(DEB_CDEBUGFLAGS)
  SED = sed

  ComplexProgramTarget(xxkb)
diff --git a/debian/rules b/debian/rules
index abfa617..1fd37ca 100755
--- a/debian/rules
+++ b/debian/rules
@@ -15,7 +15,7 @@ execute_after_dh_auto_clean:

 override_dh_auto_build:
        xmkmf
-       $(MAKE) CDEBUGFLAGS="$(CFLAGS) $(LDFLAGS) $(CDEBUGFLAGS)"
+       $(MAKE) DEB_CDEBUGFLAGS="$(CFLAGS) $(LDFLAGS)"

 override_dh_auto_install:
        $(MAKE) install install.man DESTDIR=$(CURDIR)/debian/tmp/

Reply via email to