source: trunk/libs/newlib/src/libgloss/mep/Makefile.in @ 458

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

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

File size: 3.4 KB
RevLine 
[444]1# Copyright (c) 1999, 2001, 2003 Red Hat Inc
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/mep.  We only support the simulator at the
14# moment.
15
16VPATH = @srcdir@ @srcdir@/..
17srcdir = @srcdir@
18objdir = .
19srcroot = $(srcdir)/../..
20objroot = $(objdir)/../..
21
22prefix = @prefix@
23exec_prefix = @exec_prefix@
24
25host_alias = @host_alias@
26target_alias = @target_alias@
27
28bindir = @bindir@
29libdir = @libdir@
30tooldir = $(exec_prefix)/$(target_alias)
31
32# Multilib support variables.
33# TOP is used instead of MULTI{BUILD,SRC}TOP.
34MULTIDIRS =
35MULTISUBDIR =
36MULTIDO = true
37MULTICLEAN = true
38
39INSTALL = @INSTALL@
40INSTALL_PROGRAM = @INSTALL_PROGRAM@
41INSTALL_DATA = @INSTALL_DATA@
42
43SHELL = /bin/sh
44
45CC = @CC@
46
47AS = @AS@
48AR = @AR@
49LD = @LD@
50RANLIB = @RANLIB@
51AR_FLAGS = rc
52
53OBJDUMP = `if [ -f ${objroot}/../binutils/objdump ] ; \
54        then echo ${objroot}/../binutils/objdump ; \
55        else t='$(program_transform_name)'; echo objdump | sed -e $$t ; fi`
56OBJCOPY = `if [ -f ${objroot}/../binutils/objcopy ] ; \
57        then echo ${objroot}/../binutils/objcopy ; \
58        else t='$(program_transform_name)'; echo objcopy | sed -e $$t ; fi`
59
60SCRIPTS = min.ld default.ld
61CRT = crt0.o sdram-crt0.o sim-crt0.o simnovec-crt0.o simsdram-crt0.o crtn.o sim-crtn.o
62SIM_BSP = libsim.a
63LIBNOSYS = ../libnosys/libnosys.a
64SIM_OBJS = \
65        isatty.o \
66        sbrk.o \
67        syscalls.o \
68        mep-gmon.o \
69        mep-bb.o \
70        handlers.o \
71        h_reset.o \
72        read.o \
73        write.o
74
75#### Host specific Makefile fragment comes in here.
76@host_makefile_frag@
77
78
79# Override .S.o rule to pass assembler debugging flags
80.S.o:
81        $(CC) -Wa,-gdwarf2 -Wa,-I$(srcdir) $(CFLAGS_FOR_TARGET) $(INCLUDES) $(CFLAGS) -c $<
82
83all: $(CRT) $(SIM_BSP)
84
85$(SIM_BSP): $(SIM_OBJS)
86        $(AR) $(ARFLAGS) $@ $?
87        $(RANLIB) $@
88        $(AR) $(ARFLAGS) $(LIBNOSYS) handlers.o h_reset.o
89        $(RANLIB) $(LIBNOSYS)
90
91syscalls.o: $(srcdir)/syscalls.S
92sbrk.o: $(srcdir)/sbrk.c
93crt0.o: $(srcdir)/crt0.S $(srcdir)/sim-crt0.S
94sdram-crt0.o: $(srcdir)/sdram-crt0.S $(srcdir)/sim-crt0.S
95sim-crt0.o: $(srcdir)/sim-crt0.S
96simsdram-crt0.o: $(srcdir)/simsdram-crt0.S $(srcdir)/sim-crt0.S
97simnovec-crt0.o: $(srcdir)/simnovec-crt0.S $(srcdir)/sim-crt0.S
98crtn.o: $(srcdir)/crtn.S $(srcdir)/sim-crtn.S
99
100install: $(CRT) $(SIM_BSP)
101        for c in $(CRT) $(SIM_BSP); do \
102          $(INSTALL_DATA) $$c $(DESTDIR)$(tooldir)/lib${MULTISUBDIR}/$$c ;\
103        done
104        if test -z "$(MULTISUBDIR)"; then \
105          for c in $(SCRIPTS); do \
106            $(INSTALL_DATA) $(srcdir)/$$c $(DESTDIR)$(tooldir)/lib${MULTISUBDIR}/$$c ;\
107          done; \
108          $(INSTALL_DATA) $(srcdir)/gmap_default.ld $(DESTDIR)$(tooldir)/lib/gmap_default.tmpl; \
109        else true; fi
110
111clean mostlyclean:
112        rm -f *.o *.a
113
114distclean maintainer-clean realclean: clean
115        rm -f Makefile config.cache config.log config.status
116
117.PHONY: info dvi doc install-info clean-info
118info doc dvi:
119install-info:
120clean-info:
121
122Makefile: Makefile.in config.status @host_makefile_frag_path@
123        $(SHELL) config.status
124
125config.status: configure
126        $(SHELL) config.status --recheck
Note: See TracBrowser for help on using the repository browser.