[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [XEN PATCH v3 15/23] xen/build: have the root Makefile generates the CFLAGS
On Tue, Mar 17, 2020 at 06:05:24PM +0000, Anthony PERARD wrote: > On Thu, Feb 27, 2020 at 12:05:04PM +0100, Roger Pau Monné wrote: > > On Wed, Feb 26, 2020 at 11:33:47AM +0000, Anthony PERARD wrote: > > > +ifneq ($(CONFIG_CC_IS_CLANG),y) > > > +# Clang doesn't understand this command line argument, and doesn't > > > appear to > > > +# have an suitable alternative. The resulting compiled binary does > > > function, > > > +# but has an excessively large symbol table. > > > +CFLAGS += -Wa,--strip-local-absolute > > > > This is not really related to clang, but to the assembler. If clang is > > used with -no-integrated-as it's quite likely that the GNU assembler > > will be used, and hence this option would be available. > > > > Can we use cc-option-add here in order to detect whether the build > > toolchain support the option? > > That can be done, but I think I'll do that as a follow up of this patch, > to avoid too many changes when moving the cflags around. > > > Ideally this should be done after the integrated assembler tests > > performed in x86/Rules.mk. So, testing for the -Wa,--strip-local-absolute flags turns out to be more complicated than I though it would be. - cc-option-add doesn't work because it doesn't test with the current list of CFLAGS. And if I add the CFLAGS, clang says the option is unused, it doesn't matter if -no-integrated-as is present or not. - I tried to use as-option macro from Linux but that comes with issues as well. I don't think that enough work as been done to make it work well with clang. (I probably need to filter -Wall out of the CFLAGS when testing, and they are probably other issues.) So I think I leave the enhancement for later. Having the flag depends on GCC is good enough for now. Thanks, -- Anthony PERARD _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |