source: trunk/libs/newlib/src/libgloss/microblaze/Makefile.in @ 546

Last change on this file since 546 was 444, checked in by satin@…, 6 years ago

add newlib,libalmos-mkh, restructure shared_syscalls.h and mini-libc

File size: 4.6 KB
Line 
1#  Copyright 2007, 2009 Xilinx, Inc.  All rights reserved.
2
3#  Redistribution and use in source and binary forms, with or without
4#  modification, are permitted provided that the following conditions are
5#  met:
6
7#  1.  Redistributions source code must retain the above copyright notice,
8#  this list of conditions and the following disclaimer.
9
10#  2.  Redistributions in binary form must reproduce the above copyright
11#  notice, this list of conditions and the following disclaimer in the
12#  documentation and/or other materials provided with the distribution.
13
14#  3.  Neither the name of Xilinx nor the names of its contributors may be
15#  used to endorse or promote products derived from this software without
16#  specific prior written permission.
17
18#  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS
19#  IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
20#  TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
21#  PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
22#  HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
23#  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
24#  TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
25#  PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
26#  LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
27#  NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28#  SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29
30# Makefile for libgloss/microblaze. This is the board support
31# code for the various microblaze targets.
32
33DESTDIR =
34VPATH = @srcdir@
35srcdir = @srcdir@
36objdir = .
37srcroot = $(srcdir)/../..
38objroot = $(objdir)/../..
39
40prefix = @prefix@
41exec_prefix = @exec_prefix@
42
43host_alias = @host_alias@
44target_alias = @target_alias@
45
46bindir = @bindir@
47libdir = @libdir@
48tooldir = $(exec_prefix)/$(target_alias)
49
50# Multilib support variables.
51# TOP is used instead of MULTI{BUILD,SRC}TOP.
52MULTIDIRS =
53MULTISUBDIR =
54MULTIDO = true
55MULTICLEAN = true
56
57INSTALL = @INSTALL@
58INSTALL_PROGRAM = @INSTALL_PROGRAM@
59INSTALL_DATA = @INSTALL_DATA@
60
61SHELL = /bin/sh
62
63CC = @CC@
64
65AS = @AS@
66AR = @AR@
67LD = @LD@
68RANLIB = @RANLIB@
69AR_FLAGS = qrv
70
71OBJDUMP = `if [ -f ${objroot}/../binutils/objdump ] ; \
72        then echo ${objroot}/../binutils/objdump ; \
73        else t='$(program_transform_name)'; echo objdump | sed -e $$t ; fi`
74OBJCOPY = `if [ -f ${objroot}/../binutils/objcopy ] ; \
75        then echo ${objroot}/../binutils/objcopy ; \
76        else t='$(program_transform_name)'; echo objcopy | sed -e $$t ; fi`
77
78CRT = crt0.o crt1.o crt2.o crt3.o crt4.o crtinit.o pgcrtinit.o sim-crtinit.o sim-pgcrtinit.o
79LIB = libgloss.a
80GENOBJS = fstat.o getpid.o isatty.o kill.o lseek.o print.o putnum.o stat.o unlink.o \
81          open.o close.o read.o write.o
82OBJS = ${GENOBJS} sbrk.o timer.o _exception_handler.o _hw_exception_handler.o \
83       _interrupt_handler.o _program_clean.o _program_init.o \
84       xil_malloc.o xil_sbrk.o xil_printf.o
85SCRIPTS = xilinx.ld
86
87# Tiny Linux BSP.
88LINUX_BSP     = libgloss-linux.a
89CRT          += linux-crt0.o
90LINUX_OBJS    = linux-syscalls.o linux-syscalls-wrap.o
91LINUX_OBJS   += linux-outbyte.o linux-inbyte.o
92LINUX_SCRIPTS = elf-gloss-linux.specs
93
94CPU = @CPU@
95
96#### Host specific Makefile fragment comes in here.
97@host_makefile_frag@
98
99all: ${CRT} ${LIB} ${LINUX_BSP}
100
101install: ${CRT} ${LIB} install-linux
102        @for crt in ${CRT}; do \
103        $(INSTALL_PROGRAM) $${crt} $(DESTDIR)$(tooldir)/lib${MULTISUBDIR}/$${crt}; \
104        done
105        $(INSTALL_PROGRAM) ${LIB} $(DESTDIR)$(tooldir)/lib${MULTISUBDIR}
106        $(INSTALL_PROGRAM) $(srcdir)/${SCRIPTS} $(DESTDIR)$(tooldir)/lib/
107
108install-linux: ${LINUX_BSP}
109        $(INSTALL_PROGRAM) ${LINUX_BSP} $(DESTDIR)$(tooldir)/lib${MULTISUBDIR}
110        set -e; for x in ${LINUX_SCRIPTS}; do ${INSTALL_DATA} ${srcdir}/${objtype}$$x $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x; done
111
112crt0.o: crt0.S
113crt1.o: crt1.S
114crt2.o: crt2.S
115crt3.o: crt3.S
116crt4.o: crt4.S
117linux-crt0.o: linux-crt0.S
118crtinit.o: crtinit.S
119sim-crtinit.o: sim-crtinit.S
120sim-pgcrtinit.o: sim-pgcrtinit.S
121
122# target specific makefile fragment comes in here.
123@target_makefile_frag@
124
125clean mostlyclean:
126        rm -f *.o *.a *.map *.x
127
128distclean maintainer-clean realclean: clean
129        rm -f Makefile config.cache config.log config.status
130
131${LIB}: ${OBJS}
132        ${AR} ${ARFLAGS} $@ ${OBJS}
133        ${RANLIB} $@
134
135${LINUX_BSP}: ${LINUX_OBJS}
136        ${AR} ${ARFLAGS} $@ ${LINUX_OBJS}
137        ${RANLIB} $@
138
139.PHONY: info dvi doc install-info clean-info
140info doc dvi:
141install-info:
142clean-info:
143
144Makefile: Makefile.in config.status @host_makefile_frag_path@ @target_makefile_frag_path@ \
145        $(SHELL) config.status
146
147config.status: configure
148        $(SHELL) config.status --recheck
Note: See TracBrowser for help on using the repository browser.