Message ID | 20170307234823.17093.94956.stgit@bwallan-cwp1.jf.intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Wed, Mar 8, 2017 at 12:48 AM, Bruce Allan <bruce.w.allan@intel.com> wrote: > Commit db547ef19064 ("Kbuild: don't add obj tree in additional includes") > causes warnings (-Wmissing-include-dirs) when compiling external modules > with KBUILD_OUTPUT set and W=1. This is because $src can be an absolute > path to the external module source which when prefixed with -I$(srctree)/ > generates an incorrect directory path. > > Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> > Cc: Arnd Bergmann <arnd@arndb.de> Looks good to me, sorry for the regression Acked-by: Arnd Bergmann <arnd@arndb.de> -- To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
2017-03-08 15:59 GMT+09:00 Arnd Bergmann <arnd@arndb.de>: > On Wed, Mar 8, 2017 at 12:48 AM, Bruce Allan <bruce.w.allan@intel.com> wrote: >> Commit db547ef19064 ("Kbuild: don't add obj tree in additional includes") >> causes warnings (-Wmissing-include-dirs) when compiling external modules >> with KBUILD_OUTPUT set and W=1. This is because $src can be an absolute >> path to the external module source which when prefixed with -I$(srctree)/ >> generates an incorrect directory path. >> >> Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> >> Cc: Arnd Bergmann <arnd@arndb.de> > > Looks good to me, sorry for the regression > > Acked-by: Arnd Bergmann <arnd@arndb.de> Applied to linux-kbuild/fixes Thanks!
diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib index 0a07f90..7234e61 100644 --- a/scripts/Makefile.lib +++ b/scripts/Makefile.lib @@ -155,7 +155,7 @@ else # $(call addtree,-I$(obj)) locates .h files in srctree, from generated .c files # and locates generated .h files # FIXME: Replace both with specific CFLAGS* statements in the makefiles -__c_flags = $(if $(obj),-I$(srctree)/$(src) -I$(obj)) \ +__c_flags = $(if $(obj),$(call addtree,-I$(src)) -I$(obj)) \ $(call flags,_c_flags) __a_flags = $(call flags,_a_flags) __cpp_flags = $(call flags,_cpp_flags)
Commit db547ef19064 ("Kbuild: don't add obj tree in additional includes") causes warnings (-Wmissing-include-dirs) when compiling external modules with KBUILD_OUTPUT set and W=1. This is because $src can be an absolute path to the external module source which when prefixed with -I$(srctree)/ generates an incorrect directory path. Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Cc: Arnd Bergmann <arnd@arndb.de> --- scripts/Makefile.lib | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html