FYI: Reply from HP-UX
[git/dscho.git] / flex-2.5.33 / Makefile.am
blob4d419a1ca67a3cc7ca60b3b593a04e2bfdad2551
1 # This file is part of flex.
3 # Redistribution and use in source and binary forms, with or without
4 # modification, are permitted provided that the following conditions
5 # are met:
7 # 1. Redistributions of source code must retain the above copyright
8 #    notice, this list of conditions and the following disclaimer.
9 # 2. Redistributions in binary form must reproduce the above copyright
10 #    notice, this list of conditions and the following disclaimer in the
11 #    documentation and/or other materials provided with the distribution.
13 # Neither the name of the University nor the names of its contributors
14 # may be used to endorse or promote products derived from this software
15 # without specific prior written permission.
17 # THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
18 # IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
19 # WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
20 # PURPOSE.
22 # Notes on building:
24 # Possible values for DEFS:
26 # By default, flex generates 8-bit scanners when using table compression,
27 # and 7-bit scanners when using uncompressed tables (-f or -F options).
28 # For flex to always generate 8-bit scanners, add "-DDEFAULT_CSIZE=256"
29 # to DEFS.
31 # For Vax/VMS, add "-DVMS" to DEFS.
33 # For MS-DOS, add "-DMS_DOS" to DEFS.  See the directory MISC/MSDOS for
34 # additional info.
36 AM_YFLAGS = -d
37 ACLOCAL_AMFLAGS = -I m4
38 m4 = @M4@
39 indent = @INDENT@
41 AUTOMAKE_OPTIONS = \
42         gnits \
43         check-news \
44         dist-bzip2 \
45         1.7
47 bin_PROGRAMS = flex
48 lib_LIBRARIES = libfl.a
50 flex_SOURCES = \
51         ccl.c \
52         dfa.c \
53         ecs.c \
54         gen.c \
55         main.c \
56         misc.c \
57         nfa.c \
58         parse.y \
59         scan.l \
60         skel.c \
61         sym.c \
62         tblcmp.c \
63         yylex.c \
64         options.c \
65         scanopt.c \
66         buf.c \
67         tables.c \
68         tables_shared.c \
69         filter.c \
70         regex.c
72 libfl_a_SOURCES = \
73         libmain.c \
74         libyywrap.c
76 noinst_HEADERS = \
77         flexdef.h \
78         flexint.h \
79         version.h \
80         options.h \
81         scanopt.h \
82         tables.h \
83         tables_shared.h
85 include_HEADERS = \
86         FlexLexer.h
88 MAINTAINERCLEANFILES = \
89         ABOUT-NLS \
90         config.rpath \
91         config.sub \
92         config.guess \
93         configure \
94         config.sub \
95         config.guess \
96         depcomp \
97         mkinstalldirs \
98         install-sh \
99         ABOUT-NLS \
100         ChangeLog \
101         INSTALL \
102         conf.in \
103         aclocal.m4 \
104         Makefile.in \
105         mdate-sh \
106         missing
110 EXTRA_DIST = \
111         flex.spec.in \
112         flex.spec \
113         .indent.pro \
114         AUTHORS \
115         COPYING \
116         INSTALL \
117         NEWS \
118         ONEWS \
119         README \
120         README.cvs-snapshot \
121         THANKS \
122         TODO \
123         autogen.sh \
124         flex.skl \
125         mkskel.sh \
126         ABOUT-NLS \
127         config.rpath \
128         gettext.h
130 BUILT_SOURCES = \
131         skel.c
133 SUBDIRS = \
134         . \
135         doc \
136         m4  \
137         examples \
138         po \
139         tools \
140         tests
142 localedir = $(datadir)/locale
143 AM_CPPFLAGS = -DLOCALEDIR=\"$(localedir)\" -I@includedir@ -I$(top_srcdir)/intl
144 LIBS = @LIBINTL@ @LIBS@
146 skel.c: flex.skl mkskel.sh flexint.h tables_shared.h
147         sed 's/m4_/m4postproc_/g; s/m4preproc_/m4_/g' $(srcdir)/flex.skl | $(m4) -P -DFLEX_MAJOR_VERSION=`echo $(VERSION)|cut -f 1 -d .` -DFLEX_MINOR_VERSION=`echo $(VERSION)|cut -f 2 -d .` -DFLEX_SUBMINOR_VERSION=`echo $(VERSION)|cut -f 3 -d .` | sed 's/m4postproc_/m4_/g' | $(SHELL) $(srcdir)/mkskel.sh  >skel.c
149 # Explicitly describe dependencies.
150 # You can recreate this with `gcc -I. -MM *.c'
151 buf.o: buf.c flexdef.h flexint.h
152 ccl.o: ccl.c flexdef.h flexint.h
153 dfa.o: dfa.c flexdef.h flexint.h tables.h tables_shared.h
154 ecs.o: ecs.c flexdef.h flexint.h
155 gen.o: gen.c flexdef.h flexint.h tables.h tables_shared.h
156 libmain.o: libmain.c
157 libyywrap.o: libyywrap.c
158 main.o: main.c flexdef.h flexint.h version.h options.h scanopt.h \
159  tables.h tables_shared.h
160 misc.o: misc.c flexdef.h flexint.h tables.h tables_shared.h
161 nfa.o: nfa.c flexdef.h flexint.h
162 options.o: options.c options.h scanopt.h flexdef.h flexint.h
163 parse.o: parse.c flexdef.h flexint.h tables.h tables_shared.h
164 scan.o: scan.c flexdef.h flexint.h parse.h
165 scanopt.o: scanopt.c flexdef.h flexint.h scanopt.h
166 skel.o: skel.c flexdef.h flexint.h
167 sym.o: sym.c flexdef.h flexint.h
168 tables.o: tables.c flexdef.h flexint.h tables.h tables_shared.h
169 tables_shared.o: tables_shared.c flexdef.h flexint.h tables.h \
170  tables_shared.h
171 tblcmp.o: tblcmp.c flexdef.h flexint.h
172 yylex.o: yylex.c flexdef.h flexint.h parse.h
173 filter.o: filter.c flexdef.h flexint.h
175 # Create a tags file.
176 tags:
177         ctags --c-types='defgmstuv' $(srcdir)/*.[ch]
179 # Create the ChangeLog, but only if we're inside a cvs working directory
181 ChangeLog:
182         if [ -d CVS ] ; then \
183                 sh $(srcdir)/tools/cvs2cl.pl -F trunk -U $(srcdir)/tools/cvsauthors \
184         ; fi
186 # Run GNU indent on sources. Don't run this unless all the sources compile cleanly.
188 # Whole idea:
189 #   1. Check for .indent.pro, otherwise indent will use unknown
190 #      settings, or worse, the GNU defaults.)
191 #   2. Check that this is GNU indent.
192 #   3. Make sure to process only the NON-generated .c and .h files.
193 #   4. Run indent twice per file. The first time is a test.
194 #      Otherwise, indent overwrites your file even if it fails!
195 indentfiles = \
196         buf.c \
197         ccl.c \
198         dfa.c \
199         ecs.c \
200         filter.c \
201         flexdef.h \
202         gen.c \
203         libmain.c \
204         libyywrap.c \
205         main.c \
206         misc.c \
207         nfa.c \
208         options.c \
209         options.h \
210         regex.c \
211         scanopt.c \
212         scanopt.h \
213         sym.c \
214         tables.c \
215         tables.h \
216         tables_shared.c \
217         tables_shared.h \
218         tblcmp.c
220 indent:
221         if [ -f .indent.pro ] ; then \
222         for f in $(indentfiles);\
223         do\
224                 echo indenting $$f ;\
225                 $(indent) < $$f >/dev/null && indent $$f || echo $$f FAILED to indent ;\
226         done \
227         fi
229 .PHONY: ChangeLog tags indent