Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans-Peter Nilsson <hp@axis.com>2005-02-02 00:22:33 +0300
committerHans-Peter Nilsson <hp@axis.com>2005-02-02 00:22:33 +0300
commita79f7ee05871b2ea3b23229f2003844d605f64ce (patch)
tree99c3609c4e1f841f399d0906d3c780f8e46fa3b6 /libgloss/cris
parent8c96f3fac27c13fa178f927753aaba3beed62209 (diff)
* cris/Makefile.in (ALL_INSTALL_FILES): New macro.
(ALL_INSTALL_FILES_NEWLIB_COPY): New macro. (all): Use ALL_INSTALL_FILES instead of its contents. Add ALL_INSTALL_FILES_NEWLIB_COPY. ($(objroot)/newlib/%, $(objroot)/newlib/libnosys.a): New rules
Diffstat (limited to 'libgloss/cris')
-rw-r--r--libgloss/cris/Makefile.in27
1 files changed, 25 insertions, 2 deletions
diff --git a/libgloss/cris/Makefile.in b/libgloss/cris/Makefile.in
index bab9ae7ae..ca3ec3804 100644
--- a/libgloss/cris/Makefile.in
+++ b/libgloss/cris/Makefile.in
@@ -91,14 +91,21 @@ BSP_SCRIPTS =
BSP_TEST =
BSP_INSTALL = install-bsp
+ALL_INSTALL_FILES = \
+ ${SIM_CRT0} ${SIM_EXTRA} ${SIM_BSP} \
+ ${LIN_CRT0} ${LIN_EXTRA} ${LIN_BSP} \
+ ${BSP_CRT0} ${BSP_EXTRA} ${BSP_BSP}
+
+ALL_INSTALL_FILES_NEWLIB_COPY = \
+ $(sort ${ALL_INSTALL_FILES:%=$(objroot)/newlib/%}) $(objroot)/newlib/libnosys.a
+
# Host specific makefile fragment comes in here.
@host_makefile_frag@
# Need to augment the definition from host_makefile_frag above.
INCLUDES += -I$(srcdir)
-all: ${SIM_CRT0} ${LIN_CRT0} ${BSP_CRT0} ${SIM_BSP} ${LIN_BSP} ${BSP_BSP} \
- libnosys.a ${LIN_EXTRA}
+all: ${ALL_INSTALL_FILES} ${ALL_INSTALL_FILES_NEWLIB_COPY} libnosys.a
#
# Here's where we build the board support packages for each target.
@@ -122,6 +129,22 @@ ${LIN_BSP}: ${LIN_OBJS}
libnosys.a:
ln -s ../libnosys/libnosys.a
+# Toplevel build rules for various other libraries have gcc -B options
+# applied so the newlib build directory is reached, but not the target
+# libgloss directory (whose name is unknown to the toplevel configury
+# anyway). Configury tests that check for a successful link therefore
+# fail; they can't find crt0.o and non-libc.a+libm.a libraries. We copy
+# over all files we would install to the neighboring newlib directory.
+# Only the default crt0.o and libraries are needed, but we do them all for
+# completeness. They're however installed from here, not from the newlib
+# build directory.
+$(objroot)/newlib/%: %
+ cp -p $^ $@
+
+# This rule, being more specific, overrides the pattern rule above.
+$(objroot)/newlib/libnosys.a:
+ ln -s ../libgloss/libnosys/libnosys.a $(objroot)/newlib
+
#
# Build a test program for each target board. Just trying to get
# it to link is a good test, so we ignore all the errors for now.