On 17.03.2020 19:35, Anthony PERARD wrote:
On Wed, Mar 04, 2020 at 04:00:52PM +0100, Jan Beulich wrote:
On 26.02.2020 12:33, Anthony PERARD wrote:
@@ -113,6 +115,64 @@ $(KCONFIG_CONFIG):
+AFLAGS += -D__ASSEMBLY__
+
+CFLAGS += $(CFLAGS-y)

I can't seem to be able to spot a similar line for AFLAGS.

I didn't add any because it wasn't necessary.

Symmetry / consistency would still be desirable imo.

@@ -107,7 +65,7 @@ $(foreach o,$(filter-out %/,$(obj-y) $(obj-bin-y) 
$(extra-y)),$(eval $(call gend
  subdir-y := $(subdir-y) $(filter %/, $(obj-y))
  obj-y    := $(patsubst %/, %/built_in.o, $(obj-y))
-$(filter %.init.o,$(obj-y) $(obj-bin-y) $(extra-y)): CFLAGS += -DINIT_SECTIONS_ONLY
+$(filter %.init.o,$(obj-y) $(obj-bin-y) $(extra-y)): CFLAGS-y += 
-DINIT_SECTIONS_ONLY

While in the description you say "We can't use CFLAGS in
subdirectories to add flags to particular targets, ...", it
remains unclear there why that is, and hence why changes like
this one are necessary. If this is a restriction that's going to
remain, this also needs writing down in a prominent place. After

Yes, I should probably start writing some documentation, probably
following the kind of documentation that Linux has for kbuild, and I
could put that in docs/misc, along side the kconfig doc. That probably
not a prominent place, but I don't know if there's a better place.

If it's to live under docs/, then I guess xen/Rules.mk should at
least point to that documentation (perhaps in a comment near the
first setting or consumption of CFLAGS-y).

Jan

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

Reply via email to