Enables storing the C compiler ($(CC)) that was
used for during compilation for the unikernel
image.
+
+ config LIBUKLIBID_INFO_UKCONFIGGZ
+ bool "Embed gzipped configuration (.config)"
+ help
+ If enabled, the current configuration `.config`
+ of the build is gzipped and embedded to the
+ global metadata infomration space.
endmenu
menu "Per library metadata"
LIBUKLIBID_SRCS-$(CONFIG_LIBUKLIBID_INFO) += $(LIBUKLIBID_BASE)/infosec.ld
LIBUKLIBID_SRCS-$(CONFIG_LIBUKLIBID_INFO) += $(LIBUKLIBID_BASE)/libinfo.S|global
LIBUKLIBID_LIBINFO_GLOBAL_FLAGS-y += -D__GLOBALINFO__
+LIBUKLIBID_LIBINFO_GLOBAL_CDEPS-$(CONFIG_LIBUKLIBID_INFO_UKCONFIGGZ) += $(LIBUKLIBID_BUILD)/config.gz
+LIBUKLIBID_LIBINFO_GLOBAL_FLAGS-$(CONFIG_LIBUKLIBID_INFO_UKCONFIGGZ) += -DUK_CONFIGGZINC="$(LIBUKLIBID_BUILD)/config.gz"
+
+$(LIBUKLIBID_BUILD)/config.gz: $(UK_CONFIG_OUT)
+ $(call build_cmd,GZ,libuklibid,$@, \
+ $(GZIP) -f -9 -c $< >$@)
UK_PREPARE-$(CONFIG_LIBUKLIBID) += $(LIBUKLIBID_BUILD)/libraries.in.new
RECORD(UKLI_REC_COMPILER,
.asciz STRINGIFY(__LIBUKLIBID_COMPILER__))
#endif /* CONFIG_LIBUKLIBID_INFO_COMPILER */
+#if CONFIG_LIBUKLIBID_INFO_UKCONFIGGZ
+ RECORD(UKLI_REC_UKCONFIGGZ, .incbin STRINGIFY(UK_CONFIGGZINC))
+#endif /* CONFIG_LIBUKLIBID_INFO_UKCONFIGGZ */
#else /* !__GLOBALINFO__ */
/* Records per library */