Bug#1025171: [Pkg-zfsonlinux-devel] Bug#1025171: zfs-dkms FTBFS against 6.0.0-5-amd64

2022-12-01 Thread M. Zhou
Control: reassign -1 dkms 3.0.8-2
Control: retitle -1 regression: dkms/3.0.8-2 renders zfs-dkms FTBFS
Control: severity -1 serious

Hi,

Thank you for the information! I can confirm that this is the same issue
that you have encountered. By commenting out the --environment-overrides,
the current zfs-dkms package can be built against 6.0.0-5-amd64 successfully.

According to the build log when I filed the bug report, the problem is indeed
that the compiler cannot find the header files. I believed it was some -I ...
flags missing due to some reason.

So it is a regression bug in dkms/3.0.8-2, as -I flags needed for zfs-dkms
are accidentally removed.

On Wed, 2022-11-30 at 22:56 +, Heikki Kallasjoki wrote:
> There isn't enough detail to be sure, but this might be the same issue I
> hit on sid yesterday, so adding it here. It might also count as a dkms
> bug for all I know.
> 
> In my case, zfs-dkms fails to build against either of my currently
> installed kernels (5.19.0-1-amd64, 6.0.0-5-amd64), but only after
> updating the package dkms to version 3.0.8-2 (from 3.0.8-1).
> 
> This appears to be the result of the changes to the export-CC.patch:
> https://sources.debian.org/patches/dkms/3.0.8-2/export-CC.patch/
> 
> The 3.0.8-2 version adds the following commands to the prepare_build()
> function:
> 
> export CC=$CC
> export MAKEFLAGS="--environment-overrides"
> 
> I've verified that zfs-dkms builds fine for me if I temporarily comment
> out the second line from /usr/sbin/dkms.
> 
> A build log for a failed attempt (with the flag present) is at:
> https://0x0.st/o0fu.txt
> 
> The log also includes a dump of the environment variables at the start
> of the build, from a command I added to the dkms script.
> 
> Digging a little deeper, it appears that when `--environment-overrides`
> is set, a number of required command-line options (in particular, an -I
> option to add /var/lib/dkms/zfs/2.1.6/build/include in the include
> search path) fail to be set. I didn't manage to trace why exactly that
> is, but you can see both a failing and a working example (for one object
> file) at:
> https://0x0.st/o0EC.txt
> 
> FWIW, it seems like the build environment dkms uses inherits whatever
> was present in the environment when apt was called. If this is the case,
> then it feels to me including the `--environment-overrides` flag has
> potential to make things brittle. The effect of the flag is to: "Give
> variables taken from the environment precedence over variables from
> makefiles." Any arbitrary environment variables the user may have set
> for their own purposes might be unexpectedly overriding important
> variables from the Makefile(s).
> 
> ___
> Pkg-zfsonlinux-devel mailing list
> pkg-zfsonlinux-de...@alioth-lists.debian.net
> https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/pkg-zfsonlinux-devel



Bug#1025171: zfs-dkms FTBFS against 6.0.0-5-amd64

2022-11-30 Thread Heikki Kallasjoki
There isn't enough detail to be sure, but this might be the same issue I
hit on sid yesterday, so adding it here. It might also count as a dkms
bug for all I know.

In my case, zfs-dkms fails to build against either of my currently
installed kernels (5.19.0-1-amd64, 6.0.0-5-amd64), but only after
updating the package dkms to version 3.0.8-2 (from 3.0.8-1).

This appears to be the result of the changes to the export-CC.patch:
https://sources.debian.org/patches/dkms/3.0.8-2/export-CC.patch/

The 3.0.8-2 version adds the following commands to the prepare_build()
function:

export CC=$CC
export MAKEFLAGS="--environment-overrides"

I've verified that zfs-dkms builds fine for me if I temporarily comment
out the second line from /usr/sbin/dkms.

A build log for a failed attempt (with the flag present) is at:
https://0x0.st/o0fu.txt

The log also includes a dump of the environment variables at the start
of the build, from a command I added to the dkms script.

Digging a little deeper, it appears that when `--environment-overrides`
is set, a number of required command-line options (in particular, an -I
option to add /var/lib/dkms/zfs/2.1.6/build/include in the include
search path) fail to be set. I didn't manage to trace why exactly that
is, but you can see both a failing and a working example (for one object
file) at:
https://0x0.st/o0EC.txt

FWIW, it seems like the build environment dkms uses inherits whatever
was present in the environment when apt was called. If this is the case,
then it feels to me including the `--environment-overrides` flag has
potential to make things brittle. The effect of the flag is to: "Give
variables taken from the environment precedence over variables from
makefiles." Any arbitrary environment variables the user may have set
for their own purposes might be unexpectedly overriding important
variables from the Makefile(s).



Bug#1025171: zfs-dkms FTBFS against 6.0.0-5-amd64

2022-11-30 Thread M. Zhou
Package: zfs-dkms
Version: 2.1.6-3
Severity: serious

It was built againt 6.0.0-3-amd64 on my sid machine, but suddenly
stopped working with the recent 6.0.0-5-amd64 kernel.