Patches from lvaro Lopes <alvieboy@alvie.com> to fix usage
[zpugcc.git] / toolchain / gcc / libgloss / Makefile.in
blob4e9c4c404bf745707564195c34eb68dc892635d9
1 # Top level makefile for libgloss
3 # Copyright (c) 1995, 1996 Cygnus Support
5 # The authors hereby grant permission to use, copy, modify, distribute,
6 # and license this software and its documentation for any purpose, provided
7 # that existing copyright notices are retained in all copies and that this
8 # notice is included verbatim in any distributions. No written agreement,
9 # license, or royalty fee is required for any of the authorized uses.
10 # Modifications to this software may be copyrighted by their authors
11 # and need not follow the licensing terms described here, provided that
12 # the new terms are clearly indicated on the first page of each file where
13 # they apply.
16 VPATH = @srcdir@
17 srcdir = @srcdir@
18 objdir = .
19 srcroot = $(srcdir)/../..
20 objroot = $(objdir)/../..
22 prefix = @prefix@
23 exec_prefix = @exec_prefix@
25 host_alias = @host_alias@
26 target_alias = @target_alias@
28 bindir = @bindir@
29 libdir = @libdir@
30 tooldir = $(exec_prefix)/$(target_alias)
32 TOP = .
33 SRCTOP = .
35 # Multilib support variables.
36 # TOP is used instead of MULTI{BUILD,SRC}TOP.
37 MULTISRCTOP =
38 MULTIBUILDTOP =
39 MULTIDIRS =
40 MULTISUBDIR =
41 MULTIDO = true
42 MULTICLEAN = true
44 INSTALL = @INSTALL@
45 INSTALL_PROGRAM = @INSTALL_PROGRAM@
46 INSTALL_DATA = @INSTALL_DATA@
48 SHELL = /bin/sh
50 CC = @CC@
52 AS = @AS@
53 AR = @AR@
54 LD = @LD@
55 RANLIB = @RANLIB@
57 AR_FLAGS = qv
58 BISON = bison
59 MAKEINFO = makeinfo
61 SUBDIRS = @subdirs@
63 .NOEXPORT:
64 MAKEOVERRIDES=
66 # Host specific makefile fragment comes in here.
67 @host_makefile_frag@
69 # These are roughly topologically sorted in order to make porting more
70 # streamlined.
71 FLAGS_TO_PASS = \
72 "CC=$(CC)" \
73 "CFLAGS=$(CFLAGS)" \
74 "AR=$(AR)" \
75 "RANLIB=$(RANLIB)" \
76 "AR_FLAGS=$(AR_FLAGS)" \
77 "MAKEINFO=$(MAKEINFO)" \
78 "AS=$(AS)" \
79 "LD=$(LD)" \
80 "CROSS_CFLAGS=$(CROSS_CFLAGS)" \
81 "TARGET_CFLAGS=$(TARGET_CFLAGS)" \
82 "exec_prefix=$(exec_prefix)" \
83 "prefix=$(prefix)" \
84 "tooldir=$(tooldir)" \
85 "INSTALL=$(INSTALL)" \
86 "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
87 "INSTALL_DATA=$(INSTALL_DATA)"
89 all: stmp-bsp force
90 @rootpre=`pwd`/; export rootpre; \
91 srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
92 $(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=all
94 stmp-bsp: force
95 @rootpre=`pwd`/; export rootpre; \
96 srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
97 for dir in .. ${SUBDIRS}; do \
98 if [ x$$dir != x.. ]; then \
99 if [ -d $$dir ]; then \
100 (cd $$dir; $(MAKE) $(FLAGS_TO_PASS)); \
101 else true; fi; \
102 else true; fi; \
103 done
105 install: force
106 @rootpre=`pwd`/; export rootpre; \
107 srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
108 for dir in .. ${SUBDIRS}; do \
109 if [ x$$dir != x.. ]; then \
110 if [ -d $$dir ]; then \
111 (cd $$dir; $(MAKE) $(FLAGS_TO_PASS) install); \
112 else true; fi; \
113 else true; fi; \
114 done
115 @rootpre=`pwd`/; export rootpre; \
116 srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
117 $(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=install
119 test: force
120 @rootpre=`pwd`/; export rootpre; \
121 srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
122 for dir in .. ${SUBDIRS}; do \
123 if [ x$$dir != x.. ]; then \
124 if [ -d $$dir ]; then \
125 (cd $$dir; $(MAKE) $(FLAGS_TO_PASS) test); \
126 else true; fi; \
127 else true; fi; \
128 done
129 @rootpre=`pwd`/; export rootpre; \
130 srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
131 $(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=test
133 clean-here:
134 -rm -f *~ core *.o a.out xgdb *.x
136 clean mostlyclean: clean-here
137 rootpre=`pwd`/; export rootpre; \
138 srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
139 $(MAKE) DO=$@ DODIRS="$(SUBDIRS)" $(FLAGS_TO_PASS) subdir_do; \
140 $(MULTICLEAN) multi-clean DO=$@
142 distclean maintainer-clean realclean: clean-here
143 -rm -f Makefile config.cache config.log config.status
144 -rm -f *-init.exp site.*
145 -rm -fr *.log summary detail *.sum
146 rootpre=`pwd`/; export rootpre; \
147 srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
148 $(MAKE) DO=$@ DODIRS="$(SUBDIRS)" $(FLAGS_TO_PASS) subdir_do; \
149 $(MULTICLEAN) multi-clean DO=$@
151 .PHONY: info install-info clean-info
152 subdir_do:
153 @rootpre=`pwd`/; export rootpre; \
154 srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
155 for i in .. $(DODIRS); do \
156 if [ x$$i != x.. ]; then \
157 if [ -f ./$$i/Makefile ]; then \
158 if (cd ./$$i; $(MAKE) $(FLAGS_TO_PASS) $(DO)); then \
159 true; \
160 else \
161 exit 1; \
162 fi; \
163 else true; fi; \
164 else true; fi; \
165 done
167 info dvi docs:
168 rootpre=`pwd`/; export rootpre; \
169 srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
170 $(MAKE) DO=$@ DODIRS=doc $(FLAGS_TO_PASS) subdir_do
172 install-info:
173 rootpre=`pwd`/; export rootpre; \
174 srcrootpre=`cd $(srcdir); pwd`/; export srcrootpre; \
175 $(MAKE) DO=$@ DODIRS=doc $(FLAGS_TO_PASS) subdir_do
177 clean-info:
179 force:
181 Makefile: Makefile.in config.status @host_makefile_frag_path@
182 $(SHELL) config.status
184 config.status: configure
185 $(SHELL) config.status --recheck