]> cygwin.com Git - cygwin-apps/setup.git/blob - Makefile.am
2004-12-25 Max Bowsher <maxb@ukf.net>
[cygwin-apps/setup.git] / Makefile.am
1 ## Process this file with automake to produce Makefile.in
2 #
3 # $Id$
4 #
5 # Copyright (c) 2000, Red Hat, Inc.
6 # Copyright (c) 2002, Robert Collins
7 #
8 # This program is free software; you can redistribute it and/or modify
9 # it under the terms of the GNU General Public License as published by
10 # the Free Software Foundation; either version 2 of the License, or
11 # (at your option) any later version.
12 #
13 # A copy of the GNU General Public License can be found at
14 # http://www.gnu.org/
15 #
16 # Written by Christopher Faylor <cgf@redhat.com>
17 # and Robert Collins <rbtcollins@hotmail.com>
18 #
19 # Makefile for Cygwin installer
20
21 AUTOMAKE_OPTIONS = dist-bzip2 subdir-objects 1.6 foreign
22 DIST_SUBDIRS = bz2lib zlib libgetopt++ tests
23 SUBDIRS = bz2lib zlib libgetopt++ tests
24
25 ## DISTCLEANFILES = include/stamp-h include/stamp-h[0-9]*
26
27 # We would like to use -Winline for C++ as well, but some STL code triggers
28 # this warning. (Bug verified present in gcc-3.3)
29 BASECXXFLAGS = -Wall -Wpointer-arith -Wcomments -Wcast-align -Wwrite-strings
30 AM_CXXFLAGS = -Werror $(BASECXXFLAGS)
31 AM_CFLAGS = $(AM_CXXFLAGS) -Wmissing-declarations -Winline \
32 -Wstrict-prototypes -Wmissing-prototypes
33
34 WINDRES := @WINDRES@
35
36 INCLUDES = -I$(srcdir)/bz2lib -I$(srcdir)/libgetopt++/include
37
38 noinst_PROGRAMS = \
39 setup \
40 @INILINT@
41
42 EXTRA_PROGRAMS = inilint
43 ## noinst_PROGRAMS +=inilint
44
45 EXTRA_DIST = \
46 GUIDELINES \
47 check-na.bmp \
48 check-no.bmp \
49 check-yes.bmp \
50 choose-rtarrow.bmp \
51 choose-spin.bmp \
52 cygwin.ico \
53 inilex.l \
54 iniparse.y
55
56 BUILT_SOURCES = setup_version.c \
57 inilex.cc \
58 iniparse.cc
59
60 if MINGWTARGET
61 inilint_extras = \
62 autoload.c \
63 mklink2.cc
64 else
65 inilint_extras =
66 endif
67
68 inilint_LDADD = libgetopt++/libgetopt++.la -luser32 -lkernel32
69 inilint_SOURCES = \
70 filemanip.cc \
71 filemanip.h \
72 find.cc \
73 find.h \
74 FindVisitor.cc \
75 FindVisitor.h \
76 LogSingleton.cc \
77 LogSingleton.h \
78 IniDBBuilder.cc \
79 IniDBBuilder.h \
80 inilex.cc \
81 inilintmain.cc \
82 iniparse.cc \
83 iniparse.h \
84 IniParseFeedback.cc \
85 IniParseFeedback.h \
86 io_stream.h \
87 io_stream.cc \
88 io_stream_file.h \
89 io_stream_file.cc \
90 IOStreamProvider.h \
91 mkdir.cc \
92 mkdir.h \
93 PackageSpecification.cc \
94 PackageSpecification.h \
95 PackageTrust.h \
96 rfc1738.cc \
97 rfc1738.h \
98 String++.cc \
99 String++.h \
100 $(inilint_extras)
101
102 # Obviously we are not really building a program called warnonly
103 # However, this dance was the most non-invasive way I could find
104 # of varying CFLAGS for a single file
105 EXTRA_PROGRAMS += warnonly
106 warnonly_CXXFLAGS = $(BASECXXFLAGS)
107 warnonly_SOURCES = inilex.cc
108 EXTRA_setup_SOURCES = $(warnonly_SOURCES)
109
110 setup_LDADD = warnonly-inilex.o res.o \
111 zlib/libzcygw.a bz2lib/libbz2.a libgetopt++/libgetopt++.la \
112 -luser32 -lkernel32 \
113 -lcomctl32 -lole32 -lwsock32 -lnetapi32 -ladvapi32 -luuid
114 setup_LDFLAGS = -mwindows
115 setup_SOURCES = \
116 AntiVirus.cc \
117 AntiVirus.h \
118 archive.cc \
119 archive.h \
120 archive_tar.cc \
121 archive_tar.h \
122 archive_tar_file.cc \
123 autoload.c \
124 category.cc \
125 category.h \
126 choose.cc \
127 choose.h \
128 compress.cc \
129 compress.h \
130 compress_bz.cc \
131 compress_bz.h \
132 compress_gz.cc \
133 compress_gz.h \
134 ConnectionSetting.cc \
135 ConnectionSetting.h \
136 ControlAdjuster.cc \
137 ControlAdjuster.h \
138 cygpackage.cc \
139 cygpackage.h \
140 desktop.cc \
141 desktop.h \
142 dialog.cc \
143 dialog.h \
144 diskfull.cc \
145 diskfull.h \
146 download.cc \
147 download.h \
148 Exception.cc \
149 Exception.h \
150 find.cc \
151 find.h \
152 FindVisitor.cc \
153 FindVisitor.h \
154 filemanip.cc \
155 filemanip.h \
156 fromcwd.cc \
157 Generic.h \
158 geturl.cc \
159 geturl.h \
160 hash.cc \
161 hash.h \
162 ini.cc \
163 ini.h \
164 IniDBBuilder.cc \
165 IniDBBuilder.h \
166 IniDBBuilderPackage.cc \
167 IniDBBuilderPackage.h \
168 iniparse.cc \
169 iniparse.h \
170 IniParseFeedback.cc \
171 IniParseFeedback.h \
172 IniParseFindVisitor.cc \
173 IniParseFindVisitor.h \
174 install.cc \
175 io_stream.cc \
176 io_stream.h \
177 io_stream_cygfile.cc \
178 io_stream_cygfile.h \
179 io_stream_file.cc \
180 io_stream_file.h \
181 io_stream_memory.cc \
182 io_stream_memory.h \
183 IOStreamProvider.h \
184 localdir.cc \
185 localdir.h \
186 log.cc \
187 log.h \
188 LogFile.cc \
189 LogFile.h \
190 LogSingleton.cc \
191 LogSingleton.h \
192 main.cc \
193 mkdir.cc \
194 mkdir.h \
195 mklink2.cc \
196 mklink2.h \
197 mount.cc \
198 mount.h \
199 msg.cc \
200 msg.h \
201 net.cc \
202 net.h \
203 netio.cc \
204 netio.h \
205 nio-ie5.cc \
206 nio-ie5.h \
207 nio-file.cc \
208 nio-file.h \
209 nio-ftp.cc \
210 nio-ftp.h \
211 nio-http.cc \
212 nio-http.h \
213 package_db.cc \
214 package_db.h \
215 package_meta.cc \
216 package_meta.h \
217 package_source.cc \
218 package_source.h \
219 package_version.cc \
220 package_version.h \
221 PackageSpecification.cc \
222 PackageSpecification.h \
223 PackageTrust.h \
224 PickCategoryLine.cc \
225 PickCategoryLine.h \
226 PickLine.cc \
227 PickLine.h \
228 PickPackageLine.cc \
229 PickPackageLine.h \
230 PickView.cc \
231 PickView.h \
232 postinstall.cc \
233 proppage.cc \
234 proppage.h \
235 propsheet.cc \
236 propsheet.h \
237 RECTWrapper.h \
238 res.rc \
239 resource.h \
240 rfc1738.cc \
241 rfc1738.h \
242 root.cc \
243 root.h \
244 ScanFindVisitor.cc \
245 ScanFindVisitor.h \
246 script.cc \
247 script.h \
248 setup_version.c \
249 simpsock.cc \
250 simpsock.h \
251 site.cc \
252 site.h \
253 source.cc \
254 source.h \
255 SourceSetting.cc \
256 SourceSetting.h \
257 splash.cc \
258 splash.h \
259 state.cc \
260 state.h \
261 String++.cc \
262 String++.h \
263 threebar.cc \
264 threebar.h \
265 UserSetting.cc \
266 UserSetting.h \
267 UserSettings.cc \
268 UserSettings.h \
269 version.cc \
270 version.h \
271 win32.h \
272 window.cc \
273 window.h \
274 csu_util/MD5Sum.cc \
275 csu_util/MD5Sum.h \
276 libmd5-rfc/md5.c \
277 libmd5-rfc/md5.h
278
279 setup_version.c : $(srcdir)/ChangeLog Makefile
280 V=`sed -ne 's/^\$$Revi[s]ion: *\([^ ]*\) *$$.*/\1/p' \
281 $(srcdir)/ChangeLog` ;\
282 (echo '#define VERSION_PREFIX "%%% setup-version"';\
283 echo 'static const char version_store[] = VERSION_PREFIX " '$$V'";';\
284 echo 'const char *version = version_store + sizeof (VERSION_PREFIX);') > version.tmp;\
285 mv version.tmp setup_version.c
286
287 %.o: %.rc
288 $(WINDRES) --preprocessor "$(CC) -E -xc-header -DRC_INVOKED" --include-dir $(srcdir) -o $@ $<
289
290 iniparse.cc iniparse.h : iniparse.y
291 bison -d -o iniparse.cc $(srcdir)/iniparse.y
292 @mv iniparse.cc.h iniparse.h 2>/dev/null || mv iniparse.hh iniparse.h
293
294 inilex.cc : inilex.l iniparse.h
295 flex -8 $(srcdir)/inilex.l
296 mv lex.yy.c inilex.cc
297
298 # Make a distribution package and tarball
299 release: setup$(EXEEXT) dist-all $(srcdir)/ChangeLog Makefile
300 $(STRIP) setup.exe && \
301 upx --best setup.exe && \
302 V=`sed -ne 's/^\$$Revi[s]ion: *\([^ ]*\) *$$.*/\1/p' \
303 $(srcdir)/ChangeLog` ;\
304 mv setup.exe setup-$${V}.exe && \
305 mv setup-0.tar.bz2 setup-$${V}.tar.bz2 && \
306 tar cjf setup-$${V}-1-src.tar.bz2 setup-$${V}.tar.bz2
307
308 # Create a snapshot and upload it (requires write access)
309 snapshot: release
310 V=`sed -ne 's/^\$$Revi[s]ion: *\([^ ]*\) *$$.*/\1/p' \
311 $(srcdir)/ChangeLog` ;\
312 scp -C setup-$${V}.exe setup-$${V}.tar.bz2 $${cygwinsite}:setup-snapshots/
This page took 0.054453 seconds and 6 git commands to generate.