Commit | Line | Data |
---|---|---|
eb02fd64 | 1 | # |
131a3881 | 2 | # Makefile for directory with subdirs to build. |
2e482734 | 3 | # Copyright (C) 1990, 91, 92, 93, 94, 95, 96, 1997 Free Software Foundation |
eb02fd64 | 4 | # |
4dfe09da RP |
5 | # This file 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 | |
8c222f6e | 17 | # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
4dfe09da | 18 | # |
f149eb99 | 19 | |
eb02fd64 | 20 | srcdir = . |
28f3b094 | 21 | |
4d714963 | 22 | prefix = /usr/local |
eb02fd64 | 23 | |
7fcfdcf7 SC |
24 | exec_prefix = $(prefix) |
25 | bindir = $(exec_prefix)/bin | |
26 | libdir = $(exec_prefix)/lib | |
a54e05f6 | 27 | tooldir = $(exec_prefix)/$(target) |
7fcfdcf7 | 28 | |
51489233 ILT |
29 | program_transform_name = |
30 | ||
d92eef0c | 31 | datadir = $(prefix)/share |
7fcfdcf7 | 32 | mandir = $(prefix)/man |
4d714963 RP |
33 | man1dir = $(mandir)/man1 |
34 | man2dir = $(mandir)/man2 | |
35 | man3dir = $(mandir)/man3 | |
36 | man4dir = $(mandir)/man4 | |
37 | man5dir = $(mandir)/man5 | |
38 | man6dir = $(mandir)/man6 | |
39 | man7dir = $(mandir)/man7 | |
40 | man8dir = $(mandir)/man8 | |
41 | man9dir = $(mandir)/man9 | |
7fcfdcf7 | 42 | infodir = $(prefix)/info |
4d714963 | 43 | includedir = $(prefix)/include |
04103845 | 44 | GDB_NLM_DEPS = |
4d714963 RP |
45 | |
46 | SHELL = /bin/sh | |
47 | ||
64434418 | 48 | INSTALL = $(SHELL) $$s/install-sh -c |
4d714963 | 49 | INSTALL_PROGRAM = $(INSTALL) |
5cc73086 | 50 | INSTALL_DATA = $(INSTALL) -m 644 |
3c8735af | 51 | |
09985c96 | 52 | INSTALL_DOSREL = install-dosrel-fake |
a987271c | 53 | |
440868a0 | 54 | AS = as |
ec342d7d | 55 | AR = ar |
b5329d84 | 56 | AR_FLAGS = rc |
e85e07cb | 57 | CC = cc |
7b636683 | 58 | |
66957ce4 ILT |
59 | # Special variables passed down in EXTRA_GCC_FLAGS. They are defined |
60 | # here so that they can be overridden by Makefile fragments. | |
753d5049 SC |
61 | HOST_CC = $(CC_FOR_BUILD) |
62 | HOST_PREFIX = | |
63 | HOST_PREFIX_1 = loser- | |
64 | ||
7b636683 JK |
65 | # We don't specify -g -O because many compilers don't support -g -O, |
66 | # and/or -O is broken in and of itself. | |
f8a6ad66 | 67 | CFLAGS = -g |
3585593d BK |
68 | LIBCFLAGS = $(CFLAGS) |
69 | CFLAGS_FOR_TARGET = $(CFLAGS) | |
276c2d7d | 70 | LDFLAGS_FOR_TARGET = |
3585593d | 71 | LIBCFLAGS_FOR_TARGET = $(CFLAGS_FOR_TARGET) |
04103845 DE |
72 | PICFLAG = |
73 | PICFLAG_FOR_TARGET = | |
7b636683 | 74 | |
a4e879a1 | 75 | # start-sanitize-chill |
7d9f0c54 MW |
76 | CHILLFLAGS = $(CFLAGS) |
77 | CHILL_LIB = -lchill | |
a4e879a1 | 78 | # end-sanitize-chill |
2cf00a36 | 79 | CXX = c++ |
7b636683 | 80 | |
1d5fcc66 | 81 | # Use -O2 to stress test the compiler. |
864a5888 PB |
82 | CXXFLAGS = -g -O2 |
83 | LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates | |
3585593d | 84 | CXXFLAGS_FOR_TARGET = $(CXXFLAGS) |
2f64ef77 | 85 | LIBCXXFLAGS_FOR_TARGET = $(CXXFLAGS_FOR_TARGET) -fno-implicit-templates |
7b636683 | 86 | |
4d714963 | 87 | RANLIB = ranlib |
b6ae0f10 ILT |
88 | |
89 | DLLTOOL = dlltool | |
90 | ||
51489233 | 91 | NM = nm |
64434418 ILT |
92 | |
93 | LD = ld | |
94 | ||
5cc73086 KR |
95 | # Not plain GZIP, since gzip looks there for extra command-line options. |
96 | GZIPPROG = gzip | |
eb02fd64 | 97 | |
aaefc574 JM |
98 | # These values are substituted by configure. |
99 | DEFAULT_YACC = yacc | |
100 | DEFAULT_LEX = lex | |
101 | ||
40e16078 | 102 | # BISON: This line sed'ed to BISON = bison -y for FSF releases, don't remove. |
5cc73086 KR |
103 | BISON = `if [ -f $$r/byacc/byacc ] ; \ |
104 | then echo $$r/byacc/byacc ; \ | |
aaefc574 | 105 | else echo ${DEFAULT_YACC} ; \ |
06a07944 | 106 | fi` |
2645fb0c | 107 | |
5cc73086 KR |
108 | LEX = `if [ -f $$r/flex/flex ] ; \ |
109 | then echo $$r/flex/flex ; \ | |
aaefc574 | 110 | else echo ${DEFAULT_LEX} ; fi` |
2198e4ba | 111 | |
5cc73086 KR |
112 | M4 = `if [ -f $$r/m4/m4 ] ; \ |
113 | then echo $$r/m4/m4 ; \ | |
65e21701 KR |
114 | else echo m4 ; fi` |
115 | ||
97840afa | 116 | MAKEINFO = `if [ -f $$r/texinfo/makeinfo/Makefile ] ; \ |
5cc73086 | 117 | then echo $$r/texinfo/makeinfo/makeinfo ; \ |
77806c3e | 118 | else echo makeinfo ; fi` |
484fa12d | 119 | |
9823504d ILT |
120 | # This just becomes part of the MAKEINFO definition passed down to |
121 | # sub-makes. It lets flags be given on the command line while still | |
122 | # using the makeinfo from the object tree. | |
123 | MAKEINFOFLAGS = | |
b772d75e | 124 | |
5cc73086 KR |
125 | EXPECT = `if [ -f $$r/expect/expect ] ; \ |
126 | then echo $$r/expect/expect ; \ | |
a54e05f6 KR |
127 | else echo expect ; fi` |
128 | ||
81eb5025 ILT |
129 | RUNTEST = `if [ -f $$s/dejagnu/runtest ] ; \ |
130 | then echo $$s/dejagnu/runtest ; \ | |
6a42d184 DZ |
131 | else echo runtest ; fi` |
132 | ||
f980fcfb | 133 | |
e85e07cb | 134 | # compilers to use to create programs which must be run in the build |
440868a0 ILT |
135 | # environment. |
136 | CC_FOR_BUILD = $(CC) | |
e85e07cb | 137 | CXX_FOR_BUILD = $(CXX) |
440868a0 | 138 | |
9f73dd6a | 139 | SUBDIRS = "this is set via configure, don't edit this" |
6a3958b2 RP |
140 | OTHERS = |
141 | ||
ca2ce3b3 ILT |
142 | # This is set by the configure script to the list of directories which |
143 | # should be built using the target tools. | |
ab1cbc67 | 144 | TARGET_CONFIGDIRS = libiberty libgloss newlib libio librx libstdc++ libg++ winsup |
ca2ce3b3 | 145 | |
e66eb658 | 146 | # Target libraries are put under this directory: |
d92eef0c JM |
147 | # Changed by configure to $(target_alias) if cross. |
148 | TARGET_SUBDIR = . | |
e66eb658 | 149 | |
ca2ce3b3 ILT |
150 | # This is set by the configure script to the arguments passed to configure. |
151 | CONFIG_ARGUMENTS = | |
152 | ||
b6ae0f10 ILT |
153 | # This is set by configure to REALLY_SET_LIB_PATH if --enable-shared |
154 | # was used. | |
155 | SET_LIB_PATH = | |
156 | ||
157 | # This is the name of the environment variable used for the path to | |
158 | # the libraries. This may be changed by configure.in. | |
159 | RPATH_ENVVAR = LD_LIBRARY_PATH | |
160 | ||
161 | # configure.in sets SET_LIB_PATH to this if --enable-shared was used. | |
162 | REALLY_SET_LIB_PATH = \ | |
163 | $(RPATH_ENVVAR)=$$r/bfd:$$r/opcodes:$$$(RPATH_ENVVAR); \ | |
164 | export $(RPATH_ENVVAR); | |
165 | ||
a0f47eb7 | 166 | ALL = all.normal |
ff290baf | 167 | INSTALL_TARGET = installdirs \ |
f35c6160 DZ |
168 | $(INSTALL_MODULES) \ |
169 | $(INSTALL_TARGET_MODULES) \ | |
170 | $(INSTALL_X11_MODULES) \ | |
753d5049 | 171 | install-gcc \ |
09985c96 | 172 | $(INSTALL_DOSREL) |
753d5049 | 173 | |
fb660409 | 174 | |
51489233 | 175 | CC_FOR_TARGET = ` \ |
72ce05e8 | 176 | if [ -f $$r/gcc/xgcc ] ; then \ |
e66eb658 | 177 | if [ -f $$r/$(TARGET_SUBDIR)/newlib/Makefile ] ; then \ |
d5a8bfde | 178 | if [ -f $$r/$(TARGET_SUBDIR)/winsup/Makefile ] ; then \ |
81eb5025 | 179 | echo $$r/gcc/xgcc -B$$r/gcc/ -B$$r/newlib/ -L$$r/winsup -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \ |
d5a8bfde | 180 | else \ |
81eb5025 | 181 | echo $$r/gcc/xgcc -B$$r/gcc/ -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \ |
d5a8bfde | 182 | fi; \ |
753d5049 SC |
183 | else \ |
184 | echo $$r/gcc/xgcc -B$$r/gcc/; \ | |
185 | fi; \ | |
51489233 | 186 | else \ |
378fd382 | 187 | if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \ |
51489233 ILT |
188 | echo $(CC); \ |
189 | else \ | |
ea6d5817 | 190 | t='$(program_transform_name)'; echo gcc | sed -e 's/x/x/' $$t; \ |
51489233 ILT |
191 | fi; \ |
192 | fi` | |
193 | ||
72ce05e8 ILT |
194 | # If CC_FOR_TARGET is not overriden on the command line, then this |
195 | # variable is passed down to the gcc Makefile, where it is used to | |
196 | # build libgcc2.a. We define it here so that it can itself be | |
197 | # overridden on the command line. | |
198 | GCC_FOR_TARGET = $$r/gcc/xgcc -B$$r/gcc/ | |
199 | ||
a4e879a1 | 200 | # start-sanitize-chill |
7d9f0c54 | 201 | CHILL_FOR_TARGET = ` \ |
72ce05e8 | 202 | if [ -f $$r/gcc/xgcc ] ; then \ |
04103845 | 203 | echo $$r/gcc/xgcc -B$$r/gcc/ -L$$r/gcc/ch/runtime/; \ |
7d9f0c54 MW |
204 | else \ |
205 | if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \ | |
206 | echo $(CC); \ | |
207 | else \ | |
ea6d5817 | 208 | t='$(program_transform_name)'; echo gcc | sed -e 's/x/x/' $$t; \ |
7d9f0c54 MW |
209 | fi; \ |
210 | fi` | |
34b3298b | 211 | |
a4e879a1 | 212 | # end-sanitize-chill |
7d9f0c54 | 213 | |
d1bea4c7 | 214 | CXX_FOR_TARGET = ` \ |
72ce05e8 | 215 | if [ -f $$r/gcc/xgcc ] ; then \ |
e66eb658 | 216 | if [ -f $$r/$(TARGET_SUBDIR)/newlib/Makefile ] ; then \ |
d5a8bfde | 217 | if [ -f $$r/$(TARGET_SUBDIR)/winsup/Makefile ] ; then \ |
81eb5025 | 218 | echo $$r/gcc/xgcc -B$$r/gcc/ -B$$r/newlib/ -L$$r/winsup -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \ |
d5a8bfde | 219 | else \ |
81eb5025 | 220 | echo $$r/gcc/xgcc -B$$r/gcc/ -idirafter $$r/$(TARGET_SUBDIR)/newlib/targ-include -idirafter $$s/newlib/libc/include -nostdinc; \ |
d5a8bfde | 221 | fi; \ |
753d5049 SC |
222 | else \ |
223 | echo $$r/gcc/xgcc -B$$r/gcc/; \ | |
224 | fi; \ | |
fca4f908 | 225 | else \ |
e85e07cb ILT |
226 | if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \ |
227 | echo $(CXX); \ | |
fca4f908 | 228 | else \ |
2cf00a36 | 229 | t='$(program_transform_name)'; echo c++ | sed -e 's/x/x/' $$t; \ |
fca4f908 MW |
230 | fi; \ |
231 | fi` | |
232 | ||
440868a0 | 233 | AS_FOR_TARGET = ` \ |
ea6d5817 | 234 | if [ -f $$r/gas/as.new ] ; then \ |
5cc73086 | 235 | echo $$r/gas/as.new ; \ |
440868a0 | 236 | else \ |
e85e07cb | 237 | if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \ |
440868a0 ILT |
238 | echo $(AS); \ |
239 | else \ | |
ea6d5817 | 240 | t='$(program_transform_name)'; echo as | sed -e 's/x/x/' $$t ; \ |
81246025 | 241 | fi; \ |
440868a0 ILT |
242 | fi` |
243 | ||
054f9ada JM |
244 | LD_FOR_TARGET = ` \ |
245 | if [ -f $$r/ld/ld.new ] ; then \ | |
246 | echo $$r/ld/ld.new ; \ | |
247 | else \ | |
248 | if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \ | |
249 | echo $(LD); \ | |
250 | else \ | |
251 | t='$(program_transform_name)'; echo ld | sed -e 's/x/x/' $$t ; \ | |
252 | fi; \ | |
253 | fi` | |
254 | ||
a220ba0f SC |
255 | DLLTOOL_FOR_TARGET = ` \ |
256 | if [ -f $$r/binutils/dlltool ] ; then \ | |
257 | echo $$r/binutils/dlltool ; \ | |
258 | else \ | |
259 | if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \ | |
260 | echo $(DLLTOOL); \ | |
261 | else \ | |
262 | t='$(program_transform_name)'; echo dlltool | sed -e 's/x/x/' $$t ; \ | |
263 | fi; \ | |
264 | fi` | |
265 | ||
51489233 | 266 | AR_FOR_TARGET = ` \ |
5cc73086 KR |
267 | if [ -f $$r/binutils/ar ] ; then \ |
268 | echo $$r/binutils/ar ; \ | |
51489233 | 269 | else \ |
378fd382 | 270 | if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \ |
51489233 ILT |
271 | echo $(AR); \ |
272 | else \ | |
ea6d5817 | 273 | t='$(program_transform_name)'; echo ar | sed -e 's/x/x/' $$t ; \ |
81246025 | 274 | fi; \ |
51489233 ILT |
275 | fi` |
276 | ||
277 | RANLIB_FOR_TARGET = ` \ | |
5cc73086 KR |
278 | if [ -f $$r/binutils/ranlib ] ; then \ |
279 | echo $$r/binutils/ranlib ; \ | |
51489233 | 280 | else \ |
378fd382 | 281 | if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \ |
51489233 ILT |
282 | echo $(RANLIB); \ |
283 | else \ | |
ea6d5817 | 284 | t='$(program_transform_name)'; echo ranlib | sed -e 's/x/x/' $$t ; \ |
81246025 | 285 | fi; \ |
51489233 ILT |
286 | fi` |
287 | ||
288 | NM_FOR_TARGET = ` \ | |
ea6d5817 | 289 | if [ -f $$r/binutils/nm.new ] ; then \ |
753d5049 | 290 | echo $$r/binutils/nm.new ; \ |
51489233 | 291 | else \ |
378fd382 | 292 | if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \ |
51489233 ILT |
293 | echo $(NM); \ |
294 | else \ | |
ea6d5817 | 295 | t='$(program_transform_name)'; echo nm | sed -e 's/x/x/' $$t ; \ |
81246025 | 296 | fi; \ |
51489233 ILT |
297 | fi` |
298 | ||
eb02fd64 | 299 | #### host and target specific makefile fragments come in here. |
ec342d7d | 300 | ### |
eb02fd64 | 301 | |
0ef4728f ILT |
302 | # Flags to pass down to all sub-makes. |
303 | # Please keep these in alphabetical order. | |
304 | BASE_FLAGS_TO_PASS = \ | |
2198e4ba | 305 | "AR_FLAGS=$(AR_FLAGS)" \ |
d09de70e | 306 | "AR_FOR_TARGET=$(AR_FOR_TARGET)" \ |
0ef4728f | 307 | "AS_FOR_TARGET=$(AS_FOR_TARGET)" \ |
378fd382 | 308 | "BISON=$(BISON)" \ |
378fd382 | 309 | "CC_FOR_BUILD=$(CC_FOR_BUILD)" \ |
0ef4728f | 310 | "CC_FOR_TARGET=$(CC_FOR_TARGET)" \ |
2198e4ba | 311 | "CFLAGS=$(CFLAGS)" \ |
3585593d | 312 | "CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \ |
a4e879a1 | 313 | $(start-sanitize-chill)\ |
7d9f0c54 MW |
314 | "CHILLFLAGS=$(CHILLFLAGS)" \ |
315 | "CHILL_FOR_TARGET=$(CHILL_FOR_TARGET)" \ | |
316 | "CHILL_LIB=$(CHILL_LIB)" \ | |
a4e879a1 | 317 | $(end-sanitize-chill)\ |
0ef4728f ILT |
318 | "CXX_FOR_BUILD=$(CXX_FOR_BUILD)" \ |
319 | "CXXFLAGS=$(CXXFLAGS)" \ | |
3585593d | 320 | "CXXFLAGS_FOR_TARGET=$(CXXFLAGS_FOR_TARGET)" \ |
0ef4728f | 321 | "CXX_FOR_TARGET=$(CXX_FOR_TARGET)" \ |
a220ba0f | 322 | "DLLTOOL_FOR_TARGET=$(DLLTOOL_FOR_TARGET)" \ |
2198e4ba MT |
323 | "INSTALL=$(INSTALL)" \ |
324 | "INSTALL_DATA=$(INSTALL_DATA)" \ | |
440868a0 | 325 | "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \ |
378fd382 DZ |
326 | "LDFLAGS=$(LDFLAGS)" \ |
327 | "LEX=$(LEX)" \ | |
054f9ada | 328 | "LD_FOR_TARGET=$(LD_FOR_TARGET)" \ |
3585593d BK |
329 | "LIBCFLAGS=$(LIBCFLAGS)" \ |
330 | "LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \ | |
04103845 DE |
331 | "LIBCXXFLAGS=$(LIBCXXFLAGS)" \ |
332 | "LIBCXXFLAGS_FOR_TARGET=$(LIBCXXFLAGS_FOR_TARGET)" \ | |
65e21701 | 333 | "M4=$(M4)" \ |
eb40ca93 | 334 | "MAKE=$(MAKE)" \ |
9823504d | 335 | "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \ |
0ef4728f | 336 | "NM_FOR_TARGET=$(NM_FOR_TARGET)" \ |
04103845 DE |
337 | "PICFLAG=$(PICFLAG)" \ |
338 | "PICFLAG_FOR_TARGET=$(PICFLAG_FOR_TARGET)" \ | |
d09de70e | 339 | "RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \ |
49dfa984 | 340 | "SHELL=$(SHELL)" \ |
a54e05f6 | 341 | "EXPECT=$(EXPECT)" \ |
6a42d184 | 342 | "RUNTEST=$(RUNTEST)" \ |
86365152 | 343 | "RUNTESTFLAGS=$(RUNTESTFLAGS)" \ |
5cc73086 | 344 | "YACC=$(BISON)" \ |
378fd382 DZ |
345 | "exec_prefix=$(exec_prefix)" \ |
346 | "prefix=$(prefix)" \ | |
347 | "tooldir=$(tooldir)" | |
2198e4ba | 348 | |
0ef4728f ILT |
349 | # Flags to pass down to most sub-makes, in which we're building with |
350 | # the host environment. | |
6d681784 | 351 | # If any variables are added here, they must be added to do-*, below. |
0ef4728f | 352 | EXTRA_HOST_FLAGS = \ |
6d681784 JG |
353 | 'AR=$(AR)' \ |
354 | 'AS=$(AS)' \ | |
355 | 'CC=$(CC)' \ | |
356 | 'CXX=$(CXX)' \ | |
b6ae0f10 | 357 | 'DLLTOOL=$(DLLTOOL)' \ |
64434418 | 358 | 'LD=$(LD)' \ |
6d681784 | 359 | 'NM=$(NM)' \ |
b6ae0f10 ILT |
360 | 'RANLIB=$(RANLIB)' |
361 | ||
0ef4728f | 362 | |
97840afa | 363 | FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_HOST_FLAGS) |
0ef4728f | 364 | |
d1bea4c7 DZ |
365 | # Flags that are concerned with the location of the X11 include files |
366 | # and library files | |
054f9ada JM |
367 | # |
368 | # NOTE: until the top-level is getting the values via autoconf, it only | |
369 | # causes problems to have this top-level Makefile overriding the autoconf-set | |
370 | # values in child directories. Only variables that don't conflict with | |
371 | # autoconf'ed ones should be passed by X11_FLAGS_TO_PASS for now. | |
372 | # | |
d1bea4c7 | 373 | X11_FLAGS_TO_PASS = \ |
054f9ada JM |
374 | 'X11_EXTRA_CFLAGS=$(X11_EXTRA_CFLAGS)' \ |
375 | 'X11_EXTRA_LIBS=$(X11_EXTRA_LIBS)' | |
d1bea4c7 | 376 | |
0ef4728f ILT |
377 | # Flags to pass down to makes which are built with the target environment. |
378 | # The double $ decreases the length of the command line; the variables | |
379 | # are set in BASE_FLAGS_TO_PASS, and the sub-make will expand them. | |
6d681784 | 380 | # If any variables are added here, they must be added to do-*, below. |
0ef4728f ILT |
381 | EXTRA_TARGET_FLAGS = \ |
382 | 'AR=$$(AR_FOR_TARGET)' \ | |
383 | 'AS=$$(AS_FOR_TARGET)' \ | |
384 | 'CC=$$(CC_FOR_TARGET)' \ | |
3585593d | 385 | 'CFLAGS=$$(CFLAGS_FOR_TARGET)' \ |
0ef4728f | 386 | 'CXX=$$(CXX_FOR_TARGET)' \ |
3585593d | 387 | 'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \ |
a220ba0f | 388 | 'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \ |
054f9ada | 389 | 'LD=$$(LD_FOR_TARGET)' \ |
3585593d BK |
390 | 'LIBCFLAGS=$$(LIBCFLAGS_FOR_TARGET)' \ |
391 | 'LIBCXXFLAGS=$$(LIBCXXFLAGS_FOR_TARGET)' \ | |
0ef4728f | 392 | 'NM=$$(NM_FOR_TARGET)' \ |
04103845 | 393 | 'PICFLAG=$$(PICFLAG_FOR_TARGET)' \ |
753d5049 | 394 | 'RANLIB=$$(RANLIB_FOR_TARGET)' |
0ef4728f ILT |
395 | |
396 | TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS) | |
51489233 | 397 | |
f4e414f1 ILT |
398 | # Flags to pass down to gcc. gcc builds a library, libgcc.a, so it |
399 | # unfortunately needs the native compiler and the target ar and | |
0ef4728f | 400 | # ranlib. |
66957ce4 ILT |
401 | # If any variables are added here, they must be added to do-*, below. |
402 | # The HOST_* variables are a special case, which are used for the gcc | |
403 | # cross-building scheme. | |
0ef4728f ILT |
404 | EXTRA_GCC_FLAGS = \ |
405 | 'AR=$$(AR_FOR_TARGET)' \ | |
6d681784 JG |
406 | 'AS=$(AS)' \ |
407 | 'CC=$(CC)' \ | |
408 | 'CXX=$(CXX)' \ | |
b6ae0f10 | 409 | 'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \ |
a54e05f6 KR |
410 | 'HOST_CC=$(CC_FOR_BUILD)' \ |
411 | 'HOST_PREFIX=$(HOST_PREFIX)' \ | |
412 | 'HOST_PREFIX_1=$(HOST_PREFIX_1)' \ | |
6d681784 | 413 | 'NM=$(NM)' \ |
4c0b7ebc | 414 | 'RANLIB=$$(RANLIB_FOR_TARGET)' \ |
97840afa | 415 | "GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \ |
4c0b7ebc DE |
416 | `if test x"$(LANGUAGES)" != x; then echo "LANGUAGES=$(LANGUAGES)"; fi` \ |
417 | `if test x"$(STMP_FIXPROTO)" != x; then echo "STMP_FIXPROTO=$(STMP_FIXPROTO)"; fi` \ | |
418 | `if test x"$(LIMITS_H_TEST)" != x; then echo "LIMITS_H_TEST=$(LIMITS_H_TEST)"; fi` \ | |
419 | `if test x"$(LIBGCC1_TEST)" != x; then echo "LIBGCC1_TEST=$(LIBGCC1_TEST)"; fi` \ | |
420 | `if test x"$(LIBGCC2_CFLAGS)" != x; then echo "LIBGCC2_CFLAGS=$(LIBGCC2_CFLAGS)"; fi` \ | |
2e482734 | 421 | `if test x"$(LIBGCC2_DEBUG_CFLAGS)" != x; then echo "LIBGCC2_DEBUG_CFLAGS=$(LIBGCC2_DEBUG_CFLAGS)"; fi` \ |
4c0b7ebc DE |
422 | `if test x"$(LIBGCC2_INCLUDES)" != x; then echo "LIBGCC2_INCLUDES=$(LIBGCC2_INCLUDES)"; fi` \ |
423 | `if test x"$(ENQUIRE)" != x; then echo "ENQUIRE=$(ENQUIRE)"; fi` \ | |
424 | `if test x"$(BOOT_CFLAGS)" != x; then echo "BOOT_CFLAGS=$(BOOT_CFLAGS)"; fi` | |
0ef4728f | 425 | |
34b3298b | 426 | GCC_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_GCC_FLAGS) |
f4e414f1 | 427 | |
6a42d184 | 428 | # This is a list of the targets for all of the modules which are compiled |
79337c85 ILT |
429 | # using $(FLAGS_TO_PASS). |
430 | ALL_MODULES = \ | |
53c403df | 431 | all-apache \ |
79337c85 | 432 | all-autoconf \ |
08168809 | 433 | all-automake \ |
5db223e4 | 434 | all-bash \ |
79337c85 ILT |
435 | all-bfd \ |
436 | all-binutils \ | |
437 | all-byacc \ | |
438 | all-cvs \ | |
97840afa | 439 | all-db \ |
79337c85 ILT |
440 | all-dejagnu \ |
441 | all-diff \ | |
ac259c28 | 442 | all-dosutils \ |
79337c85 ILT |
443 | all-etc \ |
444 | all-fileutils \ | |
97840afa | 445 | all-findutils \ |
79337c85 ILT |
446 | all-find \ |
447 | all-flex \ | |
448 | all-gas \ | |
449 | all-gawk \ | |
ba26181f | 450 | all-gnuserv \ |
79337c85 ILT |
451 | all-gprof \ |
452 | all-grep \ | |
19b1d034 | 453 | all-grez \ |
79337c85 ILT |
454 | all-gzip \ |
455 | all-hello \ | |
3718029f ILT |
456 | $(start-sanitize-ide) \ |
457 | all-ilu \ | |
458 | $(end-sanitize-ide) \ | |
79337c85 | 459 | all-indent \ |
13d7cbe2 | 460 | all-inet \ |
79337c85 | 461 | all-ispell \ |
97840afa | 462 | all-itcl \ |
79337c85 ILT |
463 | all-ld \ |
464 | all-libiberty \ | |
eebe454c TT |
465 | $(start-sanitize-ide) \ |
466 | all-libide \ | |
467 | $(end-sanitize-ide) \ | |
79337c85 ILT |
468 | all-m4 \ |
469 | all-make \ | |
470 | all-mmalloc \ | |
471 | all-opcodes \ | |
472 | all-patch \ | |
0f8f1d33 | 473 | all-perl \ |
79337c85 ILT |
474 | all-prms \ |
475 | all-rcs \ | |
476 | all-readline \ | |
275049c0 | 477 | all-release \ |
79337c85 ILT |
478 | all-recode \ |
479 | all-sed \ | |
480 | all-send-pr \ | |
481 | all-shellutils \ | |
482 | all-sim \ | |
2e482734 | 483 | all-sn \ |
79337c85 ILT |
484 | all-tar \ |
485 | all-tcl \ | |
486 | all-texinfo \ | |
487 | all-textutils \ | |
488 | all-tgas \ | |
489 | all-time \ | |
490 | all-uudecode \ | |
eebe454c TT |
491 | $(start-sanitize-ide) \ |
492 | all-vmake \ | |
493 | $(end-sanitize-ide) \ | |
753d5049 SC |
494 | all-wdiff |
495 | ||
4f0b8f27 TL |
496 | # This is a list of the check targets for all of the modules which are |
497 | # compiled using $(FLAGS_TO_PASS). | |
498 | # | |
d237841c BC |
499 | # The list is in two parts. The first lists those tools which |
500 | # are tested as part of the host's native tool-chain, and not | |
501 | # tested in a cross configuration. | |
502 | NATIVE_CHECK_MODULES = \ | |
503 | check-byacc \ | |
4f0b8f27 TL |
504 | check-flex |
505 | ||
d237841c | 506 | CROSS_CHECK_MODULES = \ |
53c403df | 507 | check-apache \ |
6a42d184 | 508 | check-autoconf \ |
08168809 | 509 | check-automake \ |
5db223e4 | 510 | check-bash \ |
6a42d184 DZ |
511 | check-bfd \ |
512 | check-binutils \ | |
6a42d184 | 513 | check-cvs \ |
97840afa | 514 | check-db \ |
6a42d184 DZ |
515 | check-dejagnu \ |
516 | check-diff \ | |
517 | check-etc \ | |
518 | check-fileutils \ | |
97840afa | 519 | check-findutils \ |
6a42d184 | 520 | check-find \ |
6a42d184 DZ |
521 | check-gas \ |
522 | check-gawk \ | |
ba26181f | 523 | check-gnuserv \ |
6a42d184 DZ |
524 | check-gprof \ |
525 | check-grep \ | |
526 | check-gzip \ | |
527 | check-hello \ | |
3718029f ILT |
528 | $(start-sanitize-ide) \ |
529 | check-ilu \ | |
530 | $(end-sanitize-ide) \ | |
6a42d184 | 531 | check-indent \ |
13d7cbe2 | 532 | check-inet \ |
6a42d184 | 533 | check-ispell \ |
97840afa | 534 | check-itcl \ |
6a42d184 DZ |
535 | check-ld \ |
536 | check-libiberty \ | |
eebe454c TT |
537 | $(start-sanitize-ide) \ |
538 | check-libide \ | |
539 | $(end-sanitize-ide) \ | |
6a42d184 DZ |
540 | check-m4 \ |
541 | check-make \ | |
542 | check-mmcheckoc \ | |
543 | check-opcodes \ | |
544 | check-patch \ | |
0f8f1d33 | 545 | check-perl \ |
6a42d184 DZ |
546 | check-prms \ |
547 | check-rcs \ | |
548 | check-readline \ | |
549 | check-recode \ | |
550 | check-sed \ | |
551 | check-send-pr \ | |
552 | check-shellutils \ | |
2e482734 | 553 | check-sn \ |
6a42d184 DZ |
554 | check-sim \ |
555 | check-tar \ | |
556 | check-tcl \ | |
557 | check-texinfo \ | |
558 | check-textutils \ | |
559 | check-tgas \ | |
560 | check-time \ | |
561 | check-uudecode \ | |
eebe454c TT |
562 | $(start-sanitize-ide) \ |
563 | check-vmake \ | |
564 | $(end-sanitize-ide) \ | |
6a42d184 | 565 | check-wdiff |
d237841c BC |
566 | |
567 | CHECK_MODULES=$(NATIVE_CHECK_MODULES) $(CROSS_CHECK_MODULES) | |
6a42d184 DZ |
568 | |
569 | # This is a list of the install targets for all of the modules which are | |
79337c85 | 570 | # compiled using $(FLAGS_TO_PASS). |
27349293 ILT |
571 | # We put install-opcodes before install-binutils because the installed |
572 | # binutils might be on PATH, and they might need the shared opcodes | |
573 | # library. | |
79337c85 | 574 | INSTALL_MODULES = \ |
53c403df | 575 | install-apache \ |
79337c85 | 576 | install-autoconf \ |
08168809 | 577 | install-automake \ |
5db223e4 | 578 | install-bash \ |
79337c85 | 579 | install-bfd \ |
27349293 | 580 | install-opcodes \ |
79337c85 ILT |
581 | install-binutils \ |
582 | install-byacc \ | |
583 | install-cvs \ | |
97840afa | 584 | install-db \ |
79337c85 ILT |
585 | install-dejagnu \ |
586 | install-diff \ | |
753d5049 | 587 | install-dosutils \ |
79337c85 ILT |
588 | install-etc \ |
589 | install-fileutils \ | |
97840afa | 590 | install-findutils \ |
79337c85 ILT |
591 | install-find \ |
592 | install-flex \ | |
593 | install-gas \ | |
594 | install-gawk \ | |
ba26181f | 595 | install-gnuserv \ |
79337c85 ILT |
596 | install-gprof \ |
597 | install-grep \ | |
19b1d034 | 598 | install-grez \ |
79337c85 ILT |
599 | install-gzip \ |
600 | install-hello \ | |
3718029f ILT |
601 | $(start-sanitize-ide) \ |
602 | install-ilu \ | |
603 | $(end-sanitize-ide) \ | |
79337c85 | 604 | install-indent \ |
13d7cbe2 | 605 | install-inet \ |
79337c85 | 606 | install-ispell \ |
97840afa | 607 | install-itcl \ |
79337c85 ILT |
608 | install-ld \ |
609 | install-libiberty \ | |
eebe454c TT |
610 | $(start-sanitize-ide) \ |
611 | install-libide \ | |
612 | $(end-sanitize-ide) \ | |
79337c85 ILT |
613 | install-m4 \ |
614 | install-make \ | |
615 | install-mmalloc \ | |
79337c85 | 616 | install-patch \ |
0f8f1d33 | 617 | install-perl \ |
79337c85 ILT |
618 | install-prms \ |
619 | install-rcs \ | |
620 | install-readline \ | |
621 | install-recode \ | |
622 | install-sed \ | |
623 | install-send-pr \ | |
624 | install-shellutils \ | |
625 | install-sim \ | |
2e482734 | 626 | install-sn \ |
79337c85 ILT |
627 | install-tar \ |
628 | install-tcl \ | |
629 | install-texinfo \ | |
630 | install-textutils \ | |
631 | install-tgas \ | |
632 | install-time \ | |
633 | install-uudecode \ | |
eebe454c TT |
634 | $(start-sanitize-ide) \ |
635 | install-vmake \ | |
636 | $(end-sanitize-ide) \ | |
79337c85 ILT |
637 | install-wdiff |
638 | ||
6a42d184 | 639 | # This is a list of the targets for all of the modules which are compiled |
79337c85 ILT |
640 | # using $(X11_FLAGS_TO_PASS). |
641 | ALL_X11_MODULES = \ | |
642 | all-emacs \ | |
4d802af9 | 643 | all-emacs19 \ |
04103845 | 644 | all-gdb \ |
79337c85 | 645 | all-expect \ |
65e21701 | 646 | all-gash \ |
0f8f1d33 | 647 | all-guile \ |
79337c85 ILT |
648 | all-tclX \ |
649 | all-tk | |
650 | ||
6a42d184 DZ |
651 | # This is a list of the check targets for all of the modules which are |
652 | # compiled using $(X11_FLAGS_TO_PASS). | |
653 | CHECK_X11_MODULES = \ | |
654 | check-emacs \ | |
04103845 | 655 | check-gdb \ |
0f8f1d33 | 656 | check-guile \ |
6a42d184 | 657 | check-expect \ |
65e21701 | 658 | check-gash \ |
2e482734 | 659 | check-tclX |
6a42d184 | 660 | |
79337c85 ILT |
661 | # This is a list of the install targets for all the modules which are |
662 | # compiled using $(X11_FLAGS_TO_PASS). | |
663 | INSTALL_X11_MODULES = \ | |
664 | install-emacs \ | |
4d802af9 | 665 | install-emacs19 \ |
04103845 | 666 | install-gdb \ |
0f8f1d33 | 667 | install-guile \ |
79337c85 | 668 | install-expect \ |
65e21701 | 669 | install-gash \ |
79337c85 ILT |
670 | install-tclX \ |
671 | install-tk | |
fca4f908 | 672 | |
6a42d184 | 673 | # This is a list of the targets for all of the modules which are compiled |
79337c85 ILT |
674 | # using $(TARGET_FLAGS_TO_PASS). |
675 | ALL_TARGET_MODULES = \ | |
ab1cbc67 PB |
676 | all-target-libio \ |
677 | all-target-libstdc++ \ | |
678 | all-target-librx \ | |
679 | all-target-libg++ \ | |
680 | all-target-newlib \ | |
681 | all-target-winsup \ | |
682 | all-target-libgloss \ | |
4c0b7ebc DE |
683 | all-target-libiberty \ |
684 | all-target-examples | |
79337c85 | 685 | |
ca2ce3b3 ILT |
686 | # This is a list of the configure targets for all of the modules which |
687 | # are compiled using the target tools. | |
688 | CONFIGURE_TARGET_MODULES = \ | |
ab1cbc67 PB |
689 | configure-target-libio \ |
690 | configure-target-libstdc++ \ | |
691 | configure-target-librx \ | |
692 | configure-target-libg++ \ | |
693 | configure-target-newlib \ | |
694 | configure-target-winsup \ | |
695 | configure-target-libgloss \ | |
4c0b7ebc DE |
696 | configure-target-libiberty \ |
697 | configure-target-examples | |
ca2ce3b3 | 698 | |
6a42d184 DZ |
699 | # This is a list of the check targets for all of the modules which are |
700 | # compiled using $(TARGET_FLAGS_TO_PASS). | |
701 | CHECK_TARGET_MODULES = \ | |
ab1cbc67 PB |
702 | check-target-libio \ |
703 | check-target-libstdc++ \ | |
704 | check-target-libg++ \ | |
705 | check-target-newlib \ | |
706 | check-target-winsup \ | |
707 | check-target-libiberty | |
6a42d184 DZ |
708 | |
709 | # This is a list of the install targets for all of the modules which are | |
79337c85 ILT |
710 | # compiled using $(TARGET_FLAGS_TO_PASS). |
711 | INSTALL_TARGET_MODULES = \ | |
ab1cbc67 PB |
712 | install-target-libio \ |
713 | install-target-libstdc++ \ | |
714 | install-target-libg++ \ | |
715 | install-target-newlib \ | |
716 | install-target-winsup \ | |
717 | install-target-libgloss \ | |
718 | install-target-libiberty | |
7481617f | 719 | |
7508666f MM |
720 | # This is a list of the targets for which we can do a clean-{target}. |
721 | CLEAN_MODULES = \ | |
13d7cbe2 | 722 | clean-apache \ |
7508666f | 723 | clean-autoconf \ |
08168809 | 724 | clean-automake \ |
5db223e4 | 725 | clean-bash \ |
7508666f MM |
726 | clean-bfd \ |
727 | clean-binutils \ | |
728 | clean-byacc \ | |
729 | clean-cvs \ | |
97840afa | 730 | clean-db \ |
7508666f MM |
731 | clean-dejagnu \ |
732 | clean-diff \ | |
733 | clean-dosutils \ | |
734 | clean-etc \ | |
735 | clean-fileutils \ | |
97840afa | 736 | clean-findutils \ |
7508666f MM |
737 | clean-find \ |
738 | clean-flex \ | |
739 | clean-gas \ | |
740 | clean-gawk \ | |
ba26181f | 741 | clean-gnuserv \ |
7508666f MM |
742 | clean-gprof \ |
743 | clean-grep \ | |
744 | clean-grez \ | |
745 | clean-gzip \ | |
746 | clean-hello \ | |
3718029f ILT |
747 | $(start-sanitize-ide) \ |
748 | clean-ilu \ | |
749 | $(end-sanitize-ide) \ | |
7508666f | 750 | clean-indent \ |
13d7cbe2 | 751 | clean-inet \ |
7508666f | 752 | clean-ispell \ |
97840afa | 753 | clean-itcl \ |
7508666f MM |
754 | clean-ld \ |
755 | clean-libiberty \ | |
eebe454c TT |
756 | $(start-sanitize-ide) \ |
757 | clean-libide \ | |
758 | $(end-sanitize-ide) \ | |
7508666f MM |
759 | clean-m4 \ |
760 | clean-make \ | |
761 | clean-mmalloc \ | |
762 | clean-opcodes \ | |
763 | clean-patch \ | |
764 | clean-perl \ | |
765 | clean-prms \ | |
766 | clean-rcs \ | |
767 | clean-readline \ | |
768 | clean-release \ | |
769 | clean-recode \ | |
770 | clean-sed \ | |
771 | clean-send-pr \ | |
772 | clean-shellutils \ | |
773 | clean-sim \ | |
2e482734 | 774 | clean-sn \ |
7508666f MM |
775 | clean-tar \ |
776 | clean-tcl \ | |
777 | clean-texinfo \ | |
778 | clean-textutils \ | |
779 | clean-tgas \ | |
780 | clean-time \ | |
781 | clean-uudecode \ | |
eebe454c TT |
782 | $(start-sanitize-ide) \ |
783 | clean-vmake \ | |
784 | $(end-sanitize-ide) \ | |
7508666f MM |
785 | clean-wdiff |
786 | ||
787 | # All of the target modules that can be cleaned | |
788 | CLEAN_TARGET_MODULES = \ | |
789 | clean-target-libio \ | |
790 | clean-target-libstdc++ \ | |
791 | clean-target-librx \ | |
792 | clean-target-libg++ \ | |
793 | clean-target-newlib \ | |
794 | clean-target-winsup \ | |
795 | clean-target-libgloss \ | |
796 | clean-target-libiberty \ | |
797 | clean-target-examples | |
798 | ||
799 | # All of the x11 modules that can be cleaned | |
800 | CLEAN_X11_MODULES = \ | |
801 | clean-emacs \ | |
802 | clean-emacs19 \ | |
803 | clean-gdb \ | |
804 | clean-expect \ | |
805 | clean-gash \ | |
806 | clean-guile \ | |
807 | clean-tclX \ | |
808 | clean-tk | |
809 | ||
79337c85 | 810 | # The first rule in the file had better be this one. Don't put any above it. |
a59b94d2 | 811 | all: all.normal |
79337c85 ILT |
812 | .PHONY: all |
813 | ||
814 | # The target built for a native build. | |
815 | .PHONY: all.normal | |
816 | all.normal: \ | |
817 | $(ALL_MODULES) \ | |
46d0ca81 | 818 | $(ALL_X11_MODULES) \ |
2e482734 | 819 | $(ALL_TARGET_MODULES) \ |
79337c85 ILT |
820 | all-gcc |
821 | ||
0ef4728f | 822 | # Do a target for all the subdirectories. A ``make do-X'' will do a |
53222cbd RP |
823 | # ``make X'' in all subdirectories (because, in general, there is a |
824 | # dependency (below) of X upon do-X, a ``make X'' will also do this, | |
825 | # but it may do additional work as well). | |
0ef4728f ILT |
826 | # This target ensures that $(BASE_FLAGS_TO_PASS) appears only once, |
827 | # because it is so large that it can easily overflow the command line | |
828 | # length limit on some systems. | |
79337c85 | 829 | DO_X = \ |
79337c85 ILT |
830 | do-clean \ |
831 | do-distclean \ | |
832 | do-dvi \ | |
833 | do-info \ | |
834 | do-install-info \ | |
835 | do-installcheck \ | |
836 | do-mostlyclean \ | |
ca2ce3b3 | 837 | do-maintainer-clean \ |
753d5049 | 838 | do-TAGS |
79337c85 ILT |
839 | .PHONY: $(DO_X) |
840 | $(DO_X): | |
0ef4728f | 841 | @target=`echo $@ | sed -e 's/^do-//'`; \ |
5cc73086 | 842 | r=`pwd`; export r; \ |
81eb5025 | 843 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 844 | $(SET_LIB_PATH) \ |
ab1cbc67 | 845 | for i in $(SUBDIRS) -dummy-; do \ |
36286a3e | 846 | if [ -f ./$$i/Makefile ]; then \ |
0ef4728f | 847 | case $$i in \ |
0ef4728f | 848 | gcc) \ |
6d681784 | 849 | for flag in $(EXTRA_GCC_FLAGS); do \ |
0f8f1d33 | 850 | eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'|"`; \ |
6d681784 | 851 | done; \ |
0ef4728f ILT |
852 | ;; \ |
853 | *) \ | |
6d681784 | 854 | for flag in $(EXTRA_HOST_FLAGS); do \ |
0f8f1d33 | 855 | eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'|"`; \ |
6d681784 | 856 | done; \ |
0ef4728f ILT |
857 | ;; \ |
858 | esac ; \ | |
64434418 | 859 | export AR AS CC CXX LD NM RANLIB DLLTOOL; \ |
0ef4728f | 860 | if (cd ./$$i; \ |
6d681784 | 861 | $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \ |
64434418 | 862 | "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \ |
753d5049 | 863 | "RANLIB=$${RANLIB}" \ |
b6ae0f10 | 864 | "DLLTOOL=$${DLLTOOL}" \ |
6d681784 | 865 | $${target}); \ |
0ef4728f ILT |
866 | then true; else exit 1; fi; \ |
867 | else true; fi; \ | |
ec7a8792 ILT |
868 | done |
869 | @target=`echo $@ | sed -e 's/^do-//'`; \ | |
870 | r=`pwd`; export r; \ | |
81eb5025 | 871 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 872 | $(SET_LIB_PATH) \ |
ab1cbc67 PB |
873 | for i in $(TARGET_CONFIGDIRS) -dummy-; do \ |
874 | if [ -f $(TARGET_SUBDIR)/$$i/Makefile ]; then \ | |
875 | for flag in $(EXTRA_TARGET_FLAGS); do \ | |
0f8f1d33 | 876 | eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'|"`; \ |
ab1cbc67 | 877 | done; \ |
64434418 | 878 | export AR AS CC CXX LD NM RANLIB DLLTOOL; \ |
ab1cbc67 PB |
879 | if (cd $(TARGET_SUBDIR)/$$i; \ |
880 | $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \ | |
64434418 | 881 | "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \ |
ab1cbc67 | 882 | "RANLIB=$${RANLIB}" \ |
b6ae0f10 | 883 | "DLLTOOL=$${DLLTOOL}" \ |
ab1cbc67 PB |
884 | $${target}); \ |
885 | then true; else exit 1; fi; \ | |
886 | else true; fi; \ | |
0ef4728f | 887 | done |
fb90daeb | 888 | |
79337c85 ILT |
889 | # Here are the targets which correspond to the do-X targets. |
890 | ||
65088029 | 891 | .PHONY: info installcheck dvi install-info |
ca2ce3b3 ILT |
892 | .PHONY: clean distclean mostlyclean maintainer-clean realclean |
893 | .PHONY: local-clean local-distclean local-maintainer-clean | |
0ef4728f | 894 | info: do-info |
1a14993c | 895 | installcheck: do-installcheck |
0ef4728f | 896 | dvi: do-dvi |
9a9e8e7f | 897 | |
97840afa TT |
898 | # Make sure makeinfo is built before we do a `make info'. |
899 | do-info: all-texinfo | |
900 | ||
f35c6160 | 901 | install-info: do-install-info dir.info |
81eb5025 | 902 | s=`cd $(srcdir); pwd`; export s; \ |
72c09fbc SC |
903 | if [ -f dir.info ] ; then \ |
904 | $(INSTALL_DATA) dir.info $(infodir)/dir.info ; \ | |
50fbe976 | 905 | else true ; fi |
4d714963 | 906 | |
0ef4728f | 907 | local-clean: |
7fed4078 | 908 | -rm -f *.a TEMP errs core *.o *~ \#* TAGS *.E |
3b30df82 | 909 | |
0ef4728f | 910 | local-distclean: |
2e482734 | 911 | -rm -f Makefile config.status config.cache |
8c5bc3e3 ILT |
912 | -if [ "$(TARGET_SUBDIR)" != "." ]; then \ |
913 | rm -rf $(TARGET_SUBDIR); \ | |
914 | else true; fi | |
7fcfdcf7 | 915 | |
ca2ce3b3 ILT |
916 | local-maintainer-clean: |
917 | @echo "This command is intended for maintainers to use;" | |
918 | @echo "it deletes files that may require special tools to rebuild." | |
919 | ||
0ef4728f ILT |
920 | clean: do-clean local-clean |
921 | mostlyclean: do-mostlyclean local-clean | |
922 | distclean: do-distclean local-clean local-distclean | |
ca2ce3b3 ILT |
923 | maintainer-clean: local-maintainer-clean do-maintainer-clean local-clean |
924 | maintainer-clean: local-distclean | |
925 | realclean: maintainer-clean | |
0ef4728f | 926 | |
7508666f MM |
927 | # This rule is used to clean specific modules. |
928 | .PHONY: $(CLEAN_MODULES) $(CLEAN_X11_MODULES) clean-gcc | |
929 | $(CLEAN_MODULES) $(CLEAN_X11_MODULES) clean-gcc: | |
930 | @dir=`echo $@ | sed -e 's/clean-//'`; \ | |
931 | if [ -f ./$${dir}/Makefile ] ; then \ | |
932 | r=`pwd`; export r; \ | |
81eb5025 | 933 | s=`cd $(srcdir); pwd`; export s; \ |
7508666f MM |
934 | $(SET_LIB_PATH) \ |
935 | (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) clean); \ | |
936 | else \ | |
937 | true; \ | |
938 | fi | |
939 | ||
940 | .PHONY: $(CLEAN_TARGET_MODULES) | |
941 | $(CLEAN_TARGET_MODULES): | |
942 | @dir=`echo $@ | sed -e 's/clean-target-//'`; \ | |
062aded9 | 943 | rm -f $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/tmpmulti.out; \ |
7508666f MM |
944 | if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \ |
945 | r=`pwd`; export r; \ | |
81eb5025 | 946 | s=`cd $(srcdir); pwd`; export s; \ |
7508666f MM |
947 | $(SET_LIB_PATH) \ |
948 | (cd $(TARGET_SUBDIR)/$${dir}; $(MAKE) $(TARGET_FLAGS_TO_PASS) clean); \ | |
949 | else \ | |
950 | true; \ | |
951 | fi | |
952 | ||
953 | clean-target: $(CLEAN_TARGET_MODULES) | |
954 | ||
65088029 ILT |
955 | # Check target. |
956 | ||
957 | .PHONY: check | |
958 | check: $(CHECK_MODULES) \ | |
959 | $(CHECK_TARGET_MODULES) \ | |
960 | $(CHECK_X11_MODULES) \ | |
961 | check-gcc | |
962 | ||
79337c85 | 963 | # Installation targets. |
4d714963 | 964 | |
04103845 | 965 | .PHONY: install uninstall source-vault binary-vault vault-install |
98a33b6d | 966 | install: $(INSTALL_TARGET) |
b26ff9d8 | 967 | |
79337c85 ILT |
968 | uninstall: |
969 | @echo "the uninstall target is not supported in this tree" | |
970 | ||
04103845 DE |
971 | source-vault: |
972 | $(MAKE) -f ./release/Build-A-Release \ | |
973 | host=$(host_alias) source-vault | |
974 | ||
975 | binary-vault: | |
976 | $(MAKE) -f ./release/Build-A-Release \ | |
977 | host=$(host_alias) target=$(target_alias) | |
978 | ||
275049c0 JK |
979 | vault-install: |
980 | @if [ -f ./release/vault-install ] ; then \ | |
981 | ./release/vault-install $(host_alias) $(target_alias) ; \ | |
96bfa612 KR |
982 | else \ |
983 | true ; \ | |
275049c0 JK |
984 | fi |
985 | ||
79337c85 | 986 | .PHONY: install.all |
06a07944 RP |
987 | install.all: install-no-fixedincludes |
988 | @if [ -f ./gcc/Makefile ] ; then \ | |
5cc73086 | 989 | r=`pwd` ; export r ; \ |
b6ae0f10 | 990 | $(SET_LIB_PATH) \ |
06a07944 RP |
991 | (cd ./gcc; \ |
992 | $(MAKE) $(FLAGS_TO_PASS) install-headers) ; \ | |
993 | else \ | |
994 | true ; \ | |
995 | fi | |
5a63b336 | 996 | |
424c7ca7 | 997 | # inet-install is used because the I*Net wants DejaGNU installed but |
f2b43566 | 998 | # not built. Similarly, gzip is built but not installed. |
424c7ca7 | 999 | inet-install: |
f2b43566 | 1000 | $(MAKE) INSTALL_MODULES="`echo $(INSTALL_MODULES) | sed -e 's/install-dejagnu//' -e 's/install-gzip//'`" install |
424c7ca7 | 1001 | |
96bfa612 | 1002 | # install-no-fixedincludes is used because Cygnus can not distribute |
79337c85 ILT |
1003 | # the fixed header files. |
1004 | .PHONY: install-no-fixedincludes | |
1005 | install-no-fixedincludes: \ | |
ff290baf | 1006 | installdirs \ |
79337c85 ILT |
1007 | $(INSTALL_MODULES) \ |
1008 | $(INSTALL_TARGET_MODULES) \ | |
96bfa612 | 1009 | $(INSTALL_X11_MODULES) \ |
f35c6160 | 1010 | gcc-no-fixedincludes |
d1bea4c7 | 1011 | |
5cc24596 | 1012 | # Install the gcc headers files, but not the fixed include files, |
79337c85 ILT |
1013 | # which Cygnus is not allowed to distribute. This rule is very |
1014 | # dependent on the workings of the gcc Makefile.in. | |
1015 | .PHONY: gcc-no-fixedincludes | |
06a07944 | 1016 | gcc-no-fixedincludes: |
5cc24596 PB |
1017 | @if [ -f ./gcc/Makefile ]; then \ |
1018 | rm -rf gcc/tmp-include; \ | |
1019 | mv gcc/include gcc/tmp-include 2>/dev/null; \ | |
1020 | mkdir gcc/include; \ | |
7f9cb3b2 | 1021 | cp $(srcdir)/gcc/gsyslimits.h gcc/include/syslimits.h; \ |
753d5049 | 1022 | touch gcc/stmp-fixinc gcc/include/fixed; \ |
a54e05f6 | 1023 | rm -f gcc/stmp-headers gcc/stmp-int-hdrs; \ |
5cc73086 | 1024 | r=`pwd`; export r; \ |
81eb5025 | 1025 | s=`cd $(srcdir); pwd` ; export s; \ |
b6ae0f10 | 1026 | $(SET_LIB_PATH) \ |
5cc24596 PB |
1027 | (cd ./gcc; \ |
1028 | $(MAKE) $(GCC_FLAGS_TO_PASS) install); \ | |
1029 | rm -rf gcc/include; \ | |
1030 | mv gcc/tmp-include gcc/include 2>/dev/null; \ | |
1031 | else true; fi | |
dcbfc14d | 1032 | |
79337c85 ILT |
1033 | # This rule is used to build the modules which use FLAGS_TO_PASS. To |
1034 | # build a target all-X means to cd to X and make all. | |
3de70f1d | 1035 | # |
055cca84 | 1036 | # all-gui, and all-libproc are handled specially because |
4d802af9 MT |
1037 | # they are still experimental, and if they fail to build, that |
1038 | # shouldn't stop "make all". | |
04103845 DE |
1039 | .PHONY: $(ALL_MODULES) all-gui all-libproc |
1040 | $(ALL_MODULES) all-gui all-libproc: | |
79337c85 | 1041 | @dir=`echo $@ | sed -e 's/all-//'`; \ |
472af17f ILT |
1042 | if [ -f ./$${dir}/Makefile ] ; then \ |
1043 | r=`pwd`; export r; \ | |
81eb5025 | 1044 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1045 | $(SET_LIB_PATH) \ |
472af17f | 1046 | (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) all); \ |
07362bd9 | 1047 | else \ |
79337c85 | 1048 | true; \ |
07362bd9 DZ |
1049 | fi |
1050 | ||
80cbf870 ILT |
1051 | # These rules are used to check the modules which use FLAGS_TO_PASS. |
1052 | # To build a target check-X means to cd to X and make check. Some | |
1053 | # modules are only tested in a native toolchain. | |
4f0b8f27 | 1054 | |
d237841c BC |
1055 | .PHONY: $(CHECK_MODULES) $(NATIVE_CHECK_MODULES) $(CROSS_CHECK_MODULES) |
1056 | $(NATIVE_CHECK_MODULES): | |
39cc6dae RS |
1057 | @if [ "$(host_canonical)" = "$(target_canonical)" ] ; then \ |
1058 | dir=`echo $@ | sed -e 's/check-//'`; \ | |
472af17f ILT |
1059 | if [ -f ./$${dir}/Makefile ] ; then \ |
1060 | r=`pwd`; export r; \ | |
81eb5025 | 1061 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1062 | $(SET_LIB_PATH) \ |
472af17f ILT |
1063 | (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) check); \ |
1064 | else \ | |
1065 | true; \ | |
4f0b8f27 TL |
1066 | fi; \ |
1067 | fi | |
1068 | ||
1069 | $(CROSS_CHECK_MODULES): | |
6a42d184 DZ |
1070 | @dir=`echo $@ | sed -e 's/check-//'`; \ |
1071 | if [ -f ./$${dir}/Makefile ] ; then \ | |
5cc73086 | 1072 | r=`pwd`; export r; \ |
81eb5025 | 1073 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1074 | $(SET_LIB_PATH) \ |
6a42d184 DZ |
1075 | (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) check); \ |
1076 | else \ | |
1077 | true; \ | |
1078 | fi | |
1079 | ||
79337c85 ILT |
1080 | # This rule is used to install the modules which use FLAGS_TO_PASS. |
1081 | # To build a target install-X means to cd to X and make install. | |
1082 | .PHONY: $(INSTALL_MODULES) | |
ff290baf | 1083 | $(INSTALL_MODULES): installdirs |
79337c85 ILT |
1084 | @dir=`echo $@ | sed -e 's/install-//'`; \ |
1085 | if [ -f ./$${dir}/Makefile ] ; then \ | |
5cc73086 | 1086 | r=`pwd`; export r; \ |
81eb5025 | 1087 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1088 | $(SET_LIB_PATH) \ |
f35c6160 | 1089 | (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) install); \ |
07362bd9 | 1090 | else \ |
79337c85 | 1091 | true; \ |
07362bd9 DZ |
1092 | fi |
1093 | ||
ca2ce3b3 ILT |
1094 | # This rule is used to configure the modules which are built with the |
1095 | # target tools. | |
1096 | .PHONY: $(CONFIGURE_TARGET_MODULES) | |
1097 | $(CONFIGURE_TARGET_MODULES): | |
ab1cbc67 | 1098 | @dir=`echo $@ | sed -e 's/configure-target-//'`; \ |
354a86c7 | 1099 | if [ -d $(TARGET_SUBDIR)/$${dir} ]; then \ |
59d3634c | 1100 | r=`pwd`; export r; \ |
f2b43566 ILT |
1101 | $(CC_FOR_TARGET) --print-multi-lib > $(TARGET_SUBDIR)/$${dir}/tmpmulti.out 2> /dev/null; \ |
1102 | if [ -s $(TARGET_SUBDIR)/$${dir}/tmpmulti.out ]; then \ | |
1103 | if [ -f $(TARGET_SUBDIR)/$${dir}/multilib.out ]; then \ | |
1104 | if cmp $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/tmpmulti.out > /dev/null; then \ | |
1105 | rm -f $(TARGET_SUBDIR)/$${dir}/tmpmulti.out; \ | |
1106 | else \ | |
1107 | echo "Multilibs changed for $${dir}, reconfiguring"; \ | |
1108 | rm -f $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/Makefile; \ | |
1109 | mv $(TARGET_SUBDIR)/$${dir}/tmpmulti.out $(TARGET_SUBDIR)/$${dir}/multilib.out; \ | |
1110 | fi; \ | |
354a86c7 | 1111 | else \ |
354a86c7 MM |
1112 | mv $(TARGET_SUBDIR)/$${dir}/tmpmulti.out $(TARGET_SUBDIR)/$${dir}/multilib.out; \ |
1113 | fi; \ | |
062aded9 | 1114 | fi; \ |
354a86c7 MM |
1115 | fi; exit 0 # break command into two pieces |
1116 | @dir=`echo $@ | sed -e 's/configure-target-//'`; \ | |
3e288e27 SG |
1117 | if [ ! -d $(TARGET_SUBDIR) ]; then \ |
1118 | true; \ | |
1119 | elif [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \ | |
ca2ce3b3 ILT |
1120 | true; \ |
1121 | elif echo " $(TARGET_CONFIGDIRS) " | grep " $${dir} " >/dev/null 2>&1; then \ | |
efd7b806 | 1122 | if [ -d $(srcdir)/$${dir} ]; then \ |
ab1cbc67 | 1123 | [ -d $(TARGET_SUBDIR)/$${dir} ] || mkdir $(TARGET_SUBDIR)/$${dir};\ |
efd7b806 | 1124 | r=`pwd`; export r; \ |
81eb5025 | 1125 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1126 | $(SET_LIB_PATH) \ |
efd7b806 SC |
1127 | AR="$(AR_FOR_TARGET)"; export AR; \ |
1128 | AS="$(AS_FOR_TARGET)"; export AS; \ | |
1129 | CC="$(CC_FOR_TARGET)"; export CC; \ | |
1130 | CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \ | |
1131 | CXX="$(CXX_FOR_TARGET)"; export CXX; \ | |
1132 | CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \ | |
b6ae0f10 | 1133 | DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \ |
054f9ada | 1134 | LD="$(LD_FOR_TARGET)"; export LD; \ |
276c2d7d | 1135 | LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \ |
efd7b806 SC |
1136 | NM="$(NM_FOR_TARGET)"; export NM; \ |
1137 | RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \ | |
19b1d034 | 1138 | echo Configuring in $(TARGET_SUBDIR)/$${dir}; \ |
ab1cbc67 | 1139 | cd $(TARGET_SUBDIR)/$${dir}; \ |
283a2b3d DE |
1140 | case $(srcdir) in \ |
1141 | /*) \ | |
1142 | topdir=$(srcdir) ;; \ | |
1143 | *) \ | |
1144 | case "$(TARGET_SUBDIR)" in \ | |
1145 | .) topdir="../$(srcdir)" ;; \ | |
1146 | *) topdir="../../$(srcdir)" ;; \ | |
1147 | esac ;; \ | |
1148 | esac; \ | |
1149 | if [ "$(srcdir)" = "." ] ; then \ | |
1150 | if [ "$(TARGET_SUBDIR)" != "." ] ; then \ | |
81eb5025 | 1151 | if $(SHELL) $$s/symlink-tree $${topdir}/$${dir} "no-such-file" ; then \ |
0f8f1d33 TT |
1152 | if [ -f Makefile ]; then \ |
1153 | if $(MAKE) distclean; then \ | |
1154 | true; \ | |
1155 | else \ | |
1156 | exit 1; \ | |
1157 | fi; \ | |
1158 | else \ | |
1159 | true; \ | |
1160 | fi; \ | |
283a2b3d DE |
1161 | else \ |
1162 | exit 1; \ | |
1163 | fi; \ | |
1164 | else \ | |
1165 | true; \ | |
1166 | fi; \ | |
1167 | srcdiroption="--srcdir=."; \ | |
1168 | libsrcdir="."; \ | |
1169 | else \ | |
1170 | srcdiroption="--srcdir=$${topdir}/$${dir}"; \ | |
81eb5025 | 1171 | libsrcdir="$$s/$${dir}"; \ |
283a2b3d DE |
1172 | fi; \ |
1173 | if [ -f $${libsrcdir}/configure ] ; then \ | |
1174 | $(SHELL) $${libsrcdir}/configure \ | |
1175 | $(CONFIG_ARGUMENTS) $${srcdiroption} \ | |
1176 | --with-target-subdir="$(TARGET_SUBDIR)"; \ | |
19b1d034 | 1177 | else \ |
81eb5025 | 1178 | $(SHELL) $$s/configure \ |
283a2b3d DE |
1179 | $(CONFIG_ARGUMENTS) $${srcdiroption} \ |
1180 | --with-target-subdir="$(TARGET_SUBDIR)"; \ | |
19b1d034 | 1181 | fi; \ |
efd7b806 SC |
1182 | else \ |
1183 | true; \ | |
9908eb6a | 1184 | fi; \ |
ca2ce3b3 ILT |
1185 | else \ |
1186 | true; \ | |
1187 | fi | |
1188 | ||
6a42d184 DZ |
1189 | # This rule is used to build the modules which use TARGET_FLAGS_TO_PASS. |
1190 | # To build a target all-X means to cd to X and make all. | |
79337c85 ILT |
1191 | .PHONY: $(ALL_TARGET_MODULES) |
1192 | $(ALL_TARGET_MODULES): | |
ab1cbc67 PB |
1193 | @dir=`echo $@ | sed -e 's/all-target-//'`; \ |
1194 | if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \ | |
5cc73086 | 1195 | r=`pwd`; export r; \ |
81eb5025 | 1196 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1197 | $(SET_LIB_PATH) \ |
ab1cbc67 | 1198 | (cd $(TARGET_SUBDIR)/$${dir}; $(MAKE) $(TARGET_FLAGS_TO_PASS) all); \ |
07362bd9 | 1199 | else \ |
79337c85 | 1200 | true; \ |
07362bd9 DZ |
1201 | fi |
1202 | ||
6a42d184 DZ |
1203 | # This rule is used to check the modules which use TARGET_FLAGS_TO_PASS. |
1204 | # To build a target install-X means to cd to X and make install. | |
1205 | .PHONY: $(CHECK_TARGET_MODULES) | |
1206 | $(CHECK_TARGET_MODULES): | |
136ca05d | 1207 | @dir=`echo $@ | sed -e 's/check-target-//'`; \ |
ab1cbc67 | 1208 | if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \ |
5cc73086 | 1209 | r=`pwd`; export r; \ |
81eb5025 | 1210 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1211 | $(SET_LIB_PATH) \ |
ab1cbc67 | 1212 | (cd $(TARGET_SUBDIR)/$${dir};$(MAKE) $(TARGET_FLAGS_TO_PASS) check);\ |
6a42d184 DZ |
1213 | else \ |
1214 | true; \ | |
1215 | fi | |
1216 | ||
79337c85 ILT |
1217 | # This rule is used to install the modules which use |
1218 | # TARGET_FLAGS_TO_PASS. To build a target install-X means to cd to X | |
1219 | # and make install. | |
1220 | .PHONY: $(INSTALL_TARGET_MODULES) | |
ff290baf | 1221 | $(INSTALL_TARGET_MODULES): installdirs |
ab1cbc67 PB |
1222 | @dir=`echo $@ | sed -e 's/install-target-//'`; \ |
1223 | if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \ | |
5cc73086 | 1224 | r=`pwd`; export r; \ |
81eb5025 | 1225 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1226 | $(SET_LIB_PATH) \ |
ab1cbc67 PB |
1227 | (cd $(TARGET_SUBDIR)/$${dir}; \ |
1228 | $(MAKE) $(TARGET_FLAGS_TO_PASS) install); \ | |
07362bd9 | 1229 | else \ |
79337c85 | 1230 | true; \ |
07362bd9 DZ |
1231 | fi |
1232 | ||
6a42d184 | 1233 | # This rule is used to build the modules which use X11_FLAGS_TO_PASS. |
79337c85 ILT |
1234 | # To build a target all-X means to cd to X and make all. |
1235 | .PHONY: $(ALL_X11_MODULES) | |
1236 | $(ALL_X11_MODULES): | |
1237 | @dir=`echo $@ | sed -e 's/all-//'`; \ | |
1238 | if [ -f ./$${dir}/Makefile ] ; then \ | |
5cc73086 | 1239 | r=`pwd`; export r; \ |
81eb5025 | 1240 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1241 | $(SET_LIB_PATH) \ |
79337c85 ILT |
1242 | (cd $${dir}; \ |
1243 | $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all); \ | |
07362bd9 | 1244 | else \ |
79337c85 | 1245 | true; \ |
07362bd9 DZ |
1246 | fi |
1247 | ||
6a42d184 DZ |
1248 | # This rule is used to check the modules which use X11_FLAGS_TO_PASS. |
1249 | # To build a target check-X means to cd to X and make all. | |
1250 | .PHONY: $(CHECK_X11_MODULES) | |
1251 | $(CHECK_X11_MODULES): | |
1252 | @dir=`echo $@ | sed -e 's/check-//'`; \ | |
1253 | if [ -f ./$${dir}/Makefile ] ; then \ | |
5cc73086 | 1254 | r=`pwd`; export r; \ |
81eb5025 | 1255 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1256 | $(SET_LIB_PATH) \ |
6a42d184 DZ |
1257 | (cd $${dir}; \ |
1258 | $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check); \ | |
1259 | else \ | |
1260 | true; \ | |
1261 | fi | |
1262 | ||
1263 | # This rule is used to install the modules which use X11_FLAGS_TO_PASS. | |
79337c85 ILT |
1264 | # To build a target install-X means to cd to X and make install. |
1265 | .PHONY: $(INSTALL_X11_MODULES) | |
1266 | $(INSTALL_X11_MODULES): | |
6a42d184 | 1267 | @dir=`echo $@ | sed -e 's/install-//'`; \ |
79337c85 | 1268 | if [ -f ./$${dir}/Makefile ] ; then \ |
5cc73086 | 1269 | r=`pwd`; export r; \ |
81eb5025 | 1270 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1271 | $(SET_LIB_PATH) \ |
79337c85 ILT |
1272 | (cd $${dir}; \ |
1273 | $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) install); \ | |
07362bd9 | 1274 | else \ |
79337c85 | 1275 | true; \ |
07362bd9 DZ |
1276 | fi |
1277 | ||
79337c85 ILT |
1278 | # gcc is the only module which uses GCC_FLAGS_TO_PASS. |
1279 | .PHONY: all-gcc | |
1280 | all-gcc: | |
1281 | @if [ -f ./gcc/Makefile ] ; then \ | |
5cc73086 | 1282 | r=`pwd`; export r; \ |
81eb5025 | 1283 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1284 | $(SET_LIB_PATH) \ |
79337c85 | 1285 | (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) all); \ |
07362bd9 | 1286 | else \ |
79337c85 | 1287 | true; \ |
07362bd9 DZ |
1288 | fi |
1289 | ||
4c0b7ebc DE |
1290 | .PHONY: all-bootstrap |
1291 | all-bootstrap: | |
1292 | @if [ -f ./gcc/Makefile ] ; then \ | |
1293 | r=`pwd`; export r; \ | |
81eb5025 | 1294 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1295 | $(SET_LIB_PATH) \ |
4c0b7ebc DE |
1296 | (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) bootstrap); \ |
1297 | else \ | |
1298 | true; \ | |
1299 | fi | |
1300 | ||
65088029 ILT |
1301 | .PHONY: check-gcc |
1302 | check-gcc: | |
1303 | @if [ -f ./gcc/Makefile ] ; then \ | |
5cc73086 | 1304 | r=`pwd`; export r; \ |
81eb5025 | 1305 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1306 | $(SET_LIB_PATH) \ |
65088029 ILT |
1307 | (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) check); \ |
1308 | else \ | |
1309 | true; \ | |
1310 | fi | |
1311 | ||
79337c85 ILT |
1312 | .PHONY: install-gcc |
1313 | install-gcc: | |
1314 | @if [ -f ./gcc/Makefile ] ; then \ | |
5cc73086 | 1315 | r=`pwd`; export r; \ |
81eb5025 | 1316 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1317 | $(SET_LIB_PATH) \ |
79337c85 | 1318 | (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) install); \ |
07362bd9 | 1319 | else \ |
79337c85 | 1320 | true; \ |
07362bd9 DZ |
1321 | fi |
1322 | ||
753d5049 SC |
1323 | |
1324 | # EXPERIMENTAL STUFF | |
1325 | # This rule is used to install the modules which use FLAGS_TO_PASS. | |
1326 | # To build a target install-X means to cd to X and make install. | |
09985c96 | 1327 | .PHONY: install-dosrel |
ff290baf | 1328 | install-dosrel: installdirs info |
753d5049 SC |
1329 | @dir=`echo $@ | sed -e 's/install-//'`; \ |
1330 | if [ -f ./$${dir}/Makefile ] ; then \ | |
1331 | r=`pwd`; export r; \ | |
81eb5025 | 1332 | s=`cd $(srcdir); pwd`; export s; \ |
b6ae0f10 | 1333 | $(SET_LIB_PATH) \ |
753d5049 SC |
1334 | (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) install); \ |
1335 | else \ | |
1336 | true; \ | |
1337 | fi | |
1338 | ||
09985c96 | 1339 | install-dosrel-fake: |
a987271c | 1340 | |
753d5049 | 1341 | |
79337c85 | 1342 | # This is a list of inter-dependencies among modules. |
53c403df | 1343 | all-apache: |
65e21701 | 1344 | all-autoconf: all-m4 |
08168809 | 1345 | all-automake: |
5db223e4 | 1346 | all-bash: |
79337c85 | 1347 | all-bfd: |
dfe44004 | 1348 | all-binutils: all-libiberty all-opcodes all-bfd all-flex all-byacc |
79337c85 | 1349 | all-byacc: |
79337c85 | 1350 | all-cvs: |
2e482734 | 1351 | all-db: |
4d802af9 | 1352 | all-dejagnu: all-tcl all-expect all-tk |
79337c85 ILT |
1353 | all-diff: all-libiberty |
1354 | all-emacs: | |
1d5fcc66 | 1355 | all-emacs19: all-byacc |
79337c85 | 1356 | all-etc: |
4c0b7ebc DE |
1357 | configure-target-examples: $(ALL_GCC) |
1358 | all-target-examples: configure-target-examples | |
c6ba9ae0 | 1359 | all-expect: all-tcl all-tk |
275049c0 | 1360 | all-fileutils: all-libiberty |
97840afa | 1361 | all-findutils: |
79337c85 | 1362 | all-find: |
7dcc0664 | 1363 | all-flex: all-libiberty all-byacc |
79337c85 | 1364 | all-gas: all-libiberty all-opcodes all-bfd |
65e21701 | 1365 | all-gash: all-tcl |
79337c85 | 1366 | all-gawk: |
fc3524a9 | 1367 | ALL_GCC = all-gcc |
3718029f | 1368 | all-gcc: all-byacc all-binutils all-gas all-ld |
4c0b7ebc | 1369 | all-bootstrap: all-libiberty all-byacc all-binutils all-gas all-ld |
01082eaf MM |
1370 | GDB_TK = all-tk all-tcl |
1371 | all-gdb: all-libiberty all-opcodes all-bfd all-mmalloc all-readline all-byacc all-sim $(gdbnlmrequirements) $(GDB_TK) | |
ba26181f | 1372 | all-gnuserv: |
b6ae0f10 | 1373 | all-gprof: all-libiberty all-bfd all-opcodes |
6214eb23 | 1374 | all-grep: all-libiberty |
b6ae0f10 | 1375 | all-grez: all-libiberty all-bfd all-opcodes |
ab1cbc67 | 1376 | all-gui: all-gdb all-libproc all-target-librx |
0f8f1d33 | 1377 | all-guile: |
79337c85 ILT |
1378 | all-gzip: all-libiberty |
1379 | all-hello: all-libiberty | |
3718029f ILT |
1380 | # start-sanitize-ide |
1381 | all-ilu: | |
1382 | # end-sanitize-ide | |
79337c85 | 1383 | all-indent: |
8d1d94b6 | 1384 | all-inet: all-tcl all-send-pr all-perl |
3585593d | 1385 | all-ispell: all-emacs19 |
754a6784 | 1386 | all-itcl: all-tcl all-tk |
b6ae0f10 | 1387 | all-ld: all-libiberty all-bfd all-opcodes all-byacc all-flex |
283a2b3d | 1388 | configure-target-libg++: $(ALL_GCC) configure-target-librx |
ab1cbc67 PB |
1389 | all-target-libg++: configure-target-libg++ all-gas all-ld all-gcc all-target-libiberty all-target-newlib all-target-libio all-target-librx all-target-libstdc++ |
1390 | configure-target-libgloss: $(ALL_GCC) | |
283a2b3d | 1391 | all-target-libgloss: configure-target-libgloss configure-target-newlib |
ab1cbc67 PB |
1392 | configure-target-libio: $(ALL_GCC) |
1393 | all-target-libio: configure-target-libio all-gas all-ld all-gcc all-target-libiberty all-target-newlib | |
79337c85 | 1394 | all-libiberty: |
eebe454c | 1395 | # start-sanitize-ide |
8d74b2fa | 1396 | all-libide: all-tcl all-tk all-itcl all-ilu |
eebe454c | 1397 | # end-sanitize-ide |
ab1cbc67 PB |
1398 | configure-target-librx: $(ALL_GCC) configure-target-newlib |
1399 | all-target-librx: configure-target-librx | |
1400 | configure-target-libstdc++: $(ALL_GCC) | |
1401 | all-target-libstdc++: configure-target-libstdc++ all-gas all-ld all-gcc all-target-libiberty all-target-newlib all-target-libio | |
79337c85 ILT |
1402 | all-m4: all-libiberty |
1403 | all-make: all-libiberty | |
1404 | all-mmalloc: | |
ab1cbc67 PB |
1405 | configure-target-newlib: $(ALL_GCC) |
1406 | all-target-newlib: configure-target-newlib all-binutils all-gas all-gcc | |
b6ae0f10 | 1407 | all-opcodes: all-bfd all-libiberty |
be2c65d3 | 1408 | all-patch: all-libiberty |
0f8f1d33 | 1409 | all-perl: |
b255ccdb | 1410 | all-prms: all-libiberty |
79337c85 ILT |
1411 | all-rcs: |
1412 | all-readline: | |
1413 | all-recode: all-libiberty | |
ac259c28 JM |
1414 | all-sed: all-libiberty |
1415 | all-send-pr: all-prms | |
79337c85 | 1416 | all-shellutils: |
b6ae0f10 | 1417 | all-sim: all-libiberty all-bfd all-opcodes |
2e482734 | 1418 | all-sn: all-tcl all-tk all-itcl all-db |
07362bd9 | 1419 | all-tar: all-libiberty |
79337c85 ILT |
1420 | all-tcl: |
1421 | all-tclX: all-tcl all-tk | |
1422 | all-tk: all-tcl | |
1423 | all-texinfo: all-libiberty | |
1424 | all-textutils: | |
b6ae0f10 | 1425 | all-tgas: all-libiberty all-bfd all-opcodes |
79337c85 | 1426 | all-time: |
eebe454c TT |
1427 | # start-sanitize-ide |
1428 | all-vmake: all-tcl all-tk all-itcl all-libide | |
1429 | # end-sanitize-ide | |
79337c85 | 1430 | all-wdiff: |
97840afa | 1431 | all-target-winsup: all-target-newlib all-target-libiberty all-target-librx all-target-libio configure-target-winsup |
ab1cbc67 | 1432 | configure-target-winsup: configure-target-newlib |
79337c85 | 1433 | all-uudecode: all-libiberty |
ab1cbc67 PB |
1434 | configure-target-libiberty: $(ALL_GCC) |
1435 | all-target-libiberty: configure-target-libiberty all-gcc all-ld all-target-newlib | |
0f8f1d33 TT |
1436 | all-target: $(ALL_TARGET_MODULES) |
1437 | install-target: $(INSTALL_TARGET_MODULES) | |
07362bd9 | 1438 | |
79337c85 | 1439 | ### other supporting targets |
07362bd9 | 1440 | |
79337c85 ILT |
1441 | MAKEDIRS= \ |
1442 | $(prefix) \ | |
9deb9485 | 1443 | $(exec_prefix) |
ff290baf ILT |
1444 | .PHONY: installdirs |
1445 | installdirs: mkinstalldirs | |
fab3dd2d | 1446 | $(SHELL) $(srcdir)/mkinstalldirs $(MAKEDIRS) |
23e3e7f9 | 1447 | |
79337c85 ILT |
1448 | dir.info: do-install-info |
1449 | if [ -f $(srcdir)/texinfo/gen-info-dir ] ; then \ | |
1450 | $(srcdir)/texinfo/gen-info-dir $(infodir) $(srcdir)/texinfo/dir.info-template > dir.info.new ; \ | |
1451 | mv -f dir.info.new dir.info ; \ | |
1452 | else true ; \ | |
72c09fbc | 1453 | fi |
6b7e5998 | 1454 | |
b1cceba2 DZ |
1455 | dist: |
1456 | @echo "Building a full distribution of this tree isn't done" | |
1457 | @echo "via 'make dist'. Check out the etc/ subdirectory" | |
1458 | ||
eb02fd64 RP |
1459 | etags tags: TAGS |
1460 | ||
753d5049 SC |
1461 | # Right now this just builds TAGS in each subdirectory. emacs19 has the |
1462 | # ability to use several tags files at once, so there is probably no need | |
1463 | # to combine them into one big TAGS file (like CVS 1.3 does). We could | |
1464 | # (if we felt like it) have this Makefile write a piece of elisp which | |
1465 | # the user could load to tell emacs19 where all the TAGS files we just | |
1466 | # built are. | |
1467 | TAGS: do-TAGS | |
eb02fd64 | 1468 | |
eb02fd64 RP |
1469 | # with the gnu make, this is done automatically. |
1470 | ||
01ec9588 | 1471 | Makefile: Makefile.in configure.in $(host_makefile_frag) $(target_makefile_frag) |
a26878d1 | 1472 | $(SHELL) ./config.status |
eb02fd64 | 1473 | |
11954bf1 | 1474 | # |
01ec9588 | 1475 | # Support for building net releases |
11954bf1 | 1476 | |
01ec9588 JK |
1477 | # Files in devo used in any net release. |
1478 | # ChangeLog omitted because it may refer to files which are not in this | |
1479 | # distribution (perhaps it would be better to include it anyway). | |
d94d255d | 1480 | DEVO_SUPPORT= README Makefile.in configure configure.in \ |
9823504d | 1481 | config.guess config.sub config move-if-change \ |
5f69e8bc | 1482 | mpw-README mpw-build.in mpw-config.in mpw-configure mpw-install \ |
08499fc2 ILT |
1483 | COPYING COPYING.LIB install-sh config-ml.in symlink-tree \ |
1484 | mkinstalldirs | |
01ec9588 JK |
1485 | |
1486 | # Files in devo/etc used in any net release. | |
1487 | # ChangeLog omitted because it may refer to files which are not in this | |
1488 | # distribution (perhaps it would be better to include it anyway). | |
f046ec67 JM |
1489 | ETC_SUPPORT= Makefile.in configure configure.in standards.texi \ |
1490 | make-stds.texi standards.info* | |
01ec9588 | 1491 | |
40e16078 KR |
1492 | # When you use `make setup-dirs' or `make taz' you should always redefine |
1493 | # this macro. | |
1494 | SUPPORT_FILES = list-of-support-files-for-tool-in-question | |
65e21701 | 1495 | # Files where "byacc" (Cygnus version) should be changed to "bison -y" (FSF). |
3718029f | 1496 | DISTBISONFILES= binutils/Makefile.in gas/Makefile.in gdb/Makefile.in ld/Makefile.in |
40e16078 | 1497 | |
a54e05f6 KR |
1498 | .PHONY: taz |
1499 | ||
484fa12d JW |
1500 | taz: $(DEVO_SUPPORT) $(SUPPORT_FILES) \ |
1501 | texinfo/texinfo.tex texinfo/gpl.texinfo texinfo/lgpl.texinfo | |
1502 | # Make sure "diststuff" files get built properly. | |
65e21701 KR |
1503 | for f in $(DISTBISONFILES) ; do \ |
1504 | if [ -r $$f ]; then \ | |
7b636683 | 1505 | sed '/^BISON *=.*$$/s/.*/BISON = bison -y/' <$$f >tmp ; \ |
65e21701 KR |
1506 | mv -f tmp $$f ; \ |
1507 | else true; fi ; \ | |
1508 | done | |
484fa12d JW |
1509 | # Take out texinfo from a few places; make simple BISON=bison line. |
1510 | sed -e '/^all\.normal: /s/\all-texinfo //' \ | |
1511 | -e '/^ install-texinfo /d' \ | |
64434418 | 1512 | -e '/^BISON = `if/,/^$$/d' \ |
484fa12d JW |
1513 | -e '/^# BISON:/s/.*/BISON = bison -y/' \ |
1514 | <Makefile.in >tmp | |
1515 | mv -f tmp Makefile.in | |
65e21701 | 1516 | # |
1d5fcc66 PB |
1517 | $(start-sanitize-Sanitize) |
1518 | @if [ -f .Sanitize ] ; then echo "RUN Sanitize FIRST!" ; false ; fi ; | |
1519 | $(end-sanitize-Sanitize) | |
40e16078 | 1520 | ./configure sun4 |
ab1cbc67 PB |
1521 | [ -z "$(CONFIGURE_TARGET_MODULES)" ] \ |
1522 | || $(MAKE) $(CONFIGURE_TARGET_MODULES) ALL_GCC="" \ | |
aaefc574 | 1523 | CC_FOR_TARGET="$(CC)" CXX_FOR_TARGET="$(CXX)" |
6b9e3a78 | 1524 | # Make links, and run "make diststuff" or "make info" when needed. |
a54e05f6 | 1525 | rm -rf proto-toplev ; mkdir proto-toplev |
7f9cb3b2 | 1526 | set -e ; dirs="$(TOOL) $(DEVO_SUPPORT) $(SUPPORT_FILES)" ; \ |
a54e05f6 KR |
1527 | for d in $$dirs ; do \ |
1528 | if [ -d $$d ]; then \ | |
ab1cbc67 PB |
1529 | if [ ! -f $$d/Makefile ] ; then true ; \ |
1530 | elif grep '^diststuff:' $$d/Makefile >/dev/null ; then \ | |
1531 | (cd $$d ; $(MAKE) diststuff ) || exit 1 ; \ | |
6b9e3a78 | 1532 | elif grep '^info:' $$d/Makefile >/dev/null ; then \ |
ab1cbc67 | 1533 | (cd $$d ; $(MAKE) info ) || exit 1 ; \ |
6b9e3a78 | 1534 | fi ; \ |
7f9cb3b2 KR |
1535 | if [ -d $$d/proto-$$d.dir ]; then \ |
1536 | ln -s ../$$d/proto-$$d.dir proto-toplev/$$d ; \ | |
1537 | else \ | |
1538 | ln -s ../$$d proto-toplev/$$d ; \ | |
1539 | fi ; \ | |
a54e05f6 | 1540 | else ln -s ../$$d proto-toplev/$$d ; fi ; \ |
40e16078 | 1541 | done |
3dbe0fa2 | 1542 | cd etc ; $(MAKE) info |
5600fbd2 | 1543 | $(MAKE) distclean |
a54e05f6 | 1544 | # |
40e16078 | 1545 | mkdir proto-toplev/etc |
15408b3b KR |
1546 | (cd proto-toplev/etc; \ |
1547 | for i in $(ETC_SUPPORT); do \ | |
40e16078 | 1548 | ln -s ../../etc/$$i . ; \ |
15408b3b | 1549 | done) |
a54e05f6 | 1550 | # |
04103845 | 1551 | # Take out texinfo from configurable dirs |
40e16078 KR |
1552 | rm proto-toplev/configure.in |
1553 | sed -e '/^host_tools=/s/texinfo //' \ | |
40e16078 | 1554 | <configure.in >proto-toplev/configure.in |
a54e05f6 | 1555 | # |
40e16078 | 1556 | mkdir proto-toplev/texinfo |
8d190aa3 KR |
1557 | ln -s ../../texinfo/texinfo.tex proto-toplev/texinfo/ |
1558 | ln -s ../../texinfo/gpl.texinfo proto-toplev/texinfo/ | |
1559 | ln -s ../../texinfo/lgpl.texinfo proto-toplev/texinfo/ | |
1560 | if test -r texinfo/util/tex3patch ; then \ | |
1561 | mkdir proto-toplev/texinfo/util && \ | |
1562 | ln -s ../../../texinfo/util/tex3patch proto-toplev/texinfo/util ; \ | |
1563 | else true; fi | |
a561909f | 1564 | chmod og=u `find . -print` |
b5dbae28 KR |
1565 | $(MAKE) -f Makefile.in do-tar-gz TOOL=$(TOOL) \ |
1566 | VER=`sed <$(TOOL)/Makefile.in -n 's/^VERSION *= *//p'` | |
1567 | ||
1568 | do-tar-gz: | |
1569 | echo "==> Making $(TOOL)-$(VER).tar.gz" | |
1570 | -rm -f $(TOOL)-$(VER) | |
1571 | ln -s proto-toplev $(TOOL)-$(VER) | |
1572 | tar cfh $(TOOL)-$(VER).tar $(TOOL)-$(VER) | |
1573 | $(GZIPPROG) -v -9 $(TOOL)-$(VER).tar | |
40e16078 | 1574 | |
484fa12d | 1575 | TEXINFO_SUPPORT= texinfo/texinfo.tex texinfo/gpl.texinfo texinfo/lgpl.texinfo |
7f9cb3b2 | 1576 | DIST_SUPPORT= $(DEVO_SUPPORT) $(TEXINFO_SUPPORT) |
40e16078 | 1577 | |
96bfa612 | 1578 | .PHONY: gas.tar.gz |
2e482734 | 1579 | GAS_SUPPORT_DIRS= bfd include libiberty opcodes setup.com makefile.vms |
96bfa612 | 1580 | gas.tar.gz: $(DIST_SUPPORT) $(GAS_SUPPORT_DIRS) gas |
484fa12d JW |
1581 | $(MAKE) -f Makefile.in taz TOOL=gas \ |
1582 | SUPPORT_FILES="$(GAS_SUPPORT_DIRS)" | |
40e16078 | 1583 | |
7f9cb3b2 | 1584 | # The FSF "binutils" release includes gprof and ld. |
96bfa612 | 1585 | .PHONY: binutils.tar.gz |
2e482734 | 1586 | BINUTILS_SUPPORT_DIRS= bfd gas include libiberty opcodes ld gprof setup.com makefile.vms |
96bfa612 | 1587 | binutils.tar.gz: $(DIST_SUPPORT) $(BINUTILS_SUPPORT_DIRS) binutils |
484fa12d | 1588 | $(MAKE) -f Makefile.in taz TOOL=binutils \ |
2492f942 | 1589 | SUPPORT_FILES="$(BINUTILS_SUPPORT_DIRS) makeall.bat configure.bat" |
7f9cb3b2 | 1590 | |
96bfa612 | 1591 | .PHONY: gas+binutils.tar.gz |
a54e05f6 | 1592 | GASB_SUPPORT_DIRS= $(GAS_SUPPORT_DIRS) binutils ld gprof |
96bfa612 | 1593 | gas+binutils.tar.gz: $(DIST_SUPPORT) $(GASB_SUPPORT_DIRS) gas |
484fa12d | 1594 | $(MAKE) -f Makefile.in taz TOOL=gas \ |
2492f942 | 1595 | SUPPORT_FILES="$(GASB_SUPPORT_DIRS) makeall.bat configure.bat" |
79337c85 | 1596 | |
5600fbd2 | 1597 | .PHONY: libg++.tar.gz |
ab1cbc67 | 1598 | LIBGXX_SUPPORT_DIRS=include libstdc++ libio librx libiberty |
5600fbd2 | 1599 | libg++.tar.gz: $(DIST_SUPPORT) libg++ |
484fa12d JW |
1600 | $(MAKE) -f Makefile.in taz TOOL=libg++ \ |
1601 | SUPPORT_FILES="$(LIBGXX_SUPPORT_DIRS)" | |
5600fbd2 | 1602 | |
49dfa984 JM |
1603 | GNATS_SUPPORT_DIRS=include libiberty send-pr |
1604 | gnats.tar.gz: $(DIST_SUPPORT) $(GNATS_SUPPORT_DIRS) gnats | |
a0bd8e18 | 1605 | $(MAKE) -f Makefile.in taz TOOL=gnats \ |
49dfa984 JM |
1606 | SUPPORT_FILES="$(GNATS_SUPPORT_DIRS)" |
1607 | ||
1d5fcc66 | 1608 | .PHONY: gdb.tar.gz |
81597186 | 1609 | GDB_SUPPORT_DIRS= bfd include libiberty mmalloc opcodes readline sim utils |
ca2ce3b3 | 1610 | GDBTK_SUPPORT_DIRS= `if [ -d tcl -a -d tk ] ; then echo tcl tk ; fi` |
1d5fcc66 PB |
1611 | gdb.tar.gz: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb |
1612 | $(MAKE) -f Makefile.in taz TOOL=gdb \ | |
ca2ce3b3 | 1613 | SUPPORT_FILES="$(GDB_SUPPORT_DIRS) $(GDBTK_SUPPORT_DIRS)" |
1d5fcc66 | 1614 | |
7166a308 | 1615 | .PHONY: newlib.tar.gz |
a220ba0f | 1616 | NEWLIB_SUPPORT_DIRS=libgloss |
04103845 | 1617 | # taz configures for the sun4 target which won't configure newlib. |
a220ba0f SC |
1618 | # We need newlib configured so that the .info files are made. |
1619 | # Unfortunately, it is not enough to just configure newlib separately: | |
1620 | # taz will build the .info files but since SUBDIRS won't contain newlib, | |
1621 | # distclean won't be run (leaving Makefile, config.status, and the tmp files | |
1622 | # used in building the .info files, eg: *.def, *.ref). | |
4c0b7ebc DE |
1623 | # The problem isn't solvable however without a lot of extra work because |
1624 | # target libraries are built in subdir $(target_alias) which gets nuked during | |
1625 | # the make distclean. For now punt on the issue of shipping newlib info files | |
1626 | # with newlib net releases and wait for a day when some native target (sun4?) | |
1627 | # supports newlib (if only minimally). | |
7166a308 KR |
1628 | newlib.tar.gz: $(DIST_SUPPORT) $(NEWLIB_SUPPORT_DIRS) newlib |
1629 | $(MAKE) -f Makefile.in taz TOOL=newlib \ | |
1630 | SUPPORT_FILES="$(NEWLIB_SUPPORT_DIRS)" \ | |
6b9e3a78 | 1631 | DEVO_SUPPORT="$(DEVO_SUPPORT) COPYING.NEWLIB" newlib |
7166a308 | 1632 | |
79337c85 | 1633 | .NOEXPORT: |
05992891 | 1634 | MAKEOVERRIDES= |
79337c85 ILT |
1635 | |
1636 | # start-sanitize-chill | |
1637 | ## This is ugly, but I don't want GNU make to put these variables in | |
1638 | ## the environment. Older makes will see this as a set of targets | |
1639 | ## with no dependencies and no actions. | |
1640 | unexport CHILLFLAGS CHILL_LIB CHILL_FOR_TARGET : | |
1641 | # end-sanitize-chill | |
1642 | ||
eb02fd64 | 1643 | # end of Makefile.in |