Message ID | 20200602114050.5964-2-jgross@suse.com (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | xen: build fixes for CONFIG_HYPFS | expand |
On 02.06.2020 13:40, Juergen Gross wrote: > --- a/xen/common/Makefile > +++ b/xen/common/Makefile > @@ -75,7 +75,7 @@ obj-$(CONFIG_UBSAN) += ubsan/ > obj-$(CONFIG_NEEDS_LIBELF) += libelf/ > obj-$(CONFIG_HAS_DEVICE_TREE) += libfdt/ > > -config.gz: ../.config > +config.gz: $(XEN_ROOT)/xen/$(KCONFIG_CONFIG) Looking at all pre-existing uses of KCONFIG_CONFIG this is the first one assuming it holds a relative path. The doc also doesn't indicate it can't be an absolute one. Jan
On Tue, Jun 02, 2020 at 01:55:14PM +0200, Jan Beulich wrote: > On 02.06.2020 13:40, Juergen Gross wrote: > > --- a/xen/common/Makefile > > +++ b/xen/common/Makefile > > @@ -75,7 +75,7 @@ obj-$(CONFIG_UBSAN) += ubsan/ > > obj-$(CONFIG_NEEDS_LIBELF) += libelf/ > > obj-$(CONFIG_HAS_DEVICE_TREE) += libfdt/ > > > > -config.gz: ../.config > > +config.gz: $(XEN_ROOT)/xen/$(KCONFIG_CONFIG) > > Looking at all pre-existing uses of KCONFIG_CONFIG this is the > first one assuming it holds a relative path. The doc also doesn't > indicate it can't be an absolute one. This is not an objection to this patch right? Wei. > > Jan
On 02.06.20 14:07, Wei Liu wrote: > On Tue, Jun 02, 2020 at 01:55:14PM +0200, Jan Beulich wrote: >> On 02.06.2020 13:40, Juergen Gross wrote: >>> --- a/xen/common/Makefile >>> +++ b/xen/common/Makefile >>> @@ -75,7 +75,7 @@ obj-$(CONFIG_UBSAN) += ubsan/ >>> obj-$(CONFIG_NEEDS_LIBELF) += libelf/ >>> obj-$(CONFIG_HAS_DEVICE_TREE) += libfdt/ >>> >>> -config.gz: ../.config >>> +config.gz: $(XEN_ROOT)/xen/$(KCONFIG_CONFIG) >> >> Looking at all pre-existing uses of KCONFIG_CONFIG this is the >> first one assuming it holds a relative path. The doc also doesn't >> indicate it can't be an absolute one. > > This is not an objection to this patch right? I can see his point. In case KCONFIG_CONFIG is set to an absolute path the result won't build. The proper solution would be to test KCONFIG_CONFIG for being an absolute path and do the prefixing of $(XEN_ROOT)/xen/ only if this isn't the case. I'll send V2 of this patch. Juergen
On 02.06.2020 14:07, Wei Liu wrote: > On Tue, Jun 02, 2020 at 01:55:14PM +0200, Jan Beulich wrote: >> On 02.06.2020 13:40, Juergen Gross wrote: >>> --- a/xen/common/Makefile >>> +++ b/xen/common/Makefile >>> @@ -75,7 +75,7 @@ obj-$(CONFIG_UBSAN) += ubsan/ >>> obj-$(CONFIG_NEEDS_LIBELF) += libelf/ >>> obj-$(CONFIG_HAS_DEVICE_TREE) += libfdt/ >>> >>> -config.gz: ../.config >>> +config.gz: $(XEN_ROOT)/xen/$(KCONFIG_CONFIG) >> >> Looking at all pre-existing uses of KCONFIG_CONFIG this is the >> first one assuming it holds a relative path. The doc also doesn't >> indicate it can't be an absolute one. > > This is not an objection to this patch right? It is. Jan
diff --git a/xen/common/Makefile b/xen/common/Makefile index 91581e1815..2799f6510c 100644 --- a/xen/common/Makefile +++ b/xen/common/Makefile @@ -75,7 +75,7 @@ obj-$(CONFIG_UBSAN) += ubsan/ obj-$(CONFIG_NEEDS_LIBELF) += libelf/ obj-$(CONFIG_HAS_DEVICE_TREE) += libfdt/ -config.gz: ../.config +config.gz: $(XEN_ROOT)/xen/$(KCONFIG_CONFIG) gzip -c $< >$@ config_data.o: config.gz
Commit 58263ed7713e ("xen: add /buildinfo/config entry to hypervisor filesystem") added a dependency to .config, but the hypervisor's build config could be have another name via setting KCONFIG_CONFIG. Fix that by using $(KCONFIG_CONFIG) instead. Additionally reference the config file via $(XEN_ROOT) instead of a relative path. Reported-by: Andrew Cooper <andrew.cooper3@citrix.com> Signed-off-by: Juergen Gross <jgross@suse.com> --- xen/common/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)