diff mbox

doxygen-html: include platform APIs only if they exist

Message ID 1415701817-10016-1-git-send-email-ciprian.barbu@linaro.org
State New
Headers show

Commit Message

Ciprian Barbu Nov. 11, 2014, 10:30 a.m. UTC
Signed-off-by: Ciprian Barbu <ciprian.barbu@linaro.org>
---
This affects primarily odp-netmap but the assumption that there are API files in
platform/XXX/include/api is wrong to begin with.

 aminclude.am | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
diff mbox

Patch

diff --git a/aminclude.am b/aminclude.am
index a8ce032..92902be 100644
--- a/aminclude.am
+++ b/aminclude.am
@@ -146,11 +146,13 @@  doxygen-html: @DX_DOCDIR@/@PACKAGE@.tag
 
 doxygen-doc: doxygen-html $(DX_PS_GOAL) $(DX_PDF_GOAL)
 
+PLATFORM_API = ${srcdir}/platform/${with_platform}/include/api
+
 @DX_DOCDIR@/@PACKAGE@.tag: $(DX_CONFIG) $(pkginclude_HEADERS)
 	rm -rf @DX_DOCDIR@
 	@mkdir -p @DX_DOCDIR@/api_headers
 	@cp ${srcdir}/platform/linux-generic/include/api/odp_*.h @DX_DOCDIR@/api_headers
-	@cp ${srcdir}/platform/${with_platform}/include/api/odp_*.h @DX_DOCDIR@/api_headers
+	@if find ${PLATFORM_API} -type f -name '*.h' 2> /dev/null; then cp ${PLATFORM_API}/odp_*.h @DX_DOCDIR@/api_headers; fi
 	$(DX_ENV) $(DX_DOXYGEN) $(srcdir)/$(DX_CONFIG)
 	@rm -rf @DX_DOCDIR@/api_headers