* Makefile.in: added coff-h8300
[deliverable/binutils-gdb.git] / bfd / Makefile.in
1 # Makefile template for Configure for the BFD library.
2 # Copyright (C) 1990, 1991 Free Software Foundation, Inc.
3 # Written by Cygnus Support.
4 #
5 # This file is part of BFD, the Binary File Descriptor library.
6 #
7 # This program is free software; you can redistribute it and/or modify
8 # it under the terms of the GNU General Public License as published by
9 # the Free Software Foundation; either version 2 of the License, or
10 # (at your option) any later version.
11 #
12 # This program is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 # GNU General Public License for more details.
16 #
17 # You should have received a copy of the GNU General Public License
18 # along with this program; if not, write to the Free Software
19 # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
20
21 # $Id$
22
23 srcdir = .
24 ddestdir = /usr/local
25 libdir = $(ddestdir)/lib
26 docdir = $(srcdir)$(subdir)/doc
27 includedir= $(ddestdir)/include
28 RANLIB = ranlib
29 AR = ar
30 AR_FLAGS = clq
31 INCDIR = $(srcdir)/../include
32 CSEARCH = -I. -I$(srcdir) -I$(INCDIR)
33 DEP = mkdep
34 MINUS_G=-g
35
36 SUBDIRS = doc
37
38 #### host and target dependent Makefile fragments come in here.
39 ###
40
41 # Change this (to MINIMIZE=1) to save space in executables.
42 # Currently, all this does is control the target_vector in targets.c.
43 MINIMIZE=0
44
45 TARGETLIB = libbfd.a
46 CFLAGS = $(MINUS_G) $(HDEFINES) $(TDEFINES) $(CSEARCH) $(CSWITCHES) # -DINTEL960VERSION
47
48
49 BFD_LIBS = libbfd.o opncls.o bfd.o archive.o targets.o cache.o \
50 archures.o core.o section.o format.o syms.o reloc.o init.o ctor.o
51
52 BFD_MACHINES = cpu-h8300.o cpu-i960.o cpu-sparc.o cpu-m68k.o cpu-m88k.o \
53 cpu-vax.o cpu-mips.o cpu-a29k.o cpu-i386.o cpu-rs6000.o
54
55 BFD_BACKENDS = oasys.o ieee.o srec.o elf.o stab-syms.o\
56 aout64.o aout32.o demo64.o sunos.o newsos3.o i386aout.o bout.o \
57 coff-i960.o coff-a29k.o coff-m68k.o coff-i386.o coff-m88k.o \
58 coff-mips.o coff-rs6000.o coff-h8300.o
59
60 OPTIONAL_BACKENDS = trad-core.o
61
62 BFD_H=$(INCDIR)/bfd.h
63
64 # C source files that correspond to .o's.
65 CFILES = libbfd.c opncls.c bfd.c archive.c targets.c cache.c archures.c \
66 coff-i386.c aout64.c aout32.c sunos.c demo64.c coff-i960.c srec.c \
67 oasys.c ieee.c coff-m68k.c coff-a29k.c coff-rs6000.c \
68 format.c section.c core.c syms.c stabs-syms.c reloc.c init.c ctor.c \
69 coff-m88k.c coff-mips.c trad-core.c newsos3.c i386aout.c bout.c elf.c \
70 cpu-h8300.c cpu-i960.c cpu-sparc.c cpu-m68k.c cpu-m88k.c \
71 cpu-vax.c cpu-mips.c cpu-a29k.c cpu-i386.c cpu-rs6000.c coff-h8300.c
72
73 STAGESTUFF = $(TARGETLIB) $(OFILES)
74
75 all: $(TARGETLIB)
76 $(MAKE) subdir_do DO=all "DODIRS=$(SUBDIRS)"
77
78 all-info: force
79 $(MAKE) subdir_do DO=all-info "DODIRS=$(SUBDIRS)"
80
81 install-info: force
82 $(MAKE) subdir_do DO=install-info "DODIRS=$(SUBDIRS)"
83
84 # HDEPFILES comes from the host config; TDEPFILES from the target config.
85 OFILES = $(BFD_LIBS) $(BFD_BACKENDS) $(BFD_MACHINES) $(HDEPFILES) $(TDEPFILES)
86
87 $(TARGETLIB): $(OFILES)
88 rm -f $(TARGETLIB)
89 $(AR) $(AR_FLAGS) $(TARGETLIB) $(OFILES)
90 $(RANLIB) $(TARGETLIB)
91
92 # When compiling targets.c, supply the default target info from configure.
93 targets.o: targets.c
94 $(CC) $(CFLAGS) -c -DMINIMIZE=$(MINIMIZE) $(TDEFAULTS) $<
95
96 subdir_do: force
97 for i in $(DODIRS); do \
98 if [ -d $(unsubdir)/$$i ] ; then \
99 if (cd $(unsubdir)/$$i$(subdir); \
100 $(MAKE) \
101 "against=$(against)" \
102 "AR=$(AR)" \
103 "CC=$(CC)" \
104 "AR_FLAGS=$(AR_FLAGS)" \
105 "RANLIB=$(RANLIB)" \
106 "BISON=$(BISON)" $(DO)) ; then true ; \
107 else exit 1 ; fi ; \
108 else true ; fi ; \
109 done
110
111 stage1: force
112 - mkdir stage1
113 - mv -f $(STAGESTUFF) stage1
114 $(MAKE) subdir_do DO=stage1 "DODIRS=$(SUBDIRS)"
115
116 stage2: force
117 - mkdir stage2
118 - mv -f $(STAGESTUFF) stage2
119 $(MAKE) subdir_do DO=stage2 "DODIRS=$(SUBDIRS)"
120
121 stage3: force
122 - mkdir stage3
123 - mv -f $(STAGESTUFF) stage3
124 $(MAKE) subdir_do DO=stage3 "DODIRS=$(SUBDIRS)"
125
126 against=stage2
127
128 comparison: force
129 for i in *.o ; do cmp $$i $(against)/$$i || exit 1 ; done
130 $(MAKE) subdir_do DO=comparison "DODIRS=$(SUBDIRS)"
131
132 de-stage1: force
133 - (cd stage1 ; mv -f $(STAGESTUFF) ..)
134 - rmdir stage1
135 $(MAKE) subdir_do DO=de-stage1 "DODIRS=$(SUBDIRS)"
136
137 de-stage2: force
138 - (cd stage2 ; mv -f $(STAGESTUFF) ..)
139 - rmdir stage2
140 $(MAKE) subdir_do DO=de-stage2 "DODIRS=$(SUBDIRS)"
141
142 de-stage3: force
143 - (cd stage3 ; mv -f $(STAGESTUFF) ..)
144 - rmdir stage3
145 $(MAKE) subdir_do DO=de-stage3 "DODIRS=$(SUBDIRS)"
146
147 tags etags: TAGS
148
149 TAGS: force
150 etags $(INCDIR)/*.h $(srcdir)/*.h $(srcdir)/*.c
151
152 clean:
153 rm -f *.[oa] *~ core *.E *.p *.ip
154 $(MAKE) subdir_do DO=clean "DODIRS=$(SUBDIRS)"
155
156 clobber realclean: clean
157 rm -f libbfd.a TAGS
158 $(MAKE) subdir_do DO=clobber "DODIRS=$(SUBDIRS)"
159
160 # Mark everything as depending on config.status, since the timestamp on
161 # sysdep.h might actually move backwards if we reconfig and relink it
162 # to a different hosts/h-xxx.h file. This will force a recompile anyway.
163 RECONFIG = config.status
164 $(BFD_LIBS): libbfd.h $(BFD_H) $(RECONFIG)
165 $(BFD_MACHINES): libbfd.h $(BFD_H) $(RECONFIG)
166 $(BFD_BACKENDS): libbfd.h $(BFD_H) $(RECONFIG)
167 $(OPTIONAL_BACKENDS): libbfd.h $(BFD_H) $(RECONFIG)
168
169 # Get around a Sun Make bug in SunOS 4.1.1 with VPATH
170 cpu-i386.o:cpu-i386.c
171
172 saber:
173 #suppress 65 on bfd_map_over_sections
174 #suppress 66 on bfd_map_over_sections
175 #suppress 67 on bfd_map_over_sections
176 #suppress 68 on bfd_map_over_sections
177 #suppress 69 on bfd_map_over_sections
178 #suppress 70 on bfd_map_over_sections
179 #suppress 110 in bfd_map_over_sections
180 #suppress 112 in bfd_map_over_sections
181 #suppress 530
182 #suppress 590 in swap_exec_header
183 #suppress 590 in _bfd_dummy_core_file_matches_executable_p
184 #suppress 590 in bfd_dont_truncate_arname
185 #suppress 590 on ignore
186 #suppress 590 on abfd
187 #setopt load_flags $(CFLAGS)
188 #load $(CFILES)
189
190
191 #-----------------------------------------------------------------------------
192 # 'STANDARD' GNU/960 TARGETS BELOW THIS POINT
193 #
194 # 'VERSION' file must be present and contain a string of the form "x.y"
195 #-----------------------------------------------------------------------------
196
197 ver960.c: FORCE
198 rm -f ver960.c
199 echo "char ${TARG}_ver[]= \"${TARG} `cat VERSION`, `date`\";" > ver960.c
200
201
202 # This target should be invoked before building a new release.
203 # 'VERSION' file must be present and contain a string of the form "x.y"
204 #
205 roll:
206 @V=`cat VERSION` ; \
207 MAJ=`sed 's/\..*//' VERSION` ; \
208 MIN=`sed 's/.*\.//' VERSION` ; \
209 V=$$MAJ.`expr $$MIN + 1` ; \
210 rm -f VERSION ; \
211 echo $$V >VERSION ; \
212 echo Version $$V
213
214 # Dummy target to force execution of dependent targets.
215 #
216 force:
217
218 install:
219 cp libbfd.a $(libdir)/libbfd.a.new
220 $(RANLIB) $(libdir)/libbfd.a.new
221 mv -f $(libdir)/libbfd.a.new $(libdir)/libbfd.a
222 cp $(INCDIR)/bfd.h $(includedir)/bfd.h
223 $(MAKE) subdir_do DO=install "DODIRS=$(SUBDIRS)"
224
225 # Target to uncomment host-specific lines in this makefile. Such lines must
226 # have the following string beginning in column 1: #__<hostname>__#
227 # Original Makefile is backed up as 'Makefile.old'.
228 #
229 # Invoke with: make make HOST=xxx
230 #
231 make:
232 -@if test $(HOST)x = x ; then \
233 echo '\aSpecify "make make HOST=???"'; \
234 exit 1; \
235 fi ; \
236 grep -s "^#The next line was generated by 'make make'" Makefile; \
237 if test $$? = 0 ; then \
238 echo "\aMakefile has already been processed with 'make make'";\
239 exit 1; \
240 fi ; \
241 mv -f Makefile Makefile.old; \
242 echo "#The next line was generated by 'make make'" >Makefile ; \
243 echo "HOST=$(HOST)" >>Makefile ; \
244 echo >>Makefile ; \
245 sed "s/^#__$(HOST)__#//" < Makefile.old >>Makefile
246
247 Makefile: $(srcdir)/Makefile.in $(host_makefile_frag) $(target_makefile_frag)
248 $(SHELL) ./config.status
249
250 dep: $(CFILES)
251 mkdep $(CFLAGS) $?
252
253
254
255 headers:
256 (cd $(docdir); $(MAKE) protos)
257 # Rebuild prototypes in bfd.h
258 cp $(docdir)/bfd.h $(BFD_H)
259 cp $(docdir)/libbfd.h $(srcdir)/libbfd.h
260 cp $(docdir)/libcoff.h $(srcdir)/libcoff.h
261
262 bfd.info:
263 ( cd $(docdir); $(MAKE) bfd.info)
264
265 bfd.dvi:
266 (cd $(docdir); $(MAKE) bfd.dvi)
267
268 bfd.ps:
269 (cd $(docdir); $(MAKE) bfd.ps)
270
271 # What appears below is generated by a hacked mkdep using gcc -MM.
272
273 # DO NOT DELETE THIS LINE -- mkdep uses it.
274 # DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.
275
276 libbfd.o : libbfd.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h
277 opncls.o : opncls.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h
278 bfd.o : bfd.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h
279 archive.o : archive.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h \
280 $(INCDIR)/ar.h $(INCDIR)/ranlib.h
281 targets.o : targets.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h
282 cache.o : cache.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h
283 archures.o : archures.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h
284 aout64.o : aout64.c
285 aout32.o : aout32.c aoutx.h $(INCDIR)/bfd.h $(INCDIR)/ansidecl.h \
286 $(INCDIR)/obstack.h libaout.h libbfd.h $(INCDIR)/aout64.h \
287 $(INCDIR)/stab.gnu.h $(INCDIR)/stab.def $(INCDIR)/ar.h
288 sunos.o : sunos.c aoutf1.h $(INCDIR)/bfd.h $(INCDIR)/obstack.h \
289 libaout.h libbfd.h $(INCDIR)/aout64.h $(INCDIR)/stab.gnu.h \
290 $(INCDIR)/stab.def $(INCDIR)/ar.h
291 demo64.o : demo64.c
292
293 srec.o : srec.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h
294 oasys.o : oasys.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h \
295 $(INCDIR)/oasys.h liboasys.h
296 ieee.o : ieee.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h \
297 $(INCDIR)/ieee.h libieee.h
298 coff-h8300.o: coff-h8300.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h \
299 $(INCDIR)/coff-h8300.h $(INCDIR)/internalcoff.h libcoff.h coffcode.h
300 format.o : format.c $(INCDIR)/bfd.h \
301 $(INCDIR)/obstack.h libbfd.h
302 section.o : section.c $(INCDIR)/bfd.h \
303 $(INCDIR)/obstack.h libbfd.h
304 core.o : core.c $(INCDIR)/bfd.h \
305 $(INCDIR)/obstack.h libbfd.h
306 syms.o : syms.c $(INCDIR)/bfd.h \
307 $(INCDIR)/obstack.h libbfd.h
308 syms.o : stab-syms.c
309 reloc.o : reloc.c $(INCDIR)/bfd.h \
310 $(INCDIR)/obstack.h libbfd.h
311
312 trad-core.o : trad-core.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h \
313 libbfd.h libaout.h
314 newsos3.o : newsos3.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h \
315 $(INCDIR)/aout64.h $(INCDIR)/stab.gnu.h $(INCDIR)/stab.def \
316 $(INCDIR)/ar.h libaout.h
317 i386aout.o : i386aout.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h \
318 $(INCDIR)/aout64.h $(INCDIR)/stab.gnu.h $(INCDIR)/stab.def \
319 $(INCDIR)/ar.h libaout.h
320 bout.o : bout.c $(INCDIR)/bfd.h $(INCDIR)/obstack.h libbfd.h \
321 $(INCDIR)/bout.h $(INCDIR)/stab.gnu.h $(INCDIR)/stab.def libaout.h
322
323 # IF YOU PUT ANYTHING HERE IT WILL GO AWAY
324
This page took 0.03792 seconds and 4 git commands to generate.