6ebf0c5ef04b51c26b366a1428f45097d362af92
[ncurses.git] / Ada95 / gen / Makefile.in
1 ##############################################################################
2 # Copyright (c) 1998 Free Software Foundation, Inc.                          #
3 #                                                                            #
4 # Permission is hereby granted, free of charge, to any person obtaining a    #
5 # copy of this software and associated documentation files (the "Software"), #
6 # to deal in the Software without restriction, including without limitation  #
7 # the rights to use, copy, modify, merge, publish, distribute, distribute    #
8 # with modifications, sublicense, and/or sell copies of the Software, and to #
9 # permit persons to whom the Software is furnished to do so, subject to the  #
10 # following conditions:                                                      #
11 #                                                                            #
12 # The above copyright notice and this permission notice shall be included in #
13 # all copies or substantial portions of the Software.                        #
14 #                                                                            #
15 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR #
16 # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,   #
17 # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL    #
18 # THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER      #
19 # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING    #
20 # FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER        #
21 # DEALINGS IN THE SOFTWARE.                                                  #
22 #                                                                            #
23 # Except as contained in this notice, the name(s) of the above copyright     #
24 # holders shall not be used in advertising or otherwise to promote the sale, #
25 # use or other dealings in this Software without prior written               #
26 # authorization.                                                             #
27 ##############################################################################
28 #
29 #  Author: Juergen Pfeifer <Juergen.Pfeifer@T-Online.de> 1996
30 #
31 #  Version Control
32 #  $Revision: 1.18 $
33 #
34 .SUFFIXES:
35
36 SHELL           = /bin/sh
37 THIS            = Makefile
38
39 top_srcdir      = @top_srcdir@
40 srcdir          = @srcdir@
41 prefix          = @prefix@
42 exec_prefix     = @exec_prefix@
43 libdir          = @libdir@
44 includedir      = @includedir@
45 datadir         = @datadir@
46 ticdir          = $(datadir)/terminfo
47 ADA_INCLUDE     = @ADA_INCLUDE@
48 ADA_OBJECTS     = @ADA_OBJECTS@
49
50 INSTALL         = @INSTALL@
51 INSTALL_DATA    = @INSTALL_DATA@
52
53 AWK             = @AWK@
54 LN_S            = @LN_S@
55
56 CC              = @CC@
57 CFLAGS          = @CFLAGS@
58
59 CPPFLAGS        = @ACPPFLAGS@ \
60                   -DHAVE_CONFIG_H -I$(srcdir)
61
62 CCFLAGS         = $(CPPFLAGS) $(CFLAGS)
63
64 CFLAGS_NORMAL   = $(CCFLAGS)
65 CFLAGS_DEBUG    = $(CCFLAGS) @CC_G_OPT@ -DTRACE
66 CFLAGS_PROFILE  = $(CCFLAGS) -pg
67 CFLAGS_SHARED   = $(CCFLAGS) @CC_SHARED_OPTS@
68
69 CFLAGS_DEFAULT  = $(CFLAGS_@DFT_UPR_MODEL@)
70
71 LINK            = $(CC)
72 LD_FLAGS        = @LD_MODEL@ $(LOCAL_LIBS) @LDFLAGS@ @LIBS@ @LOCAL_LDFLAGS2@ $(LDFLAGS)
73
74 RANLIB          = @RANLIB@
75
76 LIB_CURSES      = -L ../../lib -lncurses
77
78 M4              = m4
79 M4FLAGS         =
80
81 DEL_ADAMODE     = sed -e '/^\-\-\ \ \-\*\-\ ada\ \-\*\-.*/d'
82
83 ################################################################################
84 ALIB            = @cf_ada_package@
85 ABASE           = $(ALIB)-curses
86
87 ADA_SRCDIR      = ../ada_include
88 ADA_OBJDIR      = ../ada_objects
89
90 GEN_FILES0      = Base_Defs
91
92 GEN_FILES1      = Key_Definitions                       \
93                   Old_Keys                              \
94                   Character_Attribute_Set_Rep           \
95                   AC_Rep                                \
96                   Color_Defs                            \
97                   ACS_Map                               \
98                   Linker_Options                        \
99                   Base_Defs                             \
100                   Version_Info
101
102 GEN_FILES2      = Menu_Opt_Rep                          \
103                   Menu_Base_Defs                        \
104                   Menu_Linker_Options                   \
105                   Item_Rep
106
107 GEN_FILES3      = Form_Opt_Rep                          \
108                   Form_Base_Defs                        \
109                   Form_Linker_Options                   \
110                   Field_Rep
111
112 GEN_FILES4      = Mouse_Base_Defs                       \
113                   Mouse_Event_Rep                       \
114                   Panel_Linker_Options
115
116 GEN_TARGETS     = $(ADA_SRCDIR)/$(ABASE).ads                            \
117                   $(ADA_SRCDIR)/$(ABASE)-menus.ads                      \
118                   $(ADA_SRCDIR)/$(ABASE)-forms.ads                      \
119                   $(ADA_SRCDIR)/$(ABASE)-mouse.ads                      \
120                   $(ADA_SRCDIR)/$(ABASE)-panels.ads                     \
121                   $(ADA_SRCDIR)/$(ABASE)-menus-menu_user_data.ads       \
122                   $(ADA_SRCDIR)/$(ABASE)-menus-item_user_data.ads       \
123                   $(ADA_SRCDIR)/$(ABASE)-forms-form_user_data.ads       \
124                   $(ADA_SRCDIR)/$(ABASE)-forms-field_types.ads          \
125                   $(ADA_SRCDIR)/$(ABASE)-forms-field_user_data.ads      \
126                   $(ADA_SRCDIR)/$(ABASE)-panels-user_data.ads
127
128 GEN_SRC         = $(srcdir)/$(ABASE).ads.m4                             \
129                   $(srcdir)/$(ABASE)-menus.ads.m4                       \
130                   $(srcdir)/$(ABASE)-forms.ads.m4                       \
131                   $(srcdir)/$(ABASE)-mouse.ads.m4                       \
132                   $(srcdir)/$(ABASE)-panels.ads.m4                      \
133                   $(srcdir)/$(ABASE)-menus-menu_user_data.ads.m4        \
134                   $(srcdir)/$(ABASE)-menus-item_user_data.ads.m4        \
135                   $(srcdir)/$(ABASE)-forms-form_user_data.ads.m4        \
136                   $(srcdir)/$(ABASE)-forms-field_types.ads.m4           \
137                   $(srcdir)/$(ABASE)-forms-field_user_data.ads.m4       \
138                   $(srcdir)/$(ABASE)-panels-user_data.ads.m4
139
140
141 all:    $(ADA_OBJDIR) $(GEN_TARGETS)
142         @
143
144 sources:
145
146 $(ADA_OBJDIR) \
147 $(ADA_INCLUDE) \
148 $(ADA_OBJECTS) :
149         $(top_srcdir)/mkinstalldirs $@
150
151 install \
152 install.libs :: $(ADA_INCLUDE)
153         @echo installing package $(ABASE) in $(ADA_INCLUDE)
154         @$(top_srcdir)/tar-copy.sh '$(ABASE)[-.]*' $(ADA_SRCDIR) $(ADA_INCLUDE)
155         @test $(srcdir) != ./ && $(top_srcdir)/tar-copy.sh '$(ABASE)[-.]*' $(srcdir)/../ada_include $(ADA_INCLUDE)
156
157 install \
158 install.libs :: $(ADA_OBJECTS)
159         @echo installing package $(ABASE) in $(ADA_OBJECTS)
160         @$(top_srcdir)/tar-copy.sh '$(ABASE)[-.]*' $(ADA_OBJDIR) $(ADA_OBJECTS)
161
162 uninstall \
163 uninstall.libs ::
164         @echo removing package $(ABASE) from $(ADA_INCLUDE)
165         -@cd $(ADA_INCLUDE) && rm -f $(ABASE)[-.]*
166
167 uninstall \
168 uninstall.libs ::
169         @echo removing package $(ABASE) from $(ADA_OBJECTS)
170         -@cd $(ADA_OBJECTS) && rm -f $(ABASE)[-.]*
171
172 gen:    gen.o
173         @ECHO_LINK@ $(LINK) $(CFLAGS_NORMAL) gen.o $(LD_FLAGS) -o $@ $(LIB_CURSES)
174
175 gen.o:  $(srcdir)/gen.c
176         $(CC) $(CFLAGS_NORMAL) -c -o $@ $(srcdir)/gen.c
177
178 Character_Attribute_Set_Rep: gen
179         ./gen B A >$@
180
181 Base_Defs: gen
182         ./gen B B >$@
183
184 Color_Defs: gen
185         ./gen B C >$@
186
187 Key_Definitions: gen
188         ./gen B K >$@
189
190 Old_Keys: gen
191         ./gen B O >$@
192
193 ACS_Map: gen
194         ./gen B M >$@
195
196 AC_Rep: gen
197         ./gen B R >$@
198
199 Linker_Options: gen
200         ./gen B L >$@
201
202 Version_Info: gen
203         ./gen B V >$@
204
205 Menu_Opt_Rep: gen
206         ./gen M R >$@
207
208 Menu_Base_Defs: gen
209         ./gen M B >$@
210
211 Menu_Linker_Options: gen
212         ./gen M L >$@
213
214 Item_Rep: gen
215         ./gen M I >$@
216
217 Form_Opt_Rep: gen
218         ./gen F R >$@
219
220 Form_Base_Defs: gen
221         ./gen F B >$@
222
223 Form_Linker_Options: gen
224         ./gen F L >$@
225
226 Field_Rep: gen
227         ./gen F I >$@
228
229 Mouse_Base_Defs: gen
230         ./gen P B >$@
231
232 Mouse_Event_Rep: gen
233         ./gen P M >$@
234
235 Panel_Linker_Options: gen
236         ./gen P L >$@
237
238 $(ADA_SRCDIR)/$(ABASE).ads:     $(srcdir)/$(ABASE).ads.m4 \
239                                 $(GEN_FILES1) $(srcdir)/normal.m4
240         $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \
241         $(srcdir)/$(ABASE).ads.m4 |\
242         $(DEL_ADAMODE) >$@
243
244 $(ADA_SRCDIR)/$(ABASE)-menus.ads: $(srcdir)/$(ABASE)-menus.ads.m4 \
245                                   $(GEN_FILES2) $(srcdir)/normal.m4
246         $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \
247         $(srcdir)/$(ABASE)-menus.ads.m4 |\
248         $(DEL_ADAMODE) >$@
249
250 $(ADA_SRCDIR)/$(ABASE)-forms.ads: $(srcdir)/$(ABASE)-forms.ads.m4 \
251                                   $(GEN_FILES3) $(srcdir)/normal.m4
252         $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \
253         $(srcdir)/$(ABASE)-forms.ads.m4 |\
254         $(DEL_ADAMODE) >$@
255
256 $(ADA_SRCDIR)/$(ABASE)-mouse.ads: $(srcdir)/$(ABASE)-mouse.ads.m4 \
257                                   $(GEN_FILES4) $(srcdir)/normal.m4
258         $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \
259         $(srcdir)/$(ABASE)-mouse.ads.m4 |\
260         $(DEL_ADAMODE) >$@
261
262 $(ADA_SRCDIR)/$(ABASE)-panels.ads: $(srcdir)/$(ABASE)-panels.ads.m4 \
263                                    $(srcdir)/normal.m4
264         $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \
265         $(srcdir)/$(ABASE)-panels.ads.m4 |\
266         $(DEL_ADAMODE) >$@
267
268 $(ADA_SRCDIR)/$(ABASE)-menus-menu_user_data.ads: \
269                 $(srcdir)/$(ABASE)-menus-menu_user_data.ads.m4 \
270                 $(srcdir)/normal.m4
271         $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \
272         $(srcdir)/$(ABASE)-menus-menu_user_data.ads.m4 |\
273         $(DEL_ADAMODE) >$@
274
275 $(ADA_SRCDIR)/$(ABASE)-menus-item_user_data.ads: \
276                 $(srcdir)/$(ABASE)-menus-item_user_data.ads.m4 \
277                 $(srcdir)/normal.m4
278         $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \
279         $(srcdir)/$(ABASE)-menus-item_user_data.ads.m4 |\
280         $(DEL_ADAMODE) >$@
281
282 $(ADA_SRCDIR)/$(ABASE)-forms-form_user_data.ads: \
283                 $(srcdir)/$(ABASE)-forms-form_user_data.ads.m4 \
284                 $(srcdir)/normal.m4
285         $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \
286         $(srcdir)/$(ABASE)-forms-form_user_data.ads.m4 |\
287         $(DEL_ADAMODE) >$@
288
289 $(ADA_SRCDIR)/$(ABASE)-forms-field_types.ads: \
290                 $(srcdir)/$(ABASE)-forms-field_types.ads.m4 \
291                 $(srcdir)/normal.m4
292         $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \
293         $(srcdir)/$(ABASE)-forms-field_types.ads.m4 |\
294         $(DEL_ADAMODE) >$@
295
296 $(ADA_SRCDIR)/$(ABASE)-forms-field_user_data.ads: \
297                 $(srcdir)/$(ABASE)-forms-field_user_data.ads.m4 \
298                 $(srcdir)/normal.m4
299         $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \
300         $(srcdir)/$(ABASE)-forms-field_user_data.ads.m4 |\
301         $(DEL_ADAMODE) >$@
302
303 $(ADA_SRCDIR)/$(ABASE)-panels-user_data.ads: \
304                 $(srcdir)/$(ABASE)-panels-user_data.ads.m4 \
305                 $(srcdir)/normal.m4
306         $(M4) $(M4FLAGS) -DM4MACRO=$(srcdir)/normal.m4 \
307         $(srcdir)/$(ABASE)-panels-user_data.ads.m4 |\
308         $(DEL_ADAMODE) >$@
309
310 install.progs ::
311
312 tags:
313         ctags *.[ch]
314
315 TAGS:
316         etags *.[ch]
317
318 mostlyclean ::
319         -rm -f a.out core gen *.o
320         -rm -f $(GEN_FILES1)
321         -rm -f $(GEN_FILES2)
322         -rm -f $(GEN_FILES3)
323         -rm -f $(GEN_FILES4)
324
325 clean :: mostlyclean
326         -rm -f $(GEN_TARGETS)
327
328 distclean :: clean
329         rm -f Makefile
330
331 realclean :: distclean
332
333 ###############################################################################
334 # The remainder of this file is automatically generated during configuration
335 ###############################################################################