source: trunk/libs/newlib/src/libgloss/moxie/Makefile.in @ 678

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

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

File size: 3.8 KB
Line 
1# Copyright (c) 2008, 2010 Anthony Green
2#
3# The authors hereby grant permission to use, copy, modify, distribute,
4# and license this software and its documentation for any purpose, provided
5# that existing copyright notices are retained in all copies and that this
6# notice is included verbatim in any distributions. No written agreement,
7# license, or royalty fee is required for any of the authorized uses.
8# Modifications to this software may be copyrighted by their authors
9# and need not follow the licensing terms described here, provided that
10# the new terms are clearly indicated on the first page of each file where
11# they apply.
12
13# Makefile for libgloss/spro. This is the board support code for the
14# moxie target.
15
16DESTDIR =
17VPATH = @srcdir@ @srcdir@/..
18srcdir = @srcdir@
19objdir = .
20srcroot = $(srcdir)/../..
21objroot = $(objdir)/../..
22
23prefix = @prefix@
24exec_prefix = @exec_prefix@
25
26host_alias = @host_alias@
27target_alias = @target_alias@
28
29bindir = @bindir@
30libdir = @libdir@
31tooldir = $(exec_prefix)/$(target_alias)
32
33# Multilib support variables.
34# TOP is used instead of MULTI{BUILD,SRC}TOP.
35MULTIDIRS =
36MULTISUBDIR =
37MULTIDO = true
38MULTICLEAN = true
39
40INSTALL = @INSTALL@
41INSTALL_PROGRAM = @INSTALL_PROGRAM@
42INSTALL_DATA = @INSTALL_DATA@
43
44SHELL = /bin/sh
45
46CC = @CC@
47
48AS = @AS@
49AR = @AR@
50LD = @LD@
51RANLIB = @RANLIB@
52AR_FLAGS = rc
53
54OBJDUMP = `if [ -f ${objroot}/../binutils/objdump ] ; \
55        then echo ${objroot}/../binutils/objdump ; \
56        else t='$(program_transform_name)'; echo objdump | sed -e $$t ; fi`
57OBJCOPY = `if [ -f ${objroot}/../binutils/objcopy ] ; \
58        then echo ${objroot}/../binutils/objcopy ; \
59        else t='$(program_transform_name)'; echo objcopy | sed -e $$t ; fi`
60
61LD_SCRIPTS = moxie-elf-common.ld qemu.ld sim.ld moxiebox.ld
62
63@BUILD_CRT0_TRUE@CRT0           = crt0.o
64@BUILD_CRT0_TRUE@CRT0_INSTALL   = install-crt0
65@BUILD_CRT0_FALSE@CRT0          =
66@BUILD_CRT0_FALSE@CRT0_INSTALL  =
67
68SIM_BSP = libsim.a
69SIM_OBJS = fstat.o \
70           getpid.o \
71           isatty.o \
72           kill.o \
73           putnum.o \
74           sbrk.o \
75           sim-close.o \
76           sim-exit.o \
77           sim-inbyte.o \
78           sim-lseek.o \
79           sim-open.o \
80           sim-read.o \
81           sim-time.o \
82           sim-unlink.o \
83           sim-write.o \
84           stat.o
85
86QEMU_BSP = libqemu.a
87QEMU_OBJS = qemu-write.o \
88            qemu-time.o \
89            sim-exit.o \
90            sbrk.o \
91            sim-close.o \
92            fstat.o \
93            getpid.o \
94            isatty.o \
95            kill.o \
96            putnum.o \
97            sim-lseek.o \
98            sim-read.o
99
100#### Host specific Makefile fragment comes in here.
101@host_makefile_frag@
102
103all: ${CRT0} $(SIM_BSP) $(QEMU_BSP)
104
105$(SIM_BSP): $(SIM_OBJS)
106        $(AR) $(ARFLAGS) $@ $?
107        $(RANLIB) $@
108
109$(QEMU_BSP): $(QEMU_OBJS)
110        $(AR) $(ARFLAGS) $@ $?
111        $(RANLIB) $@
112
113fstat.o: $(srcdir)/fstat.c
114getpid.o: $(srcdir)/getpid.c
115isatty.o: $(srcdir)/isatty.c
116kill.o: $(srcdir)/kill.c
117putnum.o: $(srcdir)/putnum.c
118sbrk.o: $(srcdir)/sbrk.c
119sim-close.o: $(srcdir)/sim-close.S
120sim-exit.o: $(srcdir)/sim-exit.S
121sim-inbyte.o: $(srcdir)/sim-inbyte.c
122sim-lseek.o: $(srcdir)/sim-lseek.c
123sim-open.o: $(srcdir)/sim-open.S
124sim-read.o: $(srcdir)/sim-read.S
125sim-time.o: $(srcdir)/sim-time.c
126sim-unlink.o: $(srcdir)/sim-unlink.S
127sim-write.o: $(srcdir)/sim-write.S
128stat.o: $(srcdir)/stat.c
129qemu-write.o: $(srcdir)/qemu-write.c
130
131install: ${CRT0_INSTALL} $($(CPU)_INSTALL)
132        $(INSTALL_DATA) $(SIM_BSP) $(DESTDIR)$(tooldir)/lib${MULTISUBDIR}/$(SIM_BSP)
133        $(INSTALL_DATA) $(QEMU_BSP) $(DESTDIR)$(tooldir)/lib${MULTISUBDIR}/$(QEMU_BSP)
134        for x in ${LD_SCRIPTS}; do \
135          ${INSTALL_DATA} ${srcdir}/$$x $(DESTDIR)${tooldir}/lib/$$x; \
136        done;
137
138install-crt0:
139        ${INSTALL_DATA} ${CRT0} $(DESTDIR)${tooldir}/lib${MULTISUBDIR}/$$x
140
141clean mostlyclean:
142        rm -f *.o *.a
143
144distclean maintainer-clean realclean: clean
145        rm -f Makefile config.cache config.log config.status
146
147.PHONY: info dvi doc install-info clean-info
148info doc dvi:
149install-info:
150clean-info:
151
152Makefile: Makefile.in config.status @host_makefile_frag_path@
153        $(SHELL) config.status
154
155config.status: configure
156        $(SHELL) config.status --recheck
Note: See TracBrowser for help on using the repository browser.