Adding directories to the newlib build
J. Johnston
jjohnstn@redhat.com
Fri Feb 28 23:41:00 GMT 2003
Craig A. Vanderborgh wrote:
> Hello All:
>
> I am finishing up ARM/Wince 3.0 support for newlib and I need to add
> some directories under my "wince" subdirectory for additional header
> files and directories. For example, in addition to my own system header
> files for wince being put into INSTALLDIR/include/sys, I need the build
> to install some additional files and directories when the newlib build
> is performed, e.g. INSTALLDIR/include/netinet/in.h
>
> What is the correct way to get the automake regime to do this, i.e. what
> do I need to add to the Makefile hierarchy and where do I need to put
> it? Please advise as the automake stuff is really giving me headaches
> right now!!
>
You want to use the "install-data-local" tag to do this. Since these header files
are only for your configuration, they should be in your specific sys
directory. For example, if you have added a libc/sys/wince directory, you could
add a libc/sys/wince/netinet subdirectory which has your header files in it and add
the following to its Makefile.am:
install-data-local:
$(mkinstalldirs) $(DESTDIR)$(tooldir)/include/netinet; \
for i in $(srcdir)/netinet/*.h; do \
$(INSTALL_DATA) $$i $(DESTDIR)$(tooldir)/include/netinet/`basename $$i`;
You then have to regenerate the Makefile.in via: automake --cygnus Makefile
You can add to this if you have other header files that install into subdirectories
other than sys or machine.
I am assuming that you always want to install these header files. If that is not
the case, then let me know what the circumstances are and I will show you how to
handle it via configuration.
-- Jeff J.
More information about the Newlib
mailing list