@@ -20,6 +20,4 @@ do_tools_host = true
do_extras_package = true
do_tools_common = true
do_tools_acpidbg = true
-do_zfs = true
-do_v4l2loopback = true
do_odm_drivers = true
@@ -19,4 +19,3 @@ do_tools_perf_jvmti = true
do_tools_bpftool = true
do_dtbs = true
-do_zfs = true
@@ -16,4 +16,3 @@ do_tools_perf_jvmti = true
do_tools_bpftool = true
#do_flavour_image_package = false
-do_zfs = true
@@ -17,5 +17,3 @@ do_tools_cpupower = true
do_tools_perf = true
do_tools_perf_jvmti = true
do_tools_bpftool = true
-
-do_zfs = true
@@ -1,2 +1,2 @@
-v4l2loopback 0.12.5-1ubuntu5 modulename=v4l2loopback debpath=pool/universe/v/v4l2loopback/v4l2loopback-dkms_0.12.5-1ubuntu5_all.deb rprovides=v4l2loopback-modules rprovides=v4l2loopback-dkms
-zfs-linux 2.1.2-1ubuntu3 modulename=zfs debpath=pool/universe/z/zfs-linux/zfs-dkms_2.1.2-1ubuntu3_all.deb rprovides=spl-modules rprovides=spl-dkms rprovides=zfs-modules rprovides=zfs-dkms
+v4l2loopback 0.12.5-1ubuntu5 modulename=v4l2loopback debpath=pool/universe/v/v4l2loopback/v4l2loopback-dkms_0.12.5-1ubuntu5_all.deb arch=amd64 rprovides=v4l2loopback-modules rprovides=v4l2loopback-dkms
+zfs-linux 2.1.2-1ubuntu3 modulename=zfs debpath=pool/universe/z/zfs-linux/zfs-dkms_2.1.2-1ubuntu3_all.deb arch=amd64 arch=arm64 arch=ppc64el arch=s390x rprovides=spl-modules rprovides=spl-dkms rprovides=zfs-modules rprovides=zfs-dkms
@@ -40,6 +40,11 @@ do_tools_host?=false
do_tools_perf_jvmti?=false
do_enforce_all?=false
+# Default settings for DKMS modules.
+$(foreach _m,$(all_dkms_modules), \
+ $(eval do_$(_m) ?= $(if $(filter $(arch),$(filter-out $(dkms_exclude),$(if $(filter __all__,$(dkms_$(_m)_archs)),$(arch),$(dkms_$(_m)_archs)) $(dkms_include))),true,false)) \
+)
+
# Don't build tools in a cross compile environment.
ifneq ($(DEB_HOST_ARCH),$(DEB_BUILD_ARCH))
do_tools=false
@@ -305,5 +305,10 @@ $(foreach _line,$(shell gawk '{ OFS = "!"; $$1 = $$1; print }' $(DROOT)/dkms-ver
, \
$(error debpath for $(_deb_pkgname) not specified.) \
) \
+ $(if $(filter arch=%,$(_params)), \
+ $(eval dkms_$(_m)_archs = $(patsubst arch=%,%,$(filter arch=%,$(_params)))) \
+ , \
+ $(eval dkms_$(_m)_archs = __all__) \
+ ) \
$(eval dkms_$(_m)_rprovides = $(patsubst rprovides=%,%,$(filter rprovides=%,$(_params)))) \
)