Your message dated Tue, 9 Jun 2026 16:40:18 +0200
with message-id <[email protected]>
and subject line Re: Bug#1055263: dh-golang:  Go env vars are not needed for 
override_* processing.
has caused the Debian Bug report #1055263,
regarding dh-golang:  Go env vars are not needed for override_* processing.
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
1055263: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1055263
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: dh-golang
Version: 1.62
Severity: normal
Tags: patch
X-Debbugs-Cc: [email protected]

Dear Maintainer,

 I have investigated the bug report #1049392 and I have discovered the
cause of the problem. It seems that when the dh-golang package is
installed, it appends some unnecessary Go environment variables that
affect the whole dh command. This happens because the dh-golang plugin
modifies the environment variables for Go when it is invoked by the dh
command to check the suitability of the build system. This also affects
the processing of override_* statements in debian/rules incorrectly.

 I think this behavior is likely incorrect and inconsistent with the
plugin policy of dh, as other dh plugins do not alter the environment
variables of the dh command when just checking the build system. The
environment variables should be modified by the commands that are
directly invoked by dh, not for the override_* statements processed by
dh.

 To fix this issue, I have prepared a patch that changes the behavior
of the dh-golang plugin. The patch is suggested below.

https://salsa.debian.org/go-team/packages/dh-golang/-/merge_requests/21

 Please consider applying this patch and let me know if you have any
comments or questions.

 Thank you for your time and consideration.

Takahide Nojima.


-- System Information:
Debian Release: trixie/sid
  APT prefers unstable-debug
  APT policy: (500, 'unstable-debug'), (500, 'testing-debug'), (500,
'unstable'), (500, 'testing')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 6.5.0-3-amd64 (SMP w/8 CPU threads; PREEMPT)
Locale: LANG=ja_JP.UTF-8, LC_CTYPE=ja_JP.UTF-8 (charmap=UTF-8),
LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages dh-golang depends on:
ii  debhelper     13.11.7
ii  libdpkg-perl  1.22.1
ii  perl          5.36.0-9

dh-golang recommends no packages.

dh-golang suggests no packages.

-- no debconf information

--- End Message ---
--- Begin Message ---
Hi!

On Fri, 2023-11-03 at 16:32:30 +0900, Takahide Nojima wrote:
> Package: dh-golang
> Version: 1.62
> Severity: normal
> Tags: patch
> X-Debbugs-Cc: [email protected]

>  I have investigated the bug report #1049392 and I have discovered the
> cause of the problem. It seems that when the dh-golang package is
> installed, it appends some unnecessary Go environment variables that
> affect the whole dh command. This happens because the dh-golang plugin
> modifies the environment variables for Go when it is invoked by the dh
> command to check the suitability of the build system. This also affects
> the processing of override_* statements in debian/rules incorrectly.
> 
>  I think this behavior is likely incorrect and inconsistent with the
> plugin policy of dh, as other dh plugins do not alter the environment
> variables of the dh command when just checking the build system. The
> environment variables should be modified by the commands that are
> directly invoked by dh, not for the override_* statements processed by
> dh.
> 
>  To fix this issue, I have prepared a patch that changes the behavior
> of the dh-golang plugin. The patch is suggested below.
> 
> https://salsa.debian.org/go-team/packages/dh-golang/-/merge_requests/21
> 
>  Please consider applying this patch and let me know if you have any
> comments or questions.

Quoting what I mentioned on the MR:

,---
Thanks for the patch! Although I'm not convinced this is the right
approach. For golang packages we want to make sure we are using a
consistent build environment whether we call go commands via debhelper,
or directly. For other debhelper buildsystems these global settings
get persisted because they have sticky configure processes that record
similar settings (autotools, cmake, ninja, etc), or by creating a config
file for this build (python_distutils f.ex.).

I think that if some packages fails to build due to those flags, then
whether that was caused by dh-golang being installed or not does not
seem relevant, because the user might have those environment variables
set in their environment, which would indicate that the packaging is not
robust against such external definitions.

Besides the potential build failures, I think this would remove the
consistency in the build environment, and would make some cases trickier
to handle, as you'd need to then set those variables for the targets this
would no longer apply, which is going to be rather cumbersome. Unsetting
them is always going to be easier for example.

So IMO we should close this one.
`---

And doing that now. If someone else on the team disagrees, please reopen
and provide a rationale.

Thanks,
Guillem

--- End Message ---

Reply via email to