On Sat, 2015-07-11 at 14:02 +0800, kbuild test robot wrote:
> tree:   git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux
> -fs modsign-pkcs7
> head:   3f53b7ecb20662175ab055aed442680da0822f35
> commit: 9466a1e2643a5a532054151b0cd494b5bbd07d1d [15/20] modsign: Add 
> explicit CONFIG_SYSTEM_TRUSTED_KEYS option
> config: x86_64-rhel (attached as .config)
> reproduce:
>   git checkout 9466a1e2643a5a532054151b0cd494b5bbd07d1d
>   # save the attached .config to linux build tree
>   make ARCH=x86_64 
> 
> All error/warnings (new ones prefixed by >>):
> 
> > > make[2]: *** No rule to make target 
> > > 'include/config/module/sig.h', needed by 
> > > 'kernel/x509_certificate_list'.
>    make[2]: Target '__build' not remade because of errors.

Hm, why doesn't include/config/module/sig.h exist? I thought it should
always exist if the option is visible in .config (even if it's
disabled).

This probably fixes it, as long as we can still trust the dependency to
actually work in all interesting cases of config changes...

diff --git a/kernel/Makefile b/kernel/Makefile
index 2d03e87..686d93b 100644
--- a/kernel/Makefile
+++ b/kernel/Makefile
@@ -180,7 +180,7 @@ quiet_cmd_x509certs  = CERTS   $(SIGNING_X509-y) $(patsubst 
"%",%,$(2))
                         awk '/-----BEGIN 
CERTIFICATE-----/{flag=1;next}/-----END CERTIFICATE-----/{flag=0}flag' $(2) 
/dev/null | base64 -d ) > $@ || ( rm $@; exit 1)
 
 targets += $(obj)/x509_certificate_list
-$(obj)/x509_certificate_list: $(SIGNING_X509-y) 
include/config/system/trusted/keys.h include/config/module/sig.h 
$(SYSTEM_TRUSTED_KEYS_SRCPREFIX)$(SYSTEM_TRUSTED_KEYS_FILENAME)
+$(obj)/x509_certificate_list: $(SIGNING_X509-y) 
include/config/system/trusted/keys.h $(wildcard include/config/module/sig.h) 
$(SYSTEM_TRUSTED_KEYS_SRCPREFIX)$(SYSTEM_TRUSTED_KEYS_FILENAME)
        $(call 
if_changed,x509certs,$(SYSTEM_TRUSTED_KEYS_SRCPREFIX)$(CONFIG_SYSTEM_TRUSTED_KEYS))
 
 endif

-- 
David Woodhouse                            Open Source Technology Centre
[email protected]                              Intel Corporation

Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to