How to copy additional header directories in Newlib-4.1.0?
Posted: Thu Apr 21, 2022 10:09 am
Hi,
I am modifying one Makefile.am to export my headers' folder "sap_additional_headers". The issue is that subdirs of this folder is only copied to "dist", but not to "targ_include". Compiling newlib then fails due to missing headers in the subdirs of "targ_include".
Why is that and how to solve it properly? I think stmp-targ-include in newlib/Makefile.am is better to be not modified. So there should be a way to easily use the headers in "dist".
Related code in Makefile.am:
I am modifying one Makefile.am to export my headers' folder "sap_additional_headers". The issue is that subdirs of this folder is only copied to "dist", but not to "targ_include". Compiling newlib then fails due to missing headers in the subdirs of "targ_include".
Why is that and how to solve it properly? I think stmp-targ-include in newlib/Makefile.am is better to be not modified. So there should be a way to easily use the headers in "dist".
Related code in Makefile.am:
Code: Select all
install-data-local:
$(mkinstalldirs) $(DESTDIR)$(tooldir)/include/sap_additional_headers; \
for i in $(srcdir)/../include/sap_additional_headers/*.h; do \
$(INSTALL_DATA) $$i $(DESTDIR)$(tooldir)/include/sap_additional_headers/`basename $$i`; \
done; \
$(mkinstalldirs) $(DESTDIR)$(tooldir)/include/sap_additional_headers/stl; \
for i in $(srcdir)/../include/sap_additional_headers/stl/*.h; do \
$(INSTALL_DATA) $$i $(DESTDIR)$(tooldir)/include/sap_additional_headers/stl/`basename $$i`; \
done;