diff mbox series

[unstable/kinetic,3/3] UBUNTU: SAUCE: Switch to using debian/scripts/sign-module

Message ID 20220729084921.767082-4-juerg.haefliger@canonical.com
State New
Headers show
Series Add support for derivative-specific staging module signing | expand

Commit Message

Juerg Haefliger July 29, 2022, 8:49 a.m. UTC
Use the new script debian/scripts/sign-module to determine if a modules
needs to be signed.

Signed-off-by: Juerg Haefliger <juerg.haefliger@canonical.com>
---
 scripts/Makefile.modinst | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)
diff mbox series

Patch

diff --git a/scripts/Makefile.modinst b/scripts/Makefile.modinst
index 0c4e808ecb84..89d5973e4743 100644
--- a/scripts/Makefile.modinst
+++ b/scripts/Makefile.modinst
@@ -65,11 +65,9 @@  endif
 ifeq ($(CONFIG_MODULE_SIG_ALL),y)
 sig-key := $(if $(wildcard $(CONFIG_MODULE_SIG_KEY)),,$(srctree)/)$(CONFIG_MODULE_SIG_KEY)
 quiet_cmd_sign = SIGN    $@
-      cmd_sign = if echo "$@" | grep -qF "/drivers/staging/" && \
-                    test -f $(srctree)/debian/signature-inclusion && \
-                    ! grep -qFx "$(notdir $@)" $(srctree)/debian/signature-inclusion ; \
-                 then echo "UBUNTU: Not signing $@" ; \
-                 else scripts/sign-file $(CONFIG_MODULE_SIG_HASH) $(sig-key) certs/signing_key.x509 $@ \
+      cmd_sign = if test -e $(srctree)/debian/scripts/sign-module && \
+                    $(srctree)/debian/scripts/sign-module $@ ; \
+                 then scripts/sign-file $(CONFIG_MODULE_SIG_HASH) $(sig-key) certs/signing_key.x509 $@ \
                       $(if $(KBUILD_EXTMOD),|| true) ; \
                  fi
 else