]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - sim/h8300/Makefile.in
Allow srcdir builds
[thirdparty/binutils-gdb.git] / sim / h8300 / Makefile.in
1 # Makefile template for Configure for the h8300sim library.
2 # Copyright (C) 1990, 1991, 1992 Free Software Foundation, Inc.
3 # Written by Cygnus Support.
4 #
5 # This program is free software; you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation; either version 2 of the License, or
8 # (at your option) any later version.
9 #
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
14 #
15 # You should have received a copy of the GNU General Public License
16 # along with this program; if not, write to the Free Software
17 # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
18
19 srcdir = .
20
21 prefix = /usr/local
22
23 exec_prefix = $(prefix)
24 bindir = $(exec_prefix)/bin
25 libdir = $(exec_prefix)/lib
26
27 datadir = $(prefix)/lib
28 mandir = $(prefix)/man
29 man1dir = $(mandir)/man1
30 man2dir = $(mandir)/man2
31 man3dir = $(mandir)/man3
32 man4dir = $(mandir)/man4
33 man5dir = $(mandir)/man5
34 man6dir = $(mandir)/man6
35 man7dir = $(mandir)/man7
36 man8dir = $(mandir)/man8
37 man9dir = $(mandir)/man9
38 infodir = $(prefix)/info
39 includedir = $(prefix)/include
40 oldincludedir =
41 docdir = $(srcdir)/doc
42
43 SHELL = /bin/sh
44
45 INSTALL = install -c
46 INSTALL_PROGRAM = $(INSTALL)
47 INSTALL_DATA = $(INSTALL)
48
49 AR = ar
50 AR_FLAGS = qc
51 CFLAGS = -g
52 BISON = bison
53 MAKEINFO = makeinfo
54 RANLIB = ranlib
55
56 INCDIR = $(srcdir)/../include
57 CSEARCH = -I. -I$(srcdir) -I$(INCDIR) -I$(srcdir)/../bfd
58 DEP = mkdep
59
60
61 TARGETLIB = libsim.a
62
63 run: code.o run.o
64 cc -o run code.o run.o ../bfd/libbfd.a ../libiberty/libiberty.a
65
66 code.c:p1.c p2.c p3.c
67 cat $(VPATH)/p1.c p2.c $(VPATH)/p3.c | cb >code.c
68 indent code.c
69
70 p2.c:writecode
71 ./writecode >p2.c
72
73
74 writecode:writecode.o
75
76 writecode.o:writecode.c
77 cc -g $(CSEARCH) -c $(VPATH)/writecode.c
78
79
80
81
82
83 #### host and target dependent Makefile fragments come in here.
84 ###
85
86 FLAGS_TO_PASS = \
87 "against=$(against)" \
88 "AR=$(AR)" \
89 "AR_FLAGS=$(AR_FLAGS)" \
90 "CC=$(CC)" \
91 "CFLAGS=$(CFLAGS)" \
92 "RANLIB=$(RANLIB)" \
93 "MAKEINFO=$(MAKEINFO)" \
94 "INSTALL=$(INSTALL)" \
95 "INSTALL_DATA=$(INSTALL_DATA)" \
96 "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
97 "BISON=$(BISON)"
98
99 .c.o:
100 $(CC) -c $(CFLAGS) $(HDEFINES) $(TDEFINES) $(CSEARCH) $(CSWITCHES) $<
101
102
103 # C source files that correspond to .o's.
104 CFILES = z8k-dis.c
105
106 STAGESTUFF = $(TARGETLIB) $(OFILES)
107
108 all: $(TARGETLIB)
109
110
111 .NOEXPORT:
112
113 check:
114
115 info:
116 clean-info:
117 install-info:
118
119 # HDEPFILES comes from the host config; TDEPFILES from the target config.
120
121
122 $(TARGETLIB): $(OFILES)
123 rm -f $(TARGETLIB)
124 $(AR) $(AR_FLAGS) $(TARGETLIB) $(OFILES)
125 $(RANLIB) $(TARGETLIB)
126
127 # Circumvent Sun Make bug with VPATH.
128 sparc-opc.o: sparc-opc.c
129
130 tags etags: TAGS
131
132 TAGS: force
133 etags $(INCDIR)/*.h $(srcdir)/*.h $(srcdir)/*.c
134
135 clean:
136 rm -f *.[oa] *~ core *.E *.p *.ip aout-params.h gen-aout
137
138 clobber realclean: clean
139 rm -f libbfd.a TAGS
140
141 # Mark everything as depending on config.status, since the timestamp on
142 # sysdep.h might actually move backwards if we reconfig and relink it
143 # to a different hosts/h-xxx.h file. This will force a recompile anyway.
144 RECONFIG = config.status
145
146
147
148 # This target should be invoked before building a new release.
149 # 'VERSION' file must be present and contain a string of the form "x.y"
150 #
151 roll:
152 @V=`cat VERSION` ; \
153 MAJ=`sed 's/\..*//' VERSION` ; \
154 MIN=`sed 's/.*\.//' VERSION` ; \
155 V=$$MAJ.`expr $$MIN + 1` ; \
156 rm -f VERSION ; \
157 echo $$V >VERSION ; \
158 echo Version $$V
159
160 # Dummy target to force execution of dependent targets.
161 #
162 force:
163
164 install:
165 -parent=`echo $(bindir)|sed -e 's@/[^/]*$$@@'`; \
166 if [ -d $$parent ] ; then true ; else mkdir $$parent ; fi
167 -if [ -d $(bindir) ] ; then true ; else mkdir $(bindir) ; fi
168 -parent=`echo $(man1dir)|sed -e 's@/[^/]*$$@@'`; \
169 if [ -d $$parent ] ; then true ; else mkdir $$parent ; fi
170 -if [ -d $(man1dir) ] ; then true ; else mkdir $(man1dir) ; fi
171 -n=`t='$(program_transform_name)'; echo run | sed -e "" $$t`; \
172 $(INSTALL_PROGRAM) run $(bindir)/$$n; \
173 $(M_INSTALL)
174
175
176
177 Makefile: $(srcdir)/Makefile.in $(host_makefile_frag) $(target_makefile_frag)
178 $(SHELL) ./config.status
179
180 dep: $(CFILES)
181 mkdep $(CFLAGS) $?
182
183
184 # What appears below is generated by a hacked mkdep using gcc -MM.
185
186 # DO NOT DELETE THIS LINE -- mkdep uses it.
187 # DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.
188
189
190 # IF YOU PUT ANYTHING HERE IT WILL GO AWAY
191