Configure is doing strange stuff and not using the target compiler.
build.LibreELEC-Generic.x86_64-13.0-devel/build/zfs-2.3.0/build/kernel_fpu_license/build.log
make: Entering directory '/var/media/DATA/home-rudi/LibreELEC.tv/build.LibreELEC-Generic.x86_64-13.0-devel/build/linux-6.12.15'
warning: the compiler differs from the one used to build the kernel
The kernel was built by: x86_64-libreelec-linux-gnu-gcc-15.0.1 (GCC) 15.0.1 20250223 (experimental)
You are using: gcc (Ubuntu 14.2.0-4ubuntu2~24.04) 14.2.0
MODPOST /var/media/DATA/home-rudi/LibreELEC.tv/build.LibreELEC-Generic.x86_64-13.0-devel/build/zfs-2.3.0/build/kernel_fpu_license
/Module.symvers
ERROR: modpost: GPL-incompatible module kernel_fpu_license.ko uses GPL-only symbol 'kernel_fpu_begin_mask'
ERROR: modpost: GPL-incompatible module kernel_fpu_license.ko uses GPL-only symbol 'kernel_fpu_end'
==
this will get you quite a bit further. It is not complete or fully working on the make.
PKG_NAME="zfs"
PKG_VERSION="2.3.0"
PKG_SHA256="6e8787eab55f24c6b9c317f3fe9b0da9a665eb34c31df88ff368d9a92e9356a6"
PKG_URL="https://github.com/openzfs/zfs/releases/download/zfs-${PKG_VERSION}/zfs-${PKG_VERSION}.tar.gz"
PKG_DESCRIPTION="ZFS filesystem support"
#PKG_TOOLCHAIN="autotools"
PKG_IS_KERNEL_PKG="yes"
configure_target() {
#https://github.com/openzfs/zfs/pull/16924
cd $PKG_BUILD
export KERNEL_CROSS_COMPILE=${TARGET_KERNEL_PREFIX}
export KERNEL_ARCH=${TARGET_KERNEL_ARCH}
./configure --host=$TARGET_NAME --prefix=/usr \
--with-linux=$(kernel_path) \
--with-linux-obj=$(kernel_path)
}
make_target() {
make V=1 \
ARCH=${TARGET_KERNEL_ARCH} \
KSRC=$(kernel_path) \
CROSS_COMPILE=${TARGET_KERNEL_PREFIX}
}
makeinstall_target() {
mkdir -p ${INSTALL}/$(get_full_module_dir)/${PKG_NAME}
cp *.ko ${INSTALL}/$(get_full_module_dir)/${PKG_NAME}
}
Display More