kbuild: properly pass options to hostcc when doing make O=..

This fix a longstanding bug where proper options was not
passed to hostcc in case of a make O=.. build.
This bug showed up in (not yet merged) klibc, and is not known
to have any counterpart in-kernel.
Fixed by moving the flags macro to Kbuild.include so it can be used
by both Makefile.lib and Makefile.host.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2 files changed