Attempting to patch the debian 5.14 experimental kernel with the c630 bits. There seems to be some issue with the battery driver as it keeps claiming that i2c_transfer is an implicit declaration. Need to look into that.

In order to actually build the package itself though, I had to run the following commands that diederik gave me on #debian-kernel on oftc:

export ARCH=arm64
export CC=aarch64-linux-gnu-gcc-10
dpkg-architecture --host-arch arm64
dpkg-architecture -c fakeroot debian/rules maintainerclean
dpkg-architecture -c debian/rules orig
dpkg-architecture -c debian/rules debian/control
dpkg-architecture -c fakeroot debian/rules binary-indep -j$(nproc)
dpkg-architecture -c fakeroot debian/rules binary-arch -j$(nproc)

This will tell debian to build the package using the dpkg-architecture of arm64, on amd64.

Additionally, assuming you haven’t already you do need to run dpkg --add-architecture arm64 as well as apt update. In order to get the debian package to build, you will need to install:

dvipng:arm64
libbabeltrace-dev:arm64
libcap-dev:arm64
libdw-dev:arm64
libelf-dev:arm64
libglib2.0-dev:arm64
libiberty-dev:arm64
libnewt-dev:arm64
libnuma-dev:arm64
libopencsd-dev:arm64
libpci-dev:arm64
libperl-dev:arm64
libssl-dev:arm64
libudev-dev:arm64
libunwind-dev:arm64
libwrap0-dev:arm64
zlib1g-dev:arm64

Note that additional packages will be installed, but that’s the list of required packages.