kbuild: introduce destination-y for exported headers
xtensa and arm have asked for a possibility to export headers
and locate them in a specific directory when exported.
Introduce destiantion-y to support this.
This patch in additiona adds some limited
documentation for the variables used for exported headers.
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Cc: Oskar Schirmer <os@emlix.com>
Cc: Mikael Starvik <mikael.starvik@axis.com>
diff --git a/scripts/Makefile.headersinst b/scripts/Makefile.headersinst
index 612dc13..095cfc8 100644
--- a/scripts/Makefile.headersinst
+++ b/scripts/Makefile.headersinst
@@ -14,6 +14,8 @@
kbuild-file := $(srctree)/$(obj)/Kbuild
include $(kbuild-file)
+_dst := $(if $(destination-y),$(destination-y),$(_dst))
+
include scripts/Kbuild.include
install := $(INSTALL_HDR_PATH)/$(_dst)