[linux-oem][PATCH 5/6] UBUNTU: SAUCE: RTL8822BE: Add ubuntu/rtl8822be into build script

Hui Wang hui.wang at canonical.com
Wed Jan 24 06:42:36 UTC 2018


BugLink: https://launchpad.net/bugs/1745081

Signed-off-by: Hui Wang <hui.wang at canonical.com>
---
 debian/rules.d/2-binary-arch.mk | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)

diff --git a/debian/rules.d/2-binary-arch.mk b/debian/rules.d/2-binary-arch.mk
index dddadf2..45ee43c 100644
--- a/debian/rules.d/2-binary-arch.mk
+++ b/debian/rules.d/2-binary-arch.mk
@@ -64,6 +64,14 @@ define build_rtl8821ce =
 	$(kmake) -C $(builddir)/build-$* $(conc_level) $(rtl8821ce_opts) M=$(builddir)/build-$*/rtl8821ce modules
 endef
 
+define build_rtl8822be =
+	install -d $(builddir)/build-$*/rtl8822be
+	rsync -a --delete ubuntu/rtl8822be/ $(builddir)/build-$*/rtl8822be/
+	cd $(builddir)/build-$*/rtl8822be
+	ln -s rtl8822be/rtl8822b.mk $(builddir)/build-$*/
+	$(kmake) -C $(builddir)/build-$* $(conc_level) $(rtl8822be_opts) M=$(builddir)/build-$*/rtl8822be modules
+endef
+
 # Do the actual build, including image and modules
 $(stampdir)/stamp-build-%: target_flavour = $*
 $(stampdir)/stamp-build-%: splopts  = --with-linux=$(CURDIR)
@@ -75,12 +83,14 @@ $(stampdir)/stamp-build-%: zfsopts += --prefix=/usr --with-config=kernel
 $(stampdir)/stamp-build-%: bldimg = $(call custom_override,build_image,$*)
 $(stampdir)/stamp-build-%: enable_zfs = $(call custom_override,do_zfs,$*)
 $(stampdir)/stamp-build-%: rtl8821ce_opts = CONFIG_RTL8821CE=m
+$(stampdir)/stamp-build-%: rtl8822be_opts = CONFIG_RTL8822BE=m
 $(stampdir)/stamp-build-%: $(stampdir)/stamp-prepare-%
 	@echo Debug: $@ build_image $(build_image) bldimg $(bldimg)
 	$(build_cd) $(kmake) $(build_O) $(conc_level) $(bldimg) modules $(if $(filter true,$(do_dtbs)),dtbs)
 
 	$(if $(filter true,$(enable_zfs)),$(call build_zfs))
 	$(if $(filter amd64,$(arch)),$(call build_rtl8821ce))
+	$(if $(filter amd64,$(arch)),$(call build_rtl8822be))
 
 	@touch $@
 
@@ -96,6 +106,11 @@ define install_rtl8821ce =
 		$(kmake) -C $(builddir)/build-$* SUBDIRS=`pwd` modules_install $(rtl8821ce_opts)
 endef
 
+define install_rtl8822be =
+	cd $(builddir)/build-$*/rtl8822be; \
+		$(kmake) -C $(builddir)/build-$* SUBDIRS=`pwd` modules_install $(rtl8822be_opts)
+endef
+
 # Install the finished build
 install-%: pkgdir = $(CURDIR)/debian/$(bin_pkg_name)-$*
 install-%: pkgdir_ex = $(CURDIR)/debian/$(extra_pkg_name)-$*
@@ -122,6 +137,8 @@ install-%: splopts += $(conc_level)
 install-%: zfsopts  = $(splopts)
 install-%: rtl8821ce_opts  = INSTALL_MOD_DIR=kernel/ubuntu/rtl8821ce
 install-%: rtl8821ce_opts += INSTALL_MOD_PATH=$(pkgdir)/
+install-%: rtl8822be_opts  = INSTALL_MOD_DIR=kernel/ubuntu/rtl8822be
+install-%: rtl8822be_opts += INSTALL_MOD_PATH=$(pkgdir)/
 install-%: checks-%
 	@echo Debug: $@ kernel_file $(kernel_file) kernfile $(kernfile) install_file $(install_file) instfile $(instfile)
 	dh_testdir
@@ -182,6 +199,7 @@ endif
 
 	$(if $(filter true,$(enable_zfs)),$(call install_zfs))
 	$(if $(filter amd64,$(arch)),$(call install_rtl8821ce))
+	$(if $(filter amd64,$(arch)),$(call install_rtl8822be))
 
 	#
 	# Build module blacklists:
-- 
2.7.4





More information about the kernel-team mailing list