]>
Commit | Line | Data |
---|---|---|
f6100b6f RC |
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 | ||
48c7d667 | 21 | AUTOMAKE_OPTIONS = dist-bzip2 subdir-objects 1.6 foreign |
e76de0f5 MB |
22 | DIST_SUBDIRS = libgetopt++ tests |
23 | SUBDIRS = libgetopt++ tests | |
f6100b6f RC |
24 | |
25 | ## DISTCLEANFILES = include/stamp-h include/stamp-h[0-9]* | |
26 | ||
8b726ef6 MB |
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) | |
fc2ba841 MB |
29 | BASECXXFLAGS = -Wall -Wpointer-arith -Wcomments -Wcast-align -Wwrite-strings |
30 | AM_CXXFLAGS = -Werror $(BASECXXFLAGS) | |
d3c2a043 MB |
31 | AM_CFLAGS = $(AM_CXXFLAGS) -Wmissing-declarations -Winline \ |
32 | -Wstrict-prototypes -Wmissing-prototypes | |
f6100b6f RC |
33 | |
34 | WINDRES := @WINDRES@ | |
35 | ||
e76de0f5 | 36 | INCLUDES = -I$(srcdir)/libgetopt++/include -I/usr/include/mingw |
f6100b6f | 37 | |
58ee6135 | 38 | noinst_PROGRAMS = \ |
19911586 RC |
39 | setup \ |
40 | @INILINT@ | |
58ee6135 RC |
41 | |
42 | EXTRA_PROGRAMS = inilint | |
19911586 | 43 | ## noinst_PROGRAMS +=inilint |
f6100b6f | 44 | |
45e01f23 | 45 | EXTRA_DIST = \ |
3baca7c9 | 46 | GUIDELINES \ |
45e01f23 RC |
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 \ | |
3baca7c9 | 54 | iniparse.y |
45e01f23 | 55 | |
f6100b6f RC |
56 | BUILT_SOURCES = setup_version.c \ |
57 | inilex.cc \ | |
58 | iniparse.cc | |
59 | ||
2b48ecd0 RC |
60 | if MINGWTARGET |
61 | inilint_extras = \ | |
62 | autoload.c \ | |
2b48ecd0 RC |
63 | mklink2.cc |
64 | else | |
65 | inilint_extras = | |
66 | endif | |
67 | ||
4361306f | 68 | inilint_LDADD = libgetopt++/libgetopt++.la -luser32 -lkernel32 |
58ee6135 | 69 | inilint_SOURCES = \ |
b92028a4 RC |
70 | filemanip.cc \ |
71 | filemanip.h \ | |
aa1e3b4d RC |
72 | find.cc \ |
73 | find.h \ | |
74 | FindVisitor.cc \ | |
75 | FindVisitor.h \ | |
9f4a0c62 RC |
76 | LogSingleton.cc \ |
77 | LogSingleton.h \ | |
076654e7 RC |
78 | IniDBBuilder.cc \ |
79 | IniDBBuilder.h \ | |
58ee6135 RC |
80 | inilex.cc \ |
81 | inilintmain.cc \ | |
82 | iniparse.cc \ | |
83 | iniparse.h \ | |
aa1e3b4d RC |
84 | IniParseFeedback.cc \ |
85 | IniParseFeedback.h \ | |
076654e7 RC |
86 | io_stream.h \ |
87 | io_stream.cc \ | |
2b48ecd0 RC |
88 | io_stream_file.h \ |
89 | io_stream_file.cc \ | |
19911586 | 90 | IOStreamProvider.h \ |
aa1e3b4d RC |
91 | mkdir.cc \ |
92 | mkdir.h \ | |
84c4f5d1 RC |
93 | PackageSpecification.cc \ |
94 | PackageSpecification.h \ | |
076654e7 | 95 | PackageTrust.h \ |
58ee6135 RC |
96 | rfc1738.cc \ |
97 | rfc1738.h \ | |
98 | String++.cc \ | |
2b48ecd0 RC |
99 | String++.h \ |
100 | $(inilint_extras) | |
58ee6135 | 101 | |
fc2ba841 MB |
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 \ | |
e76de0f5 MB |
111 | libgetopt++/libgetopt++.la \ |
112 | /usr/lib/mingw/libbz2.a \ | |
113 | /usr/lib/mingw/libz.a \ | |
4361306f | 114 | -luser32 -lkernel32 \ |
b401ef47 | 115 | -lcomctl32 -lole32 -lwsock32 -lnetapi32 -ladvapi32 -luuid |
58ee6135 | 116 | setup_LDFLAGS = -mwindows |
f6100b6f | 117 | setup_SOURCES = \ |
f9e903a3 RC |
118 | AntiVirus.cc \ |
119 | AntiVirus.h \ | |
f6100b6f | 120 | archive.cc \ |
45e01f23 | 121 | archive.h \ |
f6100b6f | 122 | archive_tar.cc \ |
45e01f23 | 123 | archive_tar.h \ |
f6100b6f RC |
124 | archive_tar_file.cc \ |
125 | autoload.c \ | |
126 | category.cc \ | |
45e01f23 | 127 | category.h \ |
f6100b6f | 128 | choose.cc \ |
45e01f23 | 129 | choose.h \ |
f6100b6f | 130 | compress.cc \ |
45e01f23 | 131 | compress.h \ |
f6100b6f | 132 | compress_bz.cc \ |
45e01f23 | 133 | compress_bz.h \ |
f6100b6f | 134 | compress_gz.cc \ |
45e01f23 | 135 | compress_gz.h \ |
39b42ff3 RC |
136 | ConnectionSetting.cc \ |
137 | ConnectionSetting.h \ | |
ee91d9be RC |
138 | ControlAdjuster.cc \ |
139 | ControlAdjuster.h \ | |
f6100b6f | 140 | cygpackage.cc \ |
45e01f23 | 141 | cygpackage.h \ |
f6100b6f | 142 | desktop.cc \ |
45e01f23 | 143 | desktop.h \ |
f6100b6f | 144 | dialog.cc \ |
45e01f23 | 145 | dialog.h \ |
f6100b6f | 146 | diskfull.cc \ |
45e01f23 | 147 | diskfull.h \ |
f6100b6f | 148 | download.cc \ |
58ee6135 RC |
149 | download.h \ |
150 | Exception.cc \ | |
151 | Exception.h \ | |
f6100b6f | 152 | find.cc \ |
45e01f23 | 153 | find.h \ |
b401ef47 RC |
154 | FindVisitor.cc \ |
155 | FindVisitor.h \ | |
f6100b6f | 156 | filemanip.cc \ |
45e01f23 | 157 | filemanip.h \ |
f6100b6f | 158 | fromcwd.cc \ |
31f0ccce | 159 | Generic.h \ |
f6100b6f | 160 | geturl.cc \ |
45e01f23 | 161 | geturl.h \ |
f6100b6f | 162 | ini.cc \ |
45e01f23 | 163 | ini.h \ |
076654e7 RC |
164 | IniDBBuilder.cc \ |
165 | IniDBBuilder.h \ | |
166 | IniDBBuilderPackage.cc \ | |
167 | IniDBBuilderPackage.h \ | |
f6100b6f RC |
168 | iniparse.cc \ |
169 | iniparse.h \ | |
67829ce0 RC |
170 | IniParseFeedback.cc \ |
171 | IniParseFeedback.h \ | |
b401ef47 RC |
172 | IniParseFindVisitor.cc \ |
173 | IniParseFindVisitor.h \ | |
f6100b6f RC |
174 | install.cc \ |
175 | io_stream.cc \ | |
45e01f23 | 176 | io_stream.h \ |
f6100b6f | 177 | io_stream_cygfile.cc \ |
45e01f23 | 178 | io_stream_cygfile.h \ |
f6100b6f | 179 | io_stream_file.cc \ |
45e01f23 | 180 | io_stream_file.h \ |
f6100b6f | 181 | io_stream_memory.cc \ |
45e01f23 | 182 | io_stream_memory.h \ |
19911586 | 183 | IOStreamProvider.h \ |
f6100b6f | 184 | localdir.cc \ |
45e01f23 | 185 | localdir.h \ |
9f4a0c62 RC |
186 | LogFile.cc \ |
187 | LogFile.h \ | |
188 | LogSingleton.cc \ | |
189 | LogSingleton.h \ | |
f6100b6f | 190 | main.cc \ |
f6100b6f | 191 | mkdir.cc \ |
45e01f23 | 192 | mkdir.h \ |
f6100b6f | 193 | mklink2.cc \ |
45e01f23 | 194 | mklink2.h \ |
f6100b6f | 195 | mount.cc \ |
45e01f23 | 196 | mount.h \ |
f6100b6f | 197 | msg.cc \ |
45e01f23 | 198 | msg.h \ |
f6100b6f | 199 | net.cc \ |
45e01f23 | 200 | net.h \ |
f6100b6f | 201 | netio.cc \ |
45e01f23 | 202 | netio.h \ |
f6100b6f | 203 | nio-ie5.cc \ |
45e01f23 | 204 | nio-ie5.h \ |
f6100b6f | 205 | nio-file.cc \ |
45e01f23 | 206 | nio-file.h \ |
f6100b6f | 207 | nio-ftp.cc \ |
45e01f23 | 208 | nio-ftp.h \ |
f6100b6f | 209 | nio-http.cc \ |
45e01f23 | 210 | nio-http.h \ |
f6100b6f | 211 | package_db.cc \ |
45e01f23 | 212 | package_db.h \ |
f6100b6f | 213 | package_meta.cc \ |
45e01f23 | 214 | package_meta.h \ |
f6100b6f | 215 | package_source.cc \ |
45e01f23 | 216 | package_source.h \ |
f6100b6f | 217 | package_version.cc \ |
45e01f23 | 218 | package_version.h \ |
aa1e3b4d RC |
219 | PackageSpecification.cc \ |
220 | PackageSpecification.h \ | |
076654e7 | 221 | PackageTrust.h \ |
f6100b6f | 222 | PickCategoryLine.cc \ |
45e01f23 | 223 | PickCategoryLine.h \ |
45e01f23 | 224 | PickLine.h \ |
f6100b6f | 225 | PickPackageLine.cc \ |
45e01f23 | 226 | PickPackageLine.h \ |
f6100b6f | 227 | PickView.cc \ |
45e01f23 | 228 | PickView.h \ |
f6100b6f RC |
229 | postinstall.cc \ |
230 | proppage.cc \ | |
45e01f23 | 231 | proppage.h \ |
f6100b6f | 232 | propsheet.cc \ |
45e01f23 | 233 | propsheet.h \ |
8a264069 | 234 | RECTWrapper.h \ |
f6100b6f | 235 | res.rc \ |
45e01f23 | 236 | resource.h \ |
f6100b6f | 237 | root.cc \ |
45e01f23 | 238 | root.h \ |
b401ef47 RC |
239 | ScanFindVisitor.cc \ |
240 | ScanFindVisitor.h \ | |
f6100b6f | 241 | script.cc \ |
45e01f23 | 242 | script.h \ |
2b734ec7 | 243 | setup_version.h \ |
f6100b6f RC |
244 | setup_version.c \ |
245 | simpsock.cc \ | |
45e01f23 | 246 | simpsock.h \ |
f6100b6f | 247 | site.cc \ |
45e01f23 | 248 | site.h \ |
f6100b6f | 249 | source.cc \ |
45e01f23 | 250 | source.h \ |
6ff96351 RC |
251 | SourceSetting.cc \ |
252 | SourceSetting.h \ | |
f6100b6f | 253 | splash.cc \ |
45e01f23 | 254 | splash.h \ |
f6100b6f | 255 | state.cc \ |
45e01f23 | 256 | state.h \ |
f6100b6f | 257 | String++.cc \ |
45e01f23 | 258 | String++.h \ |
f6100b6f | 259 | threebar.cc \ |
45e01f23 | 260 | threebar.h \ |
ead15931 RC |
261 | UserSetting.cc \ |
262 | UserSetting.h \ | |
263 | UserSettings.cc \ | |
264 | UserSettings.h \ | |
45e01f23 RC |
265 | win32.h \ |
266 | window.cc \ | |
f4d80c3f | 267 | window.h \ |
0229b1d7 MB |
268 | csu_util/MD5Sum.cc \ |
269 | csu_util/MD5Sum.h \ | |
946198be MB |
270 | csu_util/rfc1738.cc \ |
271 | csu_util/rfc1738.h \ | |
2b734ec7 MB |
272 | csu_util/version_compare.cc \ |
273 | csu_util/version_compare.h \ | |
f4d80c3f MB |
274 | libmd5-rfc/md5.c \ |
275 | libmd5-rfc/md5.h | |
f6100b6f RC |
276 | |
277 | setup_version.c : $(srcdir)/ChangeLog Makefile | |
84b9cc5e | 278 | V=`sed -ne 's/^\$$Revi[s]ion: *\([^ ]*\) *$$.*/\1/p' \ |
012374fe | 279 | $(srcdir)/ChangeLog` ;\ |
f6100b6f RC |
280 | (echo '#define VERSION_PREFIX "%%% setup-version"';\ |
281 | echo 'static const char version_store[] = VERSION_PREFIX " '$$V'";';\ | |
2b734ec7 | 282 | echo 'const char *setup_version = version_store + sizeof (VERSION_PREFIX);') > version.tmp;\ |
f6100b6f RC |
283 | mv version.tmp setup_version.c |
284 | ||
285 | %.o: %.rc | |
4361306f | 286 | $(WINDRES) --preprocessor "$(CC) -E -xc-header -DRC_INVOKED" --include-dir $(srcdir) -o $@ $< |
f6100b6f | 287 | |
f6100b6f RC |
288 | iniparse.cc iniparse.h : iniparse.y |
289 | bison -d -o iniparse.cc $(srcdir)/iniparse.y | |
290 | @mv iniparse.cc.h iniparse.h 2>/dev/null || mv iniparse.hh iniparse.h | |
291 | ||
292 | inilex.cc : inilex.l iniparse.h | |
293 | flex -8 $(srcdir)/inilex.l | |
294 | mv lex.yy.c inilex.cc | |
902c8a3f RC |
295 | |
296 | # Make a distribution package and tarball | |
5090e3ce RC |
297 | release: setup$(EXEEXT) dist-all $(srcdir)/ChangeLog Makefile |
298 | $(STRIP) setup.exe && \ | |
299 | upx --best setup.exe && \ | |
84b9cc5e | 300 | V=`sed -ne 's/^\$$Revi[s]ion: *\([^ ]*\) *$$.*/\1/p' \ |
012374fe | 301 | $(srcdir)/ChangeLog` ;\ |
4849e2fc | 302 | mv setup.exe setup-$${V}.exe && \ |
7cb35117 RC |
303 | mv setup-0.tar.bz2 setup-$${V}.tar.bz2 && \ |
304 | tar cjf setup-$${V}-1-src.tar.bz2 setup-$${V}.tar.bz2 | |
7d702af3 RC |
305 | |
306 | # Create a snapshot and upload it (requires write access) | |
307 | snapshot: release | |
84b9cc5e | 308 | V=`sed -ne 's/^\$$Revi[s]ion: *\([^ ]*\) *$$.*/\1/p' \ |
012374fe | 309 | $(srcdir)/ChangeLog` ;\ |
7d702af3 | 310 | scp -C setup-$${V}.exe setup-$${V}.tar.bz2 $${cygwinsite}:setup-snapshots/ |