Export generated AIDL headers
It is common for developers to generate/compile AIDL in a static
library, then link that library into an executable. When doing this,
developers need to export the generated headers.
Bug: 25779424
Test: a refactoring of the aidl Android.mk shows this works
Change-Id: I4f7d471a601d2a683cb5a9da5e02e3fab576c26a
diff --git a/core/binary.mk b/core/binary.mk
index d3b536d..4e52e35 100644
--- a/core/binary.mk
+++ b/core/binary.mk
@@ -730,8 +730,9 @@
$(transform-aidl-to-cpp)
-include $(addsuffix .P,$(basename $(aidl_gen_cpp)))
-# Add generated headers to include path.
+# Add generated headers to include paths.
my_c_includes += $(aidl_gen_include_root)
+my_export_c_include_dirs += $(aidl_gen_include_root)
# Pick up the generated C++ files later for transformation to .o files.
my_generated_sources += $(aidl_gen_cpp)