[pve-devel] Failing to build pve-kernel 5.0.x from git

Thomas Lamprecht t.lamprecht at proxmox.com
Wed Oct 2 16:57:59 CEST 2019


On 10/2/19 4:46 PM, Chris Hofstaedtler | Deduktiva wrote:
> Hi,
> 
> I'm trying to build the current pve-kernel from git, but apparently
> this needs some extra tarballs? Am I holding it wrong?

we have no tarballs anymore, it's submodules all the way down.

> 
> Log (after git clone, git submodule update --init):

Either don't do the initial "git submodule update --init" yourself and
let the makefile handle that or add the "--recursive" flag..

But a fresh
# git clone git://git.proxmox.com/git/pve-kernel.git
# make

works just fine, just retried here.

> 
> $ git describe --always
> 9e3f73d
> $ make
> test -f "submodules/ubuntu-disco/README" || git submodule update --init submodules/ubuntu-disco
> test -f "submodules/zfsonlinux/Makefile" || git submodule update --init --recursive submodules/zfsonlinux
> rm -rf build/ubuntu-disco ubuntu-disco.prepared
> mkdir -p build
> cp -a submodules/ubuntu-disco build/ubuntu-disco
> cat build/ubuntu-disco/debian.master/config/config.common.ubuntu build/ubuntu-disco/debian.master/config/amd64/config.common.amd64 build/ubuntu-disco/debian.master/config/amd64/config.flavour.generic > config-5.0.21.org
> cp config-5.0.21.org build/ubuntu-disco/.config
> sed -i build/ubuntu-disco/Makefile -e 's/^EXTRAVERSION.*$/EXTRAVERSION=-3-pve/'
> rm -rf build/ubuntu-disco/debian build/ubuntu-disco/debian.master
> set -e; cd build/ubuntu-disco; for patch in ../../patches/kernel/*.patch; do echo "applying patch '$patch'" && patch -p1 < ${patch}; done
> applying patch '../../patches/kernel/0001-Make-mkcompile_h-accept-an-alternate-timestamp-strin.patch'
> patching file scripts/mkcompile_h
> applying patch '../../patches/kernel/0002-bridge-keep-MAC-of-first-assigned-port.patch'
> patching file net/bridge/br_stp_if.c
> applying patch '../../patches/kernel/0003-pci-Enable-overrides-for-missing-ACS-capabilities-4..patch'
> patching file Documentation/admin-guide/kernel-parameters.txt
> patching file drivers/pci/quirks.c
> applying patch '../../patches/kernel/0004-kvm-disable-default-dynamic-halt-polling-growth.patch'
> patching file virt/kvm/kvm_main.c
> applying patch '../../patches/kernel/0005-Revert-KVM-VMX-enable-nested-virtualization-by-defau.patch'
> patching file arch/x86/kvm/vmx/vmx.c
> applying patch '../../patches/kernel/0006-rbd-don-t-assert-on-writes-to-snapshots.patch'
> patching file drivers/block/rbd.c
> applying patch '../../patches/kernel/0007-x86-fpu-backport-copy_kernel_to_XYZ_err-helpers.patch'
> patching file arch/x86/include/asm/fpu/internal.h
> touch ubuntu-disco.prepared
> rm -rf build/modules/pkg-zfs build/modules/tmp pkg-zfs.prepared
> mkdir -p build/modules/tmp
> cp -a submodules/zfsonlinux/* build/modules/tmp
> cd build/modules/tmp; make kernel
> make[1]: Entering directory '/home/ch/Source/pve-kernel/build/modules/tmp'
> test -f "upstream/README.md" || git submodule update --init
> rm -rf zfs-linux_0.8.2
> mkdir zfs-linux_0.8.2
> cp -a upstream/* zfs-linux_0.8.2/
> cp: cannot stat 'upstream/*': No such file or directory

your zfs submodule is not correctly checked out, it uses a submodule itself
the 
# git submodule update --init --recursive submodules/zfsonlinux
command normally takes care of that, but as you manually did one
without the --recursive flag the 
# test -f "submodules/zfsonlinux/Makefile" || git submodule update --init --recursive submodules/zfsonlinux
makefield command doesn't execute any more as the first
condition is already true.

Try
# git submodule update --init --recursive submodules/zfsonlinux
to fiy this up without a fresh clone or other things

> make[1]: *** [Makefile:59: zfs-linux_0.8.2] Error 1
> make[1]: Leaving directory '/home/ch/Source/pve-kernel/build/modules/tmp'
> make: *** [Makefile:99: pkg-zfs.prepared] Error 2
> $ ls submodules/zfsonlinux/upstream/
> $
> 
> Any hints would be appreciated.
> 
> Thanks,
> Chris
> 
> PS: the README still says things about bionic, while this is
> building a disco-based kernel.
> 





More information about the pve-devel mailing list