Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fedora 40: 'make rpm-kmod' broken #16439

Closed
tonyhutter opened this issue Aug 12, 2024 · 2 comments · Fixed by #16450
Closed

Fedora 40: 'make rpm-kmod' broken #16439

tonyhutter opened this issue Aug 12, 2024 · 2 comments · Fixed by #16450
Labels
Type: Defect Incorrect behavior (e.g. crash, hang)

Comments

@tonyhutter
Copy link
Contributor

System information

Type Version/Name
Distribution Name Fedora
Distribution Version 40 (and 39)
Kernel Version 6.10.3
Architecture x86-64
OpenZFS Version master (9c56b8e)

Describe the problem you're observing

make rpm-kmod is broken on the latest Fedora 40 update. This is breaking the buildbot builds on Fedora 39-40.

Describe how to reproduce the problem

make rpm-kmod. I tried bumping the supported kernel version META file to 6.10, but that didn't help.

Include any warning/errors/backtraces from the system logs

~/zfs$ ./autogen && ./configure && make rpm-kmod
...


make[4]: Entering directory '/tmp/zfs-build-hutter-aEiFUnpD/BUILD/zfs-kmod-2.2.99/_kmod_build_6.10.3-200.fc40.x86_64/module'
mkdir -p os/linux/spl/
mkdir -p avl/ icp/ icp/algs/aes/ icp/algs/blake3/ icp/algs/edonr/ icp/algs/modes/ icp/algs/sha2/ icp/algs/skein/ icp/api/ icp/asm-aarch64/blake3/ icp/asm-aarch64/sha2/ icp/asm-arm/sha2/ icp/asm-ppc64/blake3/ icp/asm-ppc64/sha2/ icp/asm-x86_64/aes/ icp/asm-x86_64/blake3/ icp/asm-x86_64/modes/ icp/asm-x86_64/sha2/ icp/core/ icp/io/ icp/spi/ lua/ lua/setjmp/ nvpair/ os/linux/zfs/ unicode/ zcommon/ zfs/ zstd/ zstd/lib/common/ zstd/lib/compress/ zstd/lib/decompress/
make -C /usr/src/kernels/6.10.3-200.fc40.x86_64  \
	  \
	M="$PWD"  CONFIG_ZFS=m modules
make[5]: Entering directory '/usr/src/kernels/6.10.3-200.fc40.x86_64'
make[7]: *** No rule to make target '/tmp/zfs-build-hutter-aEiFUnpD/BUILD/zfs-kmod-2.2.99/_kmod_build_6.10.3-200.fc40.x86_64/module/os/linux/spl/spl-atomic.o', needed by '/tmp/zfs-build-hutter-aEiFUnpD/BUILD/zfs-kmod-2.2.99/_kmod_build_6.10.3-200.fc40.x86_64/module/spl.o'.  Stop.
make[7]: *** Waiting for unfinished jobs....
make[6]: *** [/usr/src/kernels/6.10.3-200.fc40.x86_64/Makefile:1946: /tmp/zfs-build-hutter-aEiFUnpD/BUILD/zfs-kmod-2.2.99/_kmod_build_6.10.3-200.fc40.x86_64/module] Error 2
make[5]: *** [Makefile:252: __sub-make] Error 2
make[5]: Leaving directory '/usr/src/kernels/6.10.3-200.fc40.x86_64'
make[4]: *** [Makefile:56: modules-Linux] Error 2
make[4]: Leaving directory '/tmp/zfs-build-hutter-aEiFUnpD/BUILD/zfs-kmod-2.2.99/_kmod_build_6.10.3-200.fc40.x86_64/module'
make[3]: *** [Makefile:12324: all-recursive] Error 1
make[3]: Leaving directory '/tmp/zfs-build-hutter-aEiFUnpD/BUILD/zfs-kmod-2.2.99/_kmod_build_6.10.3-200.fc40.x86_64'
make[2]: *** [Makefile:4652: all] Error 2
make[2]: Leaving directory '/tmp/zfs-build-hutter-aEiFUnpD/BUILD/zfs-kmod-2.2.99/_kmod_build_6.10.3-200.fc40.x86_64'
error: Bad exit status from /tmp/zfs-build-hutter-aEiFUnpD/TMP/rpm-tmp.lrDR6F (%build)

RPM build warnings:
    source_date_epoch_from_changelog set but %changelog is missing

RPM build errors:
    Bad exit status from /tmp/zfs-build-hutter-aEiFUnpD/TMP/rpm-tmp.lrDR6F (%build)
make[1]: *** [Makefile:14511: rpm-common] Error 1
make[1]: Leaving directory '/home/hutter/zfs'
make: *** [Makefile:14445: rpm-kmod] Error 2
@tonyhutter tonyhutter added the Type: Defect Incorrect behavior (e.g. crash, hang) label Aug 12, 2024
@tonyhutter
Copy link
Contributor Author

@tonyhutter
Copy link
Contributor Author

The problem looks to be caused by these kernel changes:

b1992c3772e6 kbuild: use $(src) instead of $(srctree)/$(src) for source directory
9a0ebe5011f4 kbuild: use $(obj)/ instead of $(src)/ for common pattern rules

When I use Fedora 40's slightly older /usr/src/kernels/6.9.9-200.fc40.x86_64/scripts/Makefile.build it starts to build. I'm guessing an update to our Kbuild.in is needed.

snajpa pushed a commit to vpsfreecz/zfs that referenced this issue Aug 15, 2024
The 6.10 kernel broke our rpm-kmod builds.  The 6.10 kernel really
want the source files in the same directory as the object files.
This workaround makes rpm-kmod work again.  It also updates
the builtin kernel codepath to work correctly with 6.10.

See kernel commits:

b1992c3772e6 kbuild: use $(src) instead of $(srctree)/$(src) for source
                     directory
9a0ebe5011f4 kbuild: use $(obj)/ instead of $(src)/ for common pattern
                     rules

Fixes: openzfs#16439
Signed-off-by: Tony Hutter <hutter2@llnl.gov>
lundman pushed a commit to openzfsonwindows/openzfs that referenced this issue Sep 4, 2024
The 6.10 kernel broke our rpm-kmod builds.  The 6.10 kernel really
wants the source files in the same directory as the object files.
This workaround makes rpm-kmod work again.  It also updates
the builtin kernel codepath to work correctly with 6.10.

See kernel commits:

b1992c3772e6 kbuild: use $(src) instead of $(srctree)/$(src) for source
                     directory
9a0ebe5011f4 kbuild: use $(obj)/ instead of $(src)/ for common pattern
                     rules

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Tony Hutter <hutter2@llnl.gov>
Closes openzfs#16439
Closes openzfs#16450
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Defect Incorrect behavior (e.g. crash, hang)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant