OSDN Git Service

Implement hooks to support lua scripting interface.
[mingw/mingw-get.git] / ChangeLog
1 2012-02-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
2
3         Implement hooks to support lua scripting interface.
4
5         * Makefile.in (LIBS): Add -llua.
6
7         * src/pkgbase.h (pkgXmlNode::InvokeScript): New method; declare it
8         as private, and provide overloaded public inline API implementation.
9         (pkgXmlNode::DispatchScript): New private method; declare it.
10
11         * src/pkgexec.cpp (pkgXmlNode::InvokeScript): Implement it.
12         (pkgXmlNode::DispatchScript): Likewise; it directs InvokeScript to...
13         (pkgInvokeScript): ...this new static function; implement it.
14
15         * src/pkginst.cpp (pkgInstall): Call InvokeScript as appropriate.
16         * src/pkgunst.cpp (pkgRemove): Likewise.
17
18 2011-11-24  Keith Marshall  <keithmarshall@users.sourceforge.net>
19
20         Avoid implicit cast warnings; reported by Robert Hartmann.
21
22         * src/dmh.h (DMH_BEGIN_DIGEST): Explicitly cast to uint16_t.
23         (DMH_END_DIGEST): Likewise.
24
25 2011-11-09  Keith Marshall  <keithmarshall@users.sourceforge.net>
26
27         Avoid unnecessary downloads for already installed packages.
28
29         * src/pkginet.cpp (pkgActionItem::DownloadSingleArchive): Require
30         external scheduling of ACTION_DOWNLOAD; cancel the scheduled request
31         on completion, or when not required due to pre-existing local copy.
32
33         * src/climain.cpp (pkgActionItem::GetSourceArchive): Must always be
34         prepared to download the associated archive; enable ACTION_DOWNLOAD.
35
36         * src/pkgexec.cpp (pkgActionItem::Schedule) [OPTION_REINSTALL]:
37         May need to download the archive, even when the requested package was
38         previously installed; schedule ACTION_DOWNLOAD to enable this.
39
40         * src/pkgdeps.cpp (promote): Macro redefined in terms of...
41         (with_flags, with_download): ...these new macros; implement and...
42         (pkgXmlDocument::ResolveDependencies): ...use them to enable/schedule
43         ACTION_DOWNLOAD only when expected that it may be necessary.
44
45 2011-11-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
46
47         Fix packaging anomalies for source and licence distributions.
48
49         * Makefile.in (licdist): Link README from ${CURDIR}, not from '..'.
50         (srcdist): Explicitly link pkginfo.c from ${CURDIR} to src/pkginfo,
51         rather than as implied prerequisite; this avoids a bogus attempt to
52         link srcdist-doc into src/pkginfo.
53
54 2011-11-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
55
56         Bump version number for subsequent CVS snapshots.
57
58         * configure.ac (AC_INIT): Set version to 0.4-alpha-1.1cvs
59
60 2011-11-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
61
62         mingw-get-0.4-mingw32-alpha-1 released.
63
64         * configure.ac (AC_INIT): Adjust version number.
65         * srcdist-doc/NEWS.in: Updated; document new features and bugs fixed.
66         * All files (r0-4-alpha-1): Tag assigned.
67
68 2011-11-04  Keith Marshall  <keithmarshall@users.sourceforge.net>
69
70         Don't upgrade installed DLL components to incompatible version.
71         Provide clearer diagnostics for failed requests on implied packages.
72
73         * src/pkgdeps.cpp (is_abi_compatible): New static inline function.
74         (pkgXmlDocument::ResolveDependencies) [is_installed]: Use it.
75         (pkgXmlDocument::ResolveDependencies) [DEBUG_TRACE_DEPENDENCIES]:
76         Clean up and improve diagnostic message content and formatting.
77         (pkgXmlDocument::Schedule) [(upgrade || remove) && ! installed]:
78         Downgrade diagnostic to WARNING, for implicitly specified component
79         packages; provide additional explanatory diagnostics.
80
81         * src/pkgspec.cpp (pkgSpecs::VersionComparator):
82         * src/pkgexec.cpp (pkgActionItem::SelectIfMostRecentFit):
83         [DEBUG_TRACE_DEPENDENCIES]: Eliminate diagnostic noise.
84
85 2011-10-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
86
87         Fix --download-only vs. --reinstall conflict.
88
89         * src/pkgexec.cpp (pkgActionItem::Execute) [OPTION_DOWNLOAD_ONLY]:
90         Test for explicit inequality, rather than equality to zero; since the
91         2011-08-30 update, which made --download-only also imply --reinstall,
92         it will test as non-zero when --reinstall is specified, even though
93         --download-only is not.
94
95 2011-10-07  Keith Marshall  <keithmarshall@users.sourceforge.net>
96
97         Add support for non-specific upgrade of all installed packages.
98
99         * src/pkgbase.h (pkgXmlDocument::RescheduleInstalledPackages):
100         New public method; declare it.
101
102         * src/pkgdeps.cpp (pkgXmlDocument::RescheduleInstalledPackages):
103         Implement it.
104
105         * src/climain.cpp (climain) [ACTION_UPGRADE && argc < 2]: Invoke
106         pkgXmlDocument::RescheduleInstalledPackages() to schedule the upgrade
107         request for all packages currently registered as installed.
108
109 2011-10-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
110
111         Implement "source" and "licence" operations.
112
113         * src/pkgopts.h (OPTION_ALL_DEPS): New option code; define it.
114         * src/clistub.c (main): Associate it with...
115         (all-related, recursive): ...these synonymous option names...
116         (options): ...defined within this local structured array.
117         (help_text): Document them; also document "source" and "licence" as
118         new operations which may be specified on the command line.
119
120         * src/pkgtask.h (action_source, action_licence): Enumerate them.
121         (ACTION_SOURCE, ACTION_LICENCE): Define their manifest values, and...
122         * src/pkgexec.cpp (action_name): ...associate with operation names.
123
124         * src/pkgbase.h (pkgActionItem::GetScheduledSourceArchives):
125         (pkgActionItem::GetSourceArchive, pkgXmlDocument::GetSourceArchive):
126         New public methods; declare them for external implementation.
127         (pkgXmlDocument::GetScheduledSourceArchives): New public method;
128         implement it as inline.
129
130         * src/climain.cpp (pkgProcessedArchives): New pointer to stack of...
131         (pkgArchiveNameList): ...this new locally defined class; implement it.
132         (pkgActionItem::GetSourceArchive, pkgXmlDocument::GetSourceArchive):
133         (pkgActionItem::GetScheduledSourceArchives): Implement them.
134         (climain): Add invocation hooks.
135
136 2011-10-04  Keith Marshall  <keithmarshall@users.sourceforge.net>
137
138         Establish mapping from release tarname to source tarname.
139
140         * src/pkgreqs.cpp (inherited_requirement): New inline function.
141         (requirement): Use it; adapt to propagate release archive format and
142         compression type fields, in addition to version fields, when resolving
143         "%" wildcard matches within the template for the resultant tarname.
144         (pkgAssociateName): New public function; implement it for use by...
145         * src/pkgname.cpp (pkgResolvedName): ...this new inline function.
146         (pkgXmlNode::SourceArchiveName): Use it; adapt to accept a category
147         selector, so it may resolve source or licence tarnames on demand.
148
149         * src/pkgbase.h (pkgXmlNode::SourceArchiveName): Modify declaration;
150         add category selector argument to support source/licence choice.
151
152 2011-10-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
153
154         Facilitate downloads using diverse cache directories.
155
156         * src/pkgbase.h (pkgActionItem::DownloadSingleArchive): New private
157         method; declare it; it handles the download for a single named archive
158         file, and stores it in a specifed cache directory.
159
160         * src/pkginet.cpp (pkgActionItem::DownloadSingleArchive): Implement
161         it; factor its code from the original implementation within...
162         (pkgActionItem::DownloadArchiveFiles): ...this; adapt to use it.
163
164 2011-10-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
165
166         Establish cache directory for source archive downloads.
167
168         * src/mkpath.h (pkgSourceArchivePath): New function; declare it.
169         * src/mkpath.c (pkgSourceArchivePath): Implement it.
170
171 2011-08-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
172
173         Support archive extraction to arbitrary destination without install.
174
175         * src/pkgproc.h (pkgArchiveProcessor::ExtractFile): New virtual
176         helper method for use, as core helper, by derived classes; declare it.
177         (pkgArchiveProcessor::CreateExtractionDirectory): Likewise.
178         (pkgTarArchiveProcessor): Declare overloaded default constructor.
179         (pkgTarArchiveExtractor): New class definition; it is derived from
180         pkgTarArchiveProcessor.
181
182         * src/tarproc.cpp (pkgArchiveProcessor::ExtractFile): Implement it.
183         (pkgArchiveProcessor::CreateExtractionDirectory): Likewise.
184         (pkgTarArchiveExtractor): Implement constructor, together with...
185         (pkgTarArchiveExtractor::ProcessDirectory): ...this method, and also...
186         (pkgTarArchiveExtractor::ProcessDataStream): ...this one; these are
187         declared as abstract, in the pkgTarArchiveProcessor base class.
188         (pkgTarArchiveInstaller::ProcessDirectory): Simplify; it now delegates
189         directory creation to pkgArchiveProcessor::CreateExtractionDirectory.
190         (pkgTarArchiveInstaller::ProcessDataStream): Simplify; delegate file
191         handling to pkgArchiveProcessor::ExtractFile, as appropriate.
192
193 2011-08-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
194
195         Make --download-only and --print-uris imply --reinstall.
196
197         * src/pkgopts.h (OPTION_PRINT_URIS): Adjust definition.
198         (OPTION_DNLOAD_ONLY, OPTION_DOWNLOAD_ONLY): Likewise.
199
200 2011-08-07  Keith Marshall  <keithmarshall@users.sourceforge.net>
201
202         Implement --download-only and --print-uris options.
203
204         * src/pkgopts.h (OPTION_DOWNLOAD_ONLY, OPTION_PRINT_URIS):
205         New manifest constants, identifying flag bits; define them.
206         (OPTION_DNLOAD_ONLY): Likewise; an alias for OPTION_DOWNLOAD_ONLY.
207
208         * src/pkgbase.h (pkgActionItem::PrintURI): New private method.
209         * src/pkginet.cpp: Implement it.
210
211         * src/clistub.c (options): Add "download-only" and "print-uris".
212         (help_text): Document them.
213         * src/pkgexec.cpp (pkgActionItem::Execute): Process them.
214
215 2011-07-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
216
217         mingw-get-0.3-mingw32-alpha-2.1 released.
218
219         * configure.ac (AC_INIT): Adjust version number.
220         * srcdist-doc/NEWS.in: Updated; document bugs fixed.
221         * All files (r0-3-alpha-2-1): Tag assigned.
222
223 2011-07-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
224
225         Adopt tar.xz as default package archive format.
226
227         * Makefile.in (TARZIP, TAREXT): New macros; define them.
228         (bindist, licdist, srcdist): Use them in place of hardcoded tar.gz
229         (maintainer-clean): Expunge tar files of any compression format.
230
231 2011-07-27  Keith Marshall  <keithmarshall@users.sourceforge.net>
232
233         Correct handling of release status in requirements specifications.
234
235         * src/debug.h (DEBUG_TRACE_DEPENDENCIES): New tracing hook; define it.
236         * src/pkgexec.cpp (pkgActionItem::SelectIfMostRecentFit): Use it; add
237         function entry/exit tracing report hooks.
238         * src/pkgdeps.cpp (pkgXmlDocument::ResolveDependencies): Likewise;
239         also add internal trace point reporting, which may also require...
240         (show_required): ...this new static inline DEBUG_INVOKED function.
241
242         * src/pkgreqs.cpp (requirement): Propagate release status and release
243         reference index fields from requirer, when package version requirement
244         is specified by a '%' token, and no explicit release status override
245         is included in the requirement specification.
246
247         * src/pkgspec.cpp (is_wildcard_spec): New static inline helper.
248         (pkgSpecs::VersionComparator): Use it to identify any package version
249         specification which may require the extension of a wildcard match, to
250         span the package version and release status fields; also add tracing
251         hooks, triggered on DEBUG_TRACE_DEPENDENCIES, to facilitate debugging.
252
253 2011-06-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
254
255         Avoid accidental RCS keyword substitutions.
256
257         * Makefile.in (DOLLAR): New macro; define it.
258         (readme.txt, readme.txt.in): Use it, where unexpanded RCS Id keyword
259         matching is intended.
260
261 2011-06-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
262
263         Mercurial support revisited.
264
265         * .cvsignore (.hgtags): Add to CVS untracked list.
266
267 2011-06-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
268
269         Update readme.txt ID tag-line to track NEWS rather than README.
270
271         * Makefile.in (readme.txt.in): New rule; implement it.
272         (readme.txt.tag): Likewise; this implements the tag-line tracking.
273         (readme.txt): Rule redefined in terms of the preceding pair.
274
275 2011-06-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
276
277         mingw-get-0.3-mingw32-alpha-2 released.
278
279         * configure.ac (AC_INIT): Adjust version number.
280         * srcdist-doc/NEWS.in: Updated; document new features and bugs fixed.
281         * All files (r0-3-alpha-2): Tag assigned.
282
283 2011-06-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
284
285         Add internal documentation for --reinstall option.
286
287         * src/clistub.c (help_text): Add description for "--reinstall".
288
289 2011-06-14  Keith Marshall  <keithmarshall@users.sourceforge.net>
290
291         Support use of Mercurial within a CVS working copy.
292
293         * .cvsignore (.hg, .hgignore): Don't have CVS track these.
294
295 2011-06-13  Keith Marshall  <keithmarshall@users.sourceforge.net>
296
297         Implement --reinstall option.
298
299         * src/pkgopts.h (OPTION_REINSTALL): New macro; define it.
300         (OPTION_GENERIC, OPTION_SHIFT_MASK): Likewise.
301         (OPTION_EXTRA_FLAGS): New field; declare it.
302
303         * src/clistub.c (options): Add "reinstall".
304         (OPTION_GENERIC): Use it where appropriate; within its scope...
305         (OPTION_STORAGE_CLASS): Improve descriptive comments; add handling for
306         default case of flag type options requiring an alignment shift.
307
308         * src/pkgexec.cpp: Remove previous "always reinstall" kludge.
309         (pkgOptionSelected, PKG_OPTION_REINSTALL): Remove obsolete macros.
310         (pkgActionItem::Execute): Check for "upgrade" request on any package
311         which is already up to date; report this state, otherwise...
312         [OPTION_REINSTALL || ACTION_UPGRADE]: Mark package as "removed", to
313         avoid bail-out on "package already installed", when calling...
314         (pkgInstall): ...this.
315
316 2011-06-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
317
318         Don't require -vv to report progress of update operation.
319
320         * src/pkgbind.cpp (pkgRepository::GetPackageList): Eliminate all
321         basename() calls; `dname' already tells us what it should return.
322         [update]: Report progress, irrespective of verbosity setting.
323
324 2011-06-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
325
326         Fix MinGW-Bug #3313806.
327
328         * src/pkginfo/pkginfo.l (CMS_KEYWORDS): Do not match them within the
329         PACKAGE_NAME field; this avoids misinterpretation as a release status
330         qualifier when intended as part of the package name, as in msys-cvs.
331
332 2011-06-07  Keith Marshall  <keithmarshall@users.sourceforge.net>
333
334         Provisional correction for MinGW-Bug #3309438.
335
336         * src/debug.h [DEBUGLEVEL == 0]: Provide defaults for...
337         (DEBUG_ENABLED, DEBUG_REQUEST): ...these macros.
338
339         * src/tarproc.cpp (pkgTarArchiveInstaller::ProcessDirectory):
340         (pkgTarArchiveInstaller::ProcessDataStream): Use DEBUG_REQUEST to
341         enable runtime trace activation for previous compile time choices.
342
343 2011-05-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
344
345         mingw-get-0.3-mingw32-alpha-1 released.
346
347         * configure.ac (AC_INIT): Adjust version number.
348         * srcdist-doc/NEWS.in: Updated; document new features.
349         * All files (r0-3-alpha-1): Tag assigned.
350
351 2011-05-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
352
353         Support assignment of DEBUGLEVEL at configure time.
354
355         * configure.ac (DEBUGLEVEL): Declare as a precious variable, using
356         AC_ARG_VAR; also declare with AC_SUBST, to ensure it is initialised.
357
358         * Makefile.in (DEBUGLEVEL): Let AC_SUBST assign it.
359
360 2011-05-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
361
362         Work around bugs in MinGW and GNU getopt_long_only() implementations.
363
364         * src/getopt.c: New file; this is a free-standing replacement for any
365         implementation provided by system libraries.  We will always use this
366         to ensure correct operation irrespective of system bugs; (different
367         bug manifestations have been identified in the stock MinGW and GNU
368         implementations).
369
370         * Makefile.in (mingw-get.EXEEXT): Use it.
371
372         * src/clistub.c (options): Remove redundant declaration of `-v' as a
373         long form option.
374
375 2011-05-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
376
377         Implement user selection of traceable features at run-time.
378
379         * src.pkgopts.h (OPTION_VERBOSE_MAX): New macro; define it.
380
381         * src/debug.h (DEBUG_ENABLED): New macro; define it.
382         (DEBUG_REQUEST, DEBUG_REQUEST_FLAGS, DEBUG_TRACE_DYNAMIC): Likewise.
383
384         * src/clistub.c (main) [--trace]: Don't make it available unless...
385         [DEBUG_ENABLED(DEBUG_TRACE_DYNAMIC)]: ...this is set (at compile-time).
386         [--verbose]: Limit to OPTION_VERBOSE_MAX, using...
387         (atmost): ...this new macro; define it.
388         (options): Declare `-v' as both long and short form, pending bug fix
389         in MinGW's getopt_long_only() implementation.
390
391         * src/pkginet.cpp (pkgInternetAgent::OpenURL): Use DEBUG_REQUEST.
392         (pkgInternetLzmaStreamingAgent::TransferData): Likewise.
393         (pkgInternetStreamingAgent::TransferData): Likewise.
394         (pkgInternetStreamingAgent::Get): Likewise.
395
396         * src/pkgunst.cpp (pkgActionItem::SetAuthorities): Use DEBUG_REQUEST.
397         (pkg_rmdir, pkg_unlink): Likewise.
398
399         * src/sysroot.cpp (pkgXmlDocument::LoadSystemMap): Use DEBUG_REQUEST.
400
401 2011-05-21  Keith Marshall  <keithmarshall@users.sourceforge.net>
402
403         Implement protocol for processing global program options.
404
405         * src/pkgopts.h: New file.
406
407         * src/climain.cpp (cli_setopts): New function; implement it.
408         (pkgOptions): Likewise.
409
410         * src/clistub.c (xatoi): New function; implement it.
411         (cli_setargv): New inline helper function; implement it.
412         (main): Use it.  Also incorporate implementation of...
413         (parsed_options): New structure; it accommodates...
414         (verbose, trace): New options; interpret them, and...
415         (help_text): ...document them.
416
417         * src/pkgbind.cpp (pkgRepository::GetPackageList): Make catalogue
418         loading notifications and progress reports conditional on...
419         [OPTION_VERBOSE > 1]: ...this.
420
421 2011-05-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
422
423         Augment known development status keywords and accept CMS labels.
424
425         * src/pkginfo/pkginfo.l (CMS_KEYWORDS): Define new provisional list;
426         add transitional state scanner rule and code to interpret them.
427         (STATUS_KEYWORDS): Add "pre" and "rc" to existing list; modify scanner
428         code to maintain consistency with CMS_KEYWORDS processing; also extend
429         this coding strategy to other rules.
430
431         * src/pkginfo/driver.c (spec): Strip initial '$' token from displayed
432         field values; (we expect it only for a CMS_KEYWORDS field value).
433
434         * src/pkgreqs.cpp (pkgSpecs::GetTarName): Remove any initial '$' token
435         from PACKAGE_RELEASE_STATUS field, when performing reverse of tarname
436         decomposition transformation.
437
438 2011-05-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
439
440         Correct omission from 2011-02-18 commit.
441
442         * src/tarproc.cpp (Copyright Notice): Add 2011 as year of release.
443
444 2011-05-14  Keith Marshall  <keithmarshall@users.sourceforge.net>
445
446         mingw-get-0.2-mingw32-alpha-4 released.
447
448         * configure.ac (AC_INIT): Adjust version number.
449         * srcdist-doc/NEWS.in: Updated; add bug-fix/feature descriptions.
450         * All files (r0-2-alpha-4): Tag assigned.
451
452 2011-05-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
453
454         Fix MinGW-Bug #3297660 (reported by Chris Sutcliffe).
455
456         * src/pkgbase.h (pkgActionItem::SetAuthorities): Return unsigned long.
457         (pkgActionItem::HasAttribute): New inline method; implement it.
458
459         * src/pkgtask.h (ACTION_DOWNLOAD, ACTION_DOWNLOAD_OK): New macros.
460
461         * src/pkginet.cpp (pkgActionItem::DownloadArchiveFiles):
462         [ACTION_DOWNLOAD]: Assert it at commencement of each package download;
463         clear it again, on successful download completion.
464
465         * src/pkginst.cpp (pkgtask.h): #include it.
466         (pkgInstall) [ACTION_DOWNLOAD]: Don't proceed with installation when
467         set; this indicates failed download; diagnose it.
468
469         * src/pkgunst.cpp (pkgRemove) [ACTION_DOWNLOAD && ACTION_UPGRADE]:
470         Don't proceed with pre-emptive removal when both set; this indicates
471         failed download of replacement package; diagnose it.
472
473 2011-05-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
474
475         Fix MinGW-Bug #3295526 (reported by Charles Wilson).
476
477         * src/pkgunst.cpp (sys/stat.h): #include it; we need it for...
478         (pkg_unlink): ...chmod( file, S_IWRITE ), emulating `rm -f' semantics.
479
480 2011-05-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
481
482         Diagnose and aggressively retry failed download connections.
483
484         * src/debug.h (DEBUG_TRACE_INTERNET_REQUESTS): New macro; define it.
485
486         * src/pkginet.cpp (debug.h): #include it.
487         (pkgDownloadMeter): New abstract class; declare it and implement its
488         default (non-abstract) data and methods; derive...
489         (pkgDownloadMeterTTY): ...this new class from it; implement it...
490         (pkgInternetStreamingAgent::Get): ...and instantiate it (naively for
491         now), as associated pkgDownloadMeter object; add tracing diagnostic.
492         (pkgInternetAgent::OpenURL): Don't inline it; move implementation out
493         of line; add retry loops to aggressively retry failed connections.
494         (pkgInternetAgent::QueryContentLength): New method; implement it.
495         (pkgInternetStreamingAgent::TransferData): Avoid Microsoft specific
496         data type `DWORD'; prefer equivalent standard `unsigned long'.  Add
497         tracing diagnostic.  Remove progress diagnostic; replace it with an
498         `Update' request to associated pkgDownloadMeter.
499         (pkgInternetLzmaStreamingAgent::GetRawData): Avoid `DWORD' data type.
500         (pkgInternetLzmaStreamingAgent::TransferData): Likewise; add tracing
501         diagnostic on failure.
502
503 2011-03-31  Keith Marshall  <keithmarshall@users.sourceforge.net>
504
505         mingw-get-0.2-mingw32-alpha-3 released.
506
507         * configure.ac (AC_INIT): Adjust version number.
508         * srcdist-doc/NEWS.in: Updated; add bug-fix description.
509         * All files (r0-2-alpha-3): Tag assigned.
510
511 2011-03-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
512
513         Provisional handling for http proxy authentication.
514         (Adapted from patch by Scott Michel <pingbak@users.sourceforge.net>)
515         (ref: MinGW-Patch #3158453)
516
517         * src/pkginet.cpp: Several format/layout adjustments; add comments.
518         Eliminate several instances of Microsoft specific typedef nastiness.
519         (dmh_dialogue_context): New macro; kludge definition to support...
520         (pkgInternetAgent::OpenURL) [HTTP_STATUS_PROXY_AUTH_REQ]: Detect
521         and handle it.
522
523 2011-03-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
524
525         Expand macros in path names for files and directories to be removed.
526
527         * src/pkgunst.cpp (pkgRemove): Format sysroot as a template, so...
528         (pkg_rmdir, pkg_unlink): ...are able to use mkpath() to construct the
529         full path name for each file or directory to be removed.
530
531 2011-03-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
532
533         Correct defective activation logic for some debugging hooks.
534
535         * src/pkgunst.cpp (pkg_rmdir, pkg_unlink) [DEBUG_INVOKE_IF]:
536         (pkgActionItem::SetAuthorities) [DEBUG_INVOKE_IF]: Use bit-wise `&'
537         operator, not `&&', to evaluate DEBUGLEVEL state.
538
539 2011-03-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
540
541         Avoid Unicode hyphens in generated ASCII document files.
542
543         * Makefile.in (NROFF): New macro; define it to invoke `nroff -Tascii'.
544         (%.dist, readme.txt): Use it to ensure that output is pure ASCII.
545
546 2011-03-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
547
548         mingw-get-0.2-mingw32-alpha-2 released.
549
550         * configure.ac (AC_INIT): Adjust version number.
551         * srcdist-doc/NEWS.in: Updated; add bug-fix description.
552         * All files (r0-2-alpha-2): Tag assigned.
553
554 2011-03-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
555
556         Fix MinGW-Bug 3212246.
557
558         * src/keyword.c (has_keyword): Avoid incrementing the comparison
559         pointers when a significant character in one string is not matched in
560         the other; previously the pointers were left pointing one character to
561         the right of the mismatch, and this was overlooked if the mismatch
562         occurred at the rightmost character in both strings.
563
564 2011-03-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
565
566         mingw-get-0.2-mingw32-alpha-1 released.
567
568         * configure.ac (AC_INIT): Set version number; correct capitalisation
569         in URI reference to bug reporting instructions.
570
571         * srcdist-doc/NEWS.in: Confirm release date.
572         [bug reporting]: Remove redundant paragraph; the information is
573         provided, via reference to mingw.org. in the README and INSTALL files.
574
575         * All files (r0-2-alpha-1): Tag assigned.
576
577 2011-03-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
578
579         * srcdist-doc/INSTALL.in [building]: Qualify liblzma.a requirement;
580         add earliest acceptable snapshot release date.
581
582 2011-03-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
583
584         Remove unused 7zip and boost source code from CVS trunk.
585
586         * 7z: Directory and all content removed.
587         * boost: Likewise.
588
589 2011-03-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
590
591         Refactor and update existing installation and usage instructions.
592
593         * src/clistub.c (help_text): Updated.
594
595         * srcdist-doc: New directory.
596
597         * README: Deleted; its content refactored into...
598         * srcdist-doc/README.in srcdist-doc/INSTALL.in srcdist-doc/NEWS.in:
599         ...these new template files, updated for current development state.
600
601         * srcdist-doc/gendoc.sed.in: New sed script; it directs formatting of
602         generated text files derived from the srcdist-doc templates.
603
604         * Makefile.in (SRCDIST_SUBDIRS): Add srcdist-doc.
605         (SRCDIST_FILES): Add NEWS and INSTALL.
606         (srcdist-doc): New build rule to generate README, NEWS and INSTALL.
607         (srcdist, licdist): Adjust path to locate them.
608         (readme.txt): New build rule to generate on-line package description.
609         (dist): Require it.
610         (distclean): Don't remove Makefile...
611         (maintainer-clean): ...but do it here instead.  Also remove generated
612         README, NEWS and INSTALL, the autom4te cache, and all distributable
613         zip files, in addition to tarballs, for the current version.
614
615 2011-02-27  Keith Marshall  <keithmarshall@users.sourceforge.net>
616
617         Initial implementation for "remove" feature.
618
619         * src/pkgbase.h: Update copyright notice; add current year.
620         (pkgActionItem::SetPrimary): New inline public method; declare it.
621         (pkgActionItem::SetAuthorities): New public method; declare it.
622
623         * src/pkgtask.h (ACTION_PREFLIGHT, ACTION_REMOVE_OK): New defines.
624
625         * src/pkgproc.h: Update copyright notice; add current year.
626         (pkgManifest::GetSysRootReference): New public method; declare it.
627         (pkgManifest::GetRoot): New inline method; declare and implement it.
628         (pkgManifest::DetachSysRoot): Argument type changed to const char*.
629         (pkgRemove): New extern "C" function; declare it.
630
631         * src/pkgexec.cpp (pkgActionItem::SetPrimary): Implement it, and...
632         (pkgXmlDocument::Schedule): ...use it to promote actions on all user
633         specified packages, as listed on the command line, to primary status.
634         (pkgActionItem::Execute): Repeatedly invoke...
635         (pkgActionItem::SetAuthorities): ...this; incorporate call of...
636         (pkgActionItem::DownloadArchiveFiles): ...this, within the loop, so
637         that we retry failed downloads at least a second time.
638         [ACTION_REMOVE]: Delete stub; invoke pkgRemove().
639
640         * src/pkgunst.cpp: New file.
641         (pkgActionItem::SetAuthorities): Implement it.
642         (pkgManifest::GetSysRootReference): Implement it.
643         (pkgManifest::DetachSysRoot): Implement it per new declaration.
644         (pkgRemove): Implement it.
645
646         * Makefile.in (CORE_DLL_OBJECTS): Add pkgunst.OBJEXT
647
648 2011-02-26  Keith Marshall  <keithmarshall@users.sourceforge.net>
649
650         Work-around for improper stderr buffering in MSYS mintty and rxvt.
651         (Merged from r0-1-alpha-5 branch).
652
653         * src/dmh.cpp (dmhTypeTTY::emit_and_flush): New private method.
654         (dmhTypeTTY::printf, dmhTypeTTY::notify): Use it to force an fflush()
655         after each output record is written to stderr.
656
657         * README: Update as appropriate.
658
659 2011-02-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
660
661         Tidy up some debugging hooks.
662
663         * src/debug.h (DEBUG_INVOKED): New macro; define it.
664         (DEBUG_INVOKE_IF): Likewise; this takes arguments providing for
665         conditional invocation of code when DEBUGLEVEL is non-zero; make it
666         expand to nothing, when DEBUGLEVEL is zero.
667         (DEBUG_TRACE_INIT): Redefined macro; value changed to 0x0010.
668         (DEBUG_TRACE_TRANSACTIONS, DEBUG_SUPPRESS_INSTALLATION):
669         (DEBUG_UPDATE_INVENTORY): New macros; define them.
670
671         * src/tarproc.cpp (pkgTarArchiveInstaller::ProcessDirectory):
672         (pkgTarArchiveInstaller::ProcessDataStream): Refactor debugging hooks;
673         implement them in terms of DEBUGLEVEL, with reference to...
674         (DEBUG_SUPPRESS_INSTALLATION, DEBUG_UPDATE_INVENTORY): ...these.
675
676 2011-02-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
677
678         Make package version comparisons more robust.
679
680         Fixes an issue reported by Chris Sutcliffe: previously, version
681         comparisons were evaluated solely on the basis of differences in the
682         package version field itself.  Henceforth, if this field compares as
683         equal, then the comparison is extended to also consider differences
684         between development phase qualifiers, and, if these too compare as
685         equal, to differences in the target subsystem version fields.
686
687         * src/pkginfo/pkginfo.h (pkgSpecs::VersionComparator): New private
688         method; declare it.
689
690         * src/pkgspec.cpp (pkgSpecs::VersionComparator): Implement it.
691         (pkgSpecs::operator<, pkgSpecs::operator<=, pkgSpecs::operator>=):
692         (pkgSpecs::operator>): Use it, replacing...
693         (version): ...this static function; now unreferenced; delete it.
694
695         * src/vercmp.h (pkgVersionInfo::pkgVersionInfo): Make it inline; it
696         now delegates the entire class construction operation to...
697         (pkgVersionInfo::Parse): ...this new private method; declare it.  This
698         is also used to facilitate implementation of...
699         (pkgVersionInfo::Reset): ...this new inline method, also requiring...
700         (pkgVersionInfo::FreeAll): ...this new inline method; also now used by
701         the class destructor, it encapsulates separate calls to...
702         (pkgVersionInfo::Free): ...this original inline method, renamed...
703         (pkgVersionInfo::FreeEntry): ...as this.
704
705         * src/vercmp.cpp (pkgVersionInfo::Parse): Implement it.
706
707 2011-02-13  Keith Marshall  <keithmarshall@users.sourceforge.net>
708
709         Merge from mingw-get-0.1-mingw32-alpha-5 bug-fix branch.
710
711         * src/pkgdeps.cpp (pkgXmlDocument::ResolveDependencies): Promote
712         "install" action on new prerequisites, where a previously uninstalled
713         package is required to satisfy any "upgrade" dependency.
714
715         * src/pkgexec.cpp (pkgActionList::Execute): Don't make misleading
716         claims concerning package removal.
717
718         * src/pkgtask.h (STRICTLY_GT, STRICTLY_LT, ACTION_PRIMARY): Add one
719         level of parentheses around defining expressions.
720
721 2011-02-10  Keith Marshall  <keithmarshall@users.sourceforge.net>
722
723         Publish mingw-get-0.0-mingw32-alpha-5.1 bug-fix release.
724
725         * README: Updated to reflect changes.
726
727 2011-02-08  Keith Marshall  <keithmarshall@users.sourceforge.net>
728
729         Improve diagnostics for failed GUI invocation.
730
731         * src/guimain.cpp: New file; currently delivers only a diagnostic
732         stub, provided by Sze Howe Koh <axfangli@users.sourceforge.net>, to
733         pop-up a message block explaining why GUI mode cannot be invoked.
734
735         * Makefile.in (GUI_LDFLAGS): New macro; it is required by...
736         (gui$EXEEXT): ...this new build rule; add to prerequisites of...
737         (all): ...this [default] build rule; redefine this in terms of...
738         (BIN_PROGRAMS, LIBEXEC_PROGRAMS, LIBEXEC_DATA): ...these new macros;
739         define them, and also use them as loop iterator objectives for...
740         (install, install_strip): ...these; also schedule them...
741         (clean): ...for removal by this.
742
743         * src/clistub.c (Copyright): Add new year.
744         (main): Amend error message, if gui$EXEEXT doesn't start; make it
745         more intelligible to normal users.
746
747 2011-02-07  Keith Marshall  <keithmarshall@users.sourceforge.net>
748
749         Correct omissions from packaged source tarball.
750
751         * Makefile.in (Copyright): Add new year.
752         (SRCDIST_FILES): Add aclocal.m4
753         (SRCDIST_SUBDIRS): Add m4
754
755 2011-01-05  Keith Marshall  <keithmarshall@users.sourceforge.net>
756
757         Reduce path names to base names, in some diagnostic message contexts.
758
759         * src/climain.cpp: Update copyright notice for new year.
760         (climain): Extract base name from argv[0], to pass as program name tag
761         in initialisation of diagnostic message handler.
762
763         * src/dmh.h, src/dmh.cpp: Update copyright notices; make some layout
764         adjustments, for more consistent formatting style.
765
766         * src/pkgbind.cpp: Update copyright notice.
767         (pkgRepository::GetPackageList): Reduce path names for catalogue files
768         to their base names, when reporting them in diagnostic messages.
769
770 2011-01-05  Keith Marshall  <keithmarshall@users.sourceforge.net>
771
772         Avoid a potential out-of-range action name look-up.
773
774         * src/pkgdeps.cpp: Update copyright notice for new year.
775         (pkgXmlDocument::Schedule): Mask action code with ACTION_MASK, to
776         determine correct action name when diagnosing uninstalled package.
777
778 2011-01-03  Keith Marshall  <keithmarshall@users.sourceforge.net>
779
780         Make "install" and "remove" notifications symmetric.
781
782         * configure.ac (AC_INIT): Bump version to "0.1-alpha-6cvs".
783         (YEARS_OF_ISSUE): Add new year.
784         
785         * src/pkginst.cpp: Update copyright notice for new year.
786         (pkgInstall): Add notification for package being installed.
787
788 2010-12-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
789
790         Add preliminary CLI support for "list" and "show" actions.
791
792         * src/pkgtask.h (ACTION_PRIMARY): New manifest constant; define it.
793         (ACTION_LIST, ACTION_SHOW): Likewise; cast to enumerated values for...
794         (action_list, action_show): ...these; define them.
795
796         * src/pkgexec.cpp (action_name): Add defining text for...
797         (action_list, action_show): ...these.
798
799         * src/climain.cpp: Partially revert 2010-11-01 change...
800         (climain) [! ACTION_UPDATE]: Reinstate original "if" block, moving
801         the "switch" block within it, but without the ACTION_UPDATE case.
802         [ACTION_LIST, ACTION_SHOW]: New "switch" cases; they invoke...
803         (pkgXmlDocument::DisplayPackageInfo): ...this new method.
804
805         * src/pkgbase.h (pkgXmlDocument::DisplayPackageInfo): Declare it.
806         (pkgActionItem::ConfirmInstallationStatus): New method; declare it.
807         (pkgXmlNode::GetSysRoot): Make declaration style consistent with
808         others in the class; do not name arguments in the declaration.
809         (pkgXmlNode::FindFirstAssociate): Likewise.
810         (pkgXmlNode::FindNextAssociate): Likewise.
811
812         * src/pkgshow.cpp: New file.
813         (pkgXmlDocument::DisplayPackageInfo): Implement it.
814
815         * src/pkgdeps.cpp (pkgMsgUnknownPackage): New extern "C" function;
816         implement it temporarily, pending a future i18n reimplementation.
817         (assert_installed): Drop "inline" attribute; leave it as "static".
818         Set "tarname" correctly, to match the installed package version; (it
819         previously incorrectly returned the latest available version).
820         (pkgActionItem::ConfirmInstallationStatus): Implement it.
821         (pkgXmlDocument::Schedule) [ACTION_PRIMARY]: Set as appropriate.
822         (pkgXmlDocument::Schedule) [ACTION_REMOVE || ACTION_UPGRADE]: Complain
823         if requested package is not recorded as having been installed.
824         (pkgXmlDocument::ResolveDependencies) [! ACTION_INSTALL]: Do not
825         invoke it recursively.
826
827         * Makefile.in (pkgshow.$OBJEXT): Add reference.
828
829 2010-11-01  Keith Marshall  <keithmarshall@users.sourceforge.net>
830
831         Lay groundwork for implentation of additional actions.
832
833         * src/climain.cpp (climain): Adjust indentation; replace `if' block...
834         [action != ACTION_UPDATE]: ...with this default `switch' case, and...
835         [action == ACTION_UPDATE]: ...this as explicit "do nothing" case.
836
837 2010-10-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
838
839         mingw-get-0.1-mingw32-alpha-5 released.
840
841         * configure.ac (AC_INIT): Bump version to 0.1-alpha-5.
842         * README: Update release notes accordingly.
843         * All files (r0-1-alpha-5): Tag assigned.
844
845 2010-10-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
846
847         Make pkgInitRites/pkgLastRites processing more robust;
848         avoid a potential race condition in mingw-get-inst.
849
850         * src/rites.c: Refactor conditional code to segregate execution of...
851         [defined IMPLEMENT_INITIATION_RITES]: ...this into distinct phases.
852         (PHASE_ONE_RITES, PHASE_TWO_RITES): Define constants to identify them.
853         (do_init_rites): Renamed to...
854         (invoke_rites): ...this; inline it.
855         (pkgLastRites): Invoke it, to pre-empt rename action of...
856         (lastrites.exe): ...this, subsequently exec()ed process.
857         (perror): Issue more informative diagnostic on exec() failure.
858
859         * src/clistub.c (IMPLEMENT_INITIATION_RITES): Stipulate as...
860         (PHASE_ONE_RITES): ...this phase of implementation only.
861
862         * src/pkgexec.cpp (IMPLEMENT_INITIATION_RITES): Define to provide...
863         (PHASE_TWO_RITES): ...this phase of implementation, facilitated by...
864         (self_upgrade_rites): ...this locally defined RITES_INLINE function.
865         (pkgActionItem::Execute): Invoke it, in remove/install loop, while...
866         [init_rites_pending]: ...new loop local variable remains true.
867
868 2010-09-10  Charles Wilson  <mingw@cwilson.fastmail.fm>
869
870         Fix packaging bug in -lic package.
871
872         * Makefile.in (licdist): Use directory named
873         "share", not "shared".
874
875 2010-09-10  Charles Wilson  <mingw@cwilson.fastmail.fm>
876
877         mingw-get-0.1-mingw32-alpha-4 released.
878
879         * All files (r0-1-alpha-4): Tag assigned.
880
881 2010-09-10  Charles Wilson  <mingw@cwilson.fastmail.fm>
882
883         Add rudimentary help option.
884
885         * README: Update release notes.
886
887         * src/clistub.c: Add --help option.
888
889 2010-09-10  Charles Wilson  <mingw@cwilson.fastmail.fm>
890
891         Fix "mingw-get deletes itself" bug in last rites handling.
892
893         * README: Add new release notes.
894
895         * configure.ac: Bump version to 0.1-alpha-4.
896
897         * src/dmh.h: If __cplusplus, include <exception> and
898         declare dmh_exception class.
899
900         * src/dmh.cpp (class dmh_exception): Implement.
901         (abort_if_fatal): If DMH_FATAL, throw dmh_exception rather
902         than calling exit().
903
904         * src/climain.cpp (climain): Wrap entire function body in try/
905         catch block. If dmh_exception is caught, return EXIT_FAILURE.
906
907         * src/clistub.c (main): Capture return value of climain(). If
908         non-zero, perform last rites and return EXIT_FAILURE.
909
910 2010-08-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
911
912         mingw-get-0.1-mingw32-alpha-3 released.
913
914         * README: Add new release notes.
915
916         * All files (r0-1-alpha-3): Tag assigned.
917
918 2010-08-27  Keith Marshall  <keithmarshall@users.sourceforge.net>
919
920         Add runtime hooks to support self-upgrade for future releases.
921
922         * src/rites.c: New file; compile it free-standing, to provide...
923         (lastrites.exe): ...this helper application for context clean-up;
924         alternatively, use it as an include file, with pre-definition of...
925         (IMPLEMENT_INITIATION_RITES): ...this, to implement...
926         (pkgInitRites, pkgLastRites): ...these inline functions.
927
928         * src/clistub.c (main) [argc > 1]: Use them.
929         (progname): New local variable within `main'; set it once, then use it
930         instead of repeated references to `basename(*argv)' in diagnostics.
931         (MINGW_GET_DLL, MINGW_GET_GUI): Relocate to `src/rites.c'.
932
933         * src/debug.h (DEBUG_INHIBIT_RITES_OF_PASSAGE):
934         (DEBUG_FAIL_FILE_RENAME_RITE, DEBUG_FAIL_FILE_UNLINK_RITE): New
935         defines; they facilitate debugging of the src/rites.c code.
936
937         * Makefile.in (lastrites$EXEEXT): New target; build as prerequisite...
938         (all): ...of this primary target.
939         (install, install-strip): Install it.
940         (SRCDIST_FILES): Remove install-sh; it is now included in...
941         (build-aux): ...this directory; add it to...
942         (SRCDIST_SUBDIRS): ...this.
943
944 2010-08-24  Keith Marshall  <keithmarshall@users.sourceforge.net>
945
946         Set default sysroots relative to mingw-get installation directory.
947
948         * xml/profile.xml (system-map) [name == default]: For each of...
949         [subsystem == mingw32]: ...set sysroot path to value of %R macro...
950         [subsystem == msys]: ...and to its %R/msys/1.0 subdirectory.
951
952 2010-08-19  Keith Marshall  <keithmarshall@users.sourceforge.net>
953
954         Some dependency resolver enhancements and bug fixes.
955
956         * src/pkgbase.h (pkgXmlNode::GetContainerAttribute): New method;
957         declare it.
958
959         * src/pkgdeps.cpp (pkgXmlNode::GetContainerAttribute): Implement it;
960         it is used to retrieve package name attributes from the containing
961         'package' element, when given a pointer to a 'release' element by...
962         (assert_unmatched, assert_installed): ...these new static functions.
963         (pkgXmlDocument::Schedule): Use them to reconstruct and register
964         dependency reference data for previously installed packages which are
965         no longer included in the distribution manifest.
966         (pkgXmlDocument::ResolveDependencies): Fix a block nesting error;
967         catch and diagnose unresolved dependencies; don't look beyond the XML
968         document root node, (tinyxml error not caught?), when searching for
969         requirements specified on container nodes.
970
971 2010-08-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
972
973         Improve scheduling of package processing requests.
974
975         * src/pkgexec.cpp (pkgXmlDocument::Schedule): Inspect entire `actions'
976         list, when checking for duplicate package processing requests; decline
977         to schedule any such duplicate, or any request which lacks a package
978         association.
979
980 2010-08-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
981
982         Lay foundation for selective compilation of debugging code.
983
984         * src/debug.h: New file...
985         * src/sysroot.cpp: Include it.
986         (pkgXmlDocument::LoadSystemMap): Make debugging output conditional...
987         [DEBUGLEVEL & DEBUG_TRACE_INIT]: ...on this new debugging state.
988
989 2010-08-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
990
991         * src/pkgkeys.h: Typo in comment: file was previously identified as
992         pkgkeys.c; corrected.
993
994 2010-08-13  Keith Marshall  <keithmarshall@users.sourceforge.net>
995
996         Improve diagnostics for invalid references to non-release XML nodes.
997
998         * src/pkgkeys.h (value_unknown): New global string; declare it.
999         * src/pkgkeys.c (value_unknown): Implement it.
1000
1001         * src/pkgname.cpp (pkgArchiveName): Identify XML element type when
1002         diagnosing references to elements of types other than release; use...
1003         (value_unknown): ...this, as appropriate.
1004
1005 2010-08-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1006
1007         Guard against a potential buffer overrun.
1008
1009         * src/pkgreqs.cpp (pkgSpecs::SetProperty): Allocate an additional
1010         byte to accommodate an extra field separator, when inserting a new
1011         data value into a previously empty field.
1012
1013 2010-07-27  Cesar Strauss  <cestrauss@gmail.com>
1014
1015         Handle the GNU long name tar header format.
1016
1017         * src/pkgproc.h (TAR_ENTITY_TYPE_GNU_LONGNAME): New manifest constant;
1018         define it.
1019         (pkgTarArchiveProcessor::EntityDataAsString): New protected method;
1020         declare and...
1021         * src/tarproc.cpp: ...implement it.
1022         (pkgTarArchiveProcessor::Process): Before building the entry pathname,
1023         check for a GNU long name type header; when found, read pathname from
1024         the entry data area, before fetching the following header, from which
1025         to retrieve the associated entity data.
1026
1027 2010-06-24  Keith Marshall  <keithmarshall@users.sourceforge.net>
1028
1029         Work around an autoconf bug (reported by Stefano Sabatini).
1030
1031         * Makefile.in (VPATH): Use @top_srcdir@ instead of ${srcdir}; current
1032         autoconf incorrectly elides references to @srcdir@ and ${srcdir} when
1033         substituting within a VPATH specification for building `in-source'.
1034         Also, prefer colons to blanks as path name separators, for improved
1035         portability to non-GNU implementations of make; (recommendation by
1036         Ralf Wildenhues).
1037
1038 2010-06-24  Keith Marshall  <keithmarshall@users.sourceforge.net>
1039
1040         Include alias search, when matching component package name.
1041
1042         * src/keyword.c (has_keyword): Rearrange argument declarations for
1043         more natural order; update all callers accordingly.  Simplify; compare
1044         keyword to be matched with each successive candidate from match-list,
1045         character-by-character and in-place, so avoiding memory allocation
1046         for any local duplicate of the passed match-list; thus...
1047         (safe_strdup): ...this static function no longer required; delete it.
1048         (string.h): No references remain; do not include it.
1049
1050         * src/pkgfind.cpp (pkgXmlNode::FindPackageByName): Augment component
1051         package name matching to include potential matches of the look-up name
1052         with trailing component name stripped off, when that matches the class
1053         name of an identified component package, and the initial substring of
1054         the look-up name, after stripping, matches any specified alias name
1055         for the containing package.
1056
1057 2010-06-10  Keith Marshall  <keithmarshall@users.sourceforge.net>
1058
1059         Address FIXME relating to identification of distributable files.
1060
1061         * install-sh: Move to...
1062         * build-aux: ...this new directory.
1063
1064         * Makefile.in (PACKAGE_DISTVERSION): Modify `sed' edit sequence; make
1065         it depend on, and ensure that it incorporates the expansion of...
1066         (PACKAGE_SUBSYSTEM): ...this new macro; defined as substitution of...
1067         (host_os): ...this autoconf variable, set by...
1068
1069         * configure.ac (AC_CANONICAL_HOST): ...this; add it, requiring...
1070         (AC_CONFIG_AUX_DIR): ...`build-aux' directory reference, providing...
1071
1072         * build-aux/config.guess, build-aux/config.sub: ...these new standard
1073         files; import them from the standard `build-aux' repository.
1074
1075 2010-05-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
1076
1077         Bump version for next release cycle.
1078
1079         * configure.ac (AC_INIT): Bump version suffix to alpha-3.
1080
1081 2010-05-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
1082
1083         mingw-get-0.1-mingw32-alpha-2 released.
1084
1085         * README: Add new release notes.
1086
1087         * xml/profile.xml: Update to use default referencing for...
1088         (package-list.xml.lzma): ...this repository master catalogue.
1089
1090         * All files (r0-1-alpha-2): Tag assigned.
1091
1092 2010-05-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1093
1094         Make provision to protect user's profile settings during upgrade.
1095
1096         * Makefile.in (install): Remove `profile.xml'; replace it with...
1097         (install-profile): ...this new prerequisite installation goal; it
1098         renames the installed copy of `profile.xml' as `defaults.xml', within
1099         the installed package image.
1100
1101         * src/pkgkeys.h (defaults_key): New key; declare it.
1102         * src/pkgkeys.c: Some cosmetic formatting (tabulation) adjustments.
1103         (defaults_key): Implement it; it refers to the `defaults.xml' file.
1104
1105         * src/climain.cpp (climain): Check `profile_key' for accessibility of
1106         the `profile.xml' file; if [! R_OK] emit a diagnostic warning, fall
1107         back on `defaults_key', and attempt to load configuration from the
1108         distributed `defaults.xml' file.
1109
1110 2010-05-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
1111
1112         Add preliminary support for future `-reinstall' option.
1113
1114         * src/pkgexec.cpp (pkgActionItem::Execute) [ACTION_INSTALL]: Force
1115         installation if `-reinstall' option is selected, overriding state of
1116         any prior installation; temporarily assume that this option is always
1117         selected, to permit proper `upgrade' operation in the absence of any
1118         functional `uninstall' capability, and pending implementation of a
1119         mechanism for interpreting user specified options.
1120
1121 2010-05-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
1122
1123         Correct handling for "%R" macro in relative sysroot path specs.
1124
1125         * src/tarproc.cpp (pkgTarArchiveProcessor): In constructor, expand the
1126         sysroot path specification a second time, to capture the effect of any
1127         embedded macros, before computing the recorded `sysroot_len' value.
1128
1129 2010-05-05  Keith Marshall  <keithmarshall@users.sourceforge.net>
1130
1131         Handle "%" wildcard matches in package and subsystem version strings.
1132
1133         * src/pkgbase.h (pkgSpecs): Forward declare it.
1134         (pkgActionItem::~pkgActionItem): Declare explicit destructor.
1135         (pkgActionItem::SetRequirements): Add extra `pkgSpecs*' argument;
1136         update references, passing additional argument in...
1137
1138         * src/pkgdeps.cpp (pkgXmlDocument::ResolveDependencies): ...this.
1139
1140         * src/pkgexec.cpp (pkgActionItem::~pkgActionItem): Implement it.
1141         (pkgActionItem::SetRequirements): Delete obsolete implementation.
1142
1143         * src/pkginfo/pkginfo.h: Update copyright notice; add year 2010.
1144         (pkgSpecs::GetTarName): New public method; declare it.
1145         (pkgSpecs::SetProperty): New private method; declare it.
1146         (pkgSpecs::SetPackageName): New inline method; implement it.
1147         (pkgSpecs::SetPackageVersion, pkgSpecs::SetPackageBuild): Likewise.
1148         (pkgSpecs::SetSubSystemName, pkgSpecs::SetSubSystemVersion): Likewise.
1149         (pkgSpecs::SetSubSystemBuild, pkgSpecs::SetReleaseStatus): Likewise.
1150         (pkgSpecs::SetReleaseIndex, pkgSpecs::SetComponentClass): Likewise.
1151         (pkgSpecs::SetComponentVersion, pkgSpecs::SetPackageFormat): Likewise.
1152         (pkgSpecs::SetCompressionType): Likewise.
1153
1154         * src/pkginfo/pkginfo.l: Update copyright notice; add year 2010.
1155         (TRANS): Interpret "%" as wildcard in version string matches.
1156
1157         * src/pkgreqs.cpp: New file.
1158         (pkgActionItem::SetRequirements): Reimplement per new declaration;
1159         it now always allocates heap memory for requirements specifications.
1160         (pkgSpecs::GetTarName, pkgSpecs::SetProperty): Implement them.
1161
1162         * Makefile.in (CORE_DLL_OBJECTS): Add `pkgreqs.$(OBJEXT)'.
1163
1164 2010-04-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
1165
1166         Revert 2010-04-04 refactoring of tarproc.cpp and tarinst.cpp
1167
1168         * src/tarinst.cpp: File removed; its content merged into...
1169         * src/tarproc.cpp: ...this; it cannot be cleanly separated out.
1170
1171         * Makefile.in (tarinst.$OBJEXT): Remove reference.
1172
1173 2010-04-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
1174
1175         Handle "*" wildcard matches in package and subsystem version strings.
1176
1177         * src/vercmp.h (pkgVersionInfo::version_string): New private member
1178         variable; it stores a pointer to a dynamically allocated local copy of
1179         the invariant `version' argument, to facilitate correct parsing.
1180         (pkgVersionInfo::build_string): Likewise; it provides similar handling
1181         for the invariant `build' argument.
1182         (pkgVersionInfo::Free): New private inline method; it provides a NULL
1183         pointer safe wrapper, calling the C library `free()' function, (since
1184         some implementations are believed to be unsafe); it is used by...
1185         (pkgVersionInfo::~pkgVersionInfo): ...this new inline destructor, to
1186         release the memory allocated by the constructor, for `version_string'
1187         and `build_string'.
1188
1189         * src/vercmp.cpp (pkgVersionInfo::pkgVersionInfo): Allocate memory for
1190         `version_string' and `build_string', as required; populate it.
1191         Explicitly handle "*" as a `match anything' wildcard...
1192         (pkgVersionInfo::Compare): ...matching it as `equal' to everything.
1193
1194 2010-04-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
1195
1196         Correct omission from configure script prerequisite checks.
1197
1198         * aclocal.m4 (MINGW_AC_OUTPUT): New macro; it wraps AC_OUTPUT itself,
1199         adding a trap to force an abort if any preceding prerequisite check
1200         was handled by MINGW_AC_ASSERT_MISSING.
1201
1202         * configure.ac: Qualify package component types, in prerequisite
1203         checks handled by MINGW_AC_ASSERT_MISSING; invoke MINGW_AC_OUTPUT
1204         in place of AC_OUTPUT.
1205
1206 2010-04-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
1207
1208         Add configure script checks for prerequisite library headers.
1209         (Thanks to Cesar Strauss for proposing a rudimentary implementation).
1210
1211         * aclocal.m4: New file; it does no more than include...
1212         * m4/missing.m4: ...this; new file incorporated from build-aux module.
1213
1214         * configure.ac: Add AC_CHECK_HEADER assertions for...
1215         (zlib.h, bzlib.h, lzma.h): ...these; invoke MINGW_AC_ASSERT_MISSING in
1216         respect of each failing assertion.
1217
1218 2010-04-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
1219
1220         Case-insensitive subsystem name matching revisited.
1221
1222         * src/pkgfind.cpp (pkgXmlDocument::FindPackageByName): Use...
1223         (subsystem_strcmp): ...this to match subsystem names, instead of...
1224         (match_if_explicit): ...this.
1225
1226 2010-04-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
1227
1228         Enable recursive processing of repository package lists.
1229
1230         * src/pkgbase.h (pkgXmlDocument::SyncRepository): Make it public.
1231
1232         * src/pkgbind.cpp (pkgRepository): New locally defined and implemented
1233         class; it facilitates recursive loading and parsing of package lists,
1234         replacing much of the original non-recursive functionality within...
1235         (pkgXmlDocument::BindRepositories): ...this; use it.
1236
1237 2010-04-04  Keith Marshall  <keithmarshall@users.sourceforge.net>
1238
1239         Implement installer function; use per-package file manifests.
1240
1241         * src/pkgproc.h (pkgManifest): New class; declare it.
1242         (pkgArchiveProcessor::origin): New protected member variable.
1243         (pkgArchiveProcessor::sysroot_len): New protected member variable.
1244         (pkgArchiveProcessor::installed): Type changed to `pkgManifest *'.
1245         (pkgTarArchiveInstaller::Process): Declare specialisation hook.
1246         (pkgTarArchiveInstaller::UpdateInstallationManifest): Disused member
1247         function; remove redundant declaration from class definition.
1248         (pkgInstall): New generalised installation function; declare it.
1249         (pkgRegister): New function; declare it.
1250
1251         * src/pkginst.cpp: New file.
1252         (pkgManifest, pkgInstall, pkgRegister): Implement them.
1253
1254         * src/pkgexec.cpp (pkgActionItem::Execute): Use `pkgInstall' in place
1255         of stub formerly provided here.
1256
1257         * src/pkgkeys.h (manifest_key, reference_key): New keys; declare them.
1258         * src/pkgkeys.c (manifest_key, reference_key): Implement them.
1259
1260         * src/tarproc.cpp: Code refactored.
1261         (pkgTarArchiveProcessor::sysroot_len): Initialise it.
1262         (pkgTarArchiveProcessor::origin): Initialise it.
1263         (pkgTarArchiveProcessor::installed): Initialise; associate it with a
1264         pkgManifest class entity, and populate this as appropriate.
1265         (pkgTarArchiveProcessor::~pkgTarArchiveProcessor): Add explicit clean
1266         up of linked `pkgManifest *' entity referenced by `installed'.
1267         (pkgTarArchiveProcessor::Process) [TAR_ENTITY_TYPE_DIRECTORY]: Add
1268         braces to demarcate localised inner scope of string scan for removal
1269         of trailing directory name separators; (thanks to Cesar Strauss for
1270         reporting invalid local pointer declaration error in GCC >= 4.4).
1271         (pkgTarArchiveInstaller::UpdateInstallationManifest): Deleted.
1272         (pkgTarArchiveInstaller::pkgTarArchiveInstaller): Factor out.
1273         (pkgTarArchiveInstaller::ProcessDirectory): Likewise.
1274         (pkgTarArchiveInstaller::ProcessDataStream): Likewise.
1275         (commit_saved_entity): Likewise.
1276
1277         * src/tarinst.cpp: New file; it implements...
1278         (pkgTarArchiveInstaller::Process): ...this new specialisation
1279         of the original pkgTarArchiveProcessor::Process method...
1280         (pkgTarArchiveInstaller::pkgTarArchiveInstaller): ...and this
1281         refactored code, abstracted from src/tarproc.cpp and modified to
1282         use the pkgManifest class for installation tracking.
1283         (pkgTarArchiveInstaller::ProcessDirectory): Likewise.
1284         (pkgTarArchiveInstaller::ProcessDataStream): Likewise.
1285         (commit_saved_entity): Relocated from src/tarproc.cpp.
1286
1287         * Makefile.in (CORE_DLL_OBJECTS): Add...
1288         (pkginst.OBJEXT, tarinst.OBJEXT): ...these new object files.
1289
1290 2010-03-31  Keith Marshall  <keithmarshall@users.sourceforge.net>
1291
1292         Guard against NULL pointer dereferences in tinyxml code.
1293
1294         * src/pkgbase.h (pkgXmlNode::GetName): Verify `this' pointer is
1295         non-NULL, before invoking the underlying tinyxml method.
1296         (pkgXmlNode::GetParent, pkgXmlNode::GetChildren): Likewise.
1297         (pkgXmlNode::GetNext, pkgXmlNode::GetPropVal): Likewise.
1298         (pkgXmlNode::AddChild, pkgXmlNode::DeleteChild): Likewise.
1299         (pkgXmlNode::GetDocumentRoot): Likewise.
1300         (pkgXmlNode::IsElementOfType): Likewise.
1301
1302 2010-03-28  Cesar Strauss  <cestrauss@gmail.com>
1303
1304         Avoid running InternetAttemptConnect in pkgInternetAgent
1305         constructor, since it is called during DLL initialisation.
1306
1307         * src/pkginet.cpp (pkgInternetAgent::pkgInternetAgent): Move the
1308         InternetAttemptConnect call from constructor...
1309         (pkgInternetAgent::OpenURL): ...to here.
1310
1311 2010-03-23  Keith Marshall  <keithmarshall@users.sourceforge.net>
1312
1313         Automate object code dependency tracking.
1314
1315         * Makefile.in (DEPFLAGS): New macro; define it.
1316         (%.OBJEXT: %.c, %.OBJEXT: %.cpp): Add dependency generator commands...
1317         (%.d): ...to create these dependency maps; `sinclude' them, and...
1318         (clean): ...remove them.
1319         
1320         * .cvsignore (*.d): Add wild card template to match them.
1321
1322 2010-03-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
1323
1324         Support case insensitive matching for file and subsystem names.
1325
1326         * src/pkgbase.h (safe_strcmp): New inline function; it provides NULL
1327         argument safe comparison of strings, returning the boolean inverse of
1328         the `strcmp' result, using either case-sensitive or case-insensitive
1329         semantics; derive it from...
1330         (match_if_explicit): ...this; redefine as macro; invoke `safe_strcmp'
1331         using explicitly case-sensitive semantics.
1332         (subsystem_strcmp): New macro; it invokes `safe_strcmp' with either
1333         case-sensitive or case-insensitive semantics, depending on...
1334         (CASE_INSENSITIVE_SUBSYSTEMS): ...this new context selection macro; it
1335         fixes the choice between case-sensitive and case-insensitive matching
1336         semantics for any given implementation, at compile time.
1337         (pkg_strcmp): New macro; it invokes `safe_strcmp' with either
1338         case-sensitive or case-insensitive semantics, depending on...
1339         (CASE_INSENSITIVE_FILESYSTEM): ...this new context selection macro; it
1340         fixes the choice between case-sensitive and case-insensitive matching
1341         semantics for any given implementation, at compile time.
1342
1343         * src/sysroot.cpp (pkgXmlNode::GetSysRoot): Use `subsystem_strcmp'.
1344
1345 2010-03-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
1346
1347         Add preliminary support for virtual packages.
1348
1349         * src/pkgkeys.h (yes_value, no_value): Redefine as aliases...
1350         (value_yes, value_no): ...for these new global strings; declare them.
1351         (value_none, value_virtual): New global strings; declare them.
1352
1353         * src/pkgkeys.c (yes_value, no_value): Rename...
1354         (value_yes, value_no): ...to implement these, respectively.
1355         (value_none, value_virtual): Implement them.
1356
1357         * src/pkgname.cpp (pkgXmlNode::ArchiveName): Check containing package
1358         node for `class' attribute set to `value_virtual'; if present, always
1359         return the effective `tarname' property as `value_none'.
1360
1361         * src/pkginet.cpp (pkgActionItem::DownloadArchiveFiles): For packages
1362         with an effective `tarname' of `value_none', do not download anything.
1363
1364         * src/pkgexec.cpp (pkgActionItem::Execute): For packages with an
1365         effective `tarname' of `value_none', do not invoke any tar archive
1366         processing function.
1367
1368 2010-03-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
1369
1370         Don't write installation records for unavailable packages.
1371
1372         * src/tarproc.cpp (pkgTarArchiveInstaller): In constructor, ensure
1373         archive is ready for processing, before initialising an installation
1374         manifest record.
1375
1376 2010-03-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
1377
1378         Rationalise path identification for XML file locations.
1379
1380         * src/sysroot.cpp (pkgXmlDocument::LoadSystemMap): Use `xmlfile()'
1381         function to locate `sysroot' map file; free memory when done.
1382         (pkgXmlDocument::UpdateSystemMap): Likewise.
1383         (sigpath): Static global variable disused; delete it.
1384
1385 2010-03-01  Keith Marshall  <keithmarshall@users.sourceforge.net>
1386
1387         Extend package name search to include component packages.
1388
1389         * src/pkgfind.cpp (pkgHasMatchingName): Remove; fold it into...
1390         (pkgXmlNode::FindPackageByName): ...this; augment to extend search
1391         within package definition elements, seeking a potential match on an
1392         included component package name or component class-implied name.
1393
1394         * src/pkgkeys.h (class_key): New global string constant; declare it.
1395         * src/pkgkeys.c (class_key): Implement it.
1396
1397 2010-02-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
1398
1399         Bump version for next release cycle.
1400
1401         * configure.ac (AC_INIT): Bump version suffix to alpha-2.
1402
1403 2010-02-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
1404
1405         mingw-get-0.1-mingw32-alpha-1 released.
1406
1407 2010-02-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
1408
1409         Prepare initial package release.
1410
1411         * README: New file; use it to source release notes.
1412
1413         * Makefile.in (SRCDIST_FILES): Use ...
1414         (LICENCE_FILES): ...this new macro; define it.
1415         (licdist): New build goal; implement it.
1416         (bindist): Require it; add alternative `zip' format package.
1417
1418         * xml/profile.xml (repository): Set default `package-index' name.
1419         (system-map): Normalise spelling for default `sysroot' path names.
1420
1421 2010-02-10  Keith Marshall  <keithmarshall@users.sourceforge.net>
1422
1423         Add directory/file records in installation manifests.
1424
1425         * src/pkgkeys.h (dirname_key, filename_key): New strings; declare...
1426         * src/pkgkeys.c (dirname_key, filename_key): ...and implement them.
1427
1428         * src/pkgproc.h (pkgArchiveProcessor::installed): New class member
1429         variable; declare it.
1430         (pkgTarArchiveInstaller::UpdateInstallationManifest): New method;
1431         declare it.
1432
1433         * src/tarproc.cpp: Miscellaneous comment updates.
1434         (pkgTarArchiveInstaller): In constructor...
1435         (pkgTarArchiveInstaller::installed): ...use new member variable...
1436         (pkgArchiveProcessor::installed): ...inherited from this.
1437         (pkgTarArchiveInstaller::UpdateInstallationManifest): Implement and...
1438         (pkgTarArchiveInstaller::ProcessDataStream): ...use it.
1439         (pkgTarArchiveInstaller::ProcessDirectory): Likewise.
1440
1441 2010-02-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
1442
1443         Work around a deficiency in Microsoft's stat() implementation.
1444
1445         * src/tarproc.cpp (pkgTarArchiveProcessor::ProcessDirectory): Don't
1446         pass a `pathname' argument with trailing slashes; strip them off.
1447
1448 2010-02-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
1449
1450         Add machinery for installation and packaging for distribution.
1451
1452         * install-sh: New file; source it from autoconf distribution.
1453
1454         * configure.ac (AC_PREFIX_DEFAULT): Assign it as `C:/MinGW'.
1455         (AC_PROG_MKDIR_P, AC_PROG_INSTALL, AC_PROG_LN_S): Invoke these.
1456         (STRIP): New output variable; use AC_CHECK_TOOL to define it.
1457
1458         * Makefile.in (abs_top_srcdir): Define to AC_SUBST value.
1459         (PACKAGE_TARNAME, PACKAGE_VERSION): Define to AC_SUBST values.
1460         (prefix, exec_prefix, bindir, libexecdir, localstatedir): Likewise.
1461         (INSTALL, INSTALL_PROGRAM, INSTALL_SCRIPT, INSTALL_DATA): Likewise.
1462         (STRIP): New macro; define it using AC_CHECK_TOOL substitution.
1463         (mkinstalldirs): New macro; define it as AC_PROG_MKDIR_P result.
1464         (LN_S): New macro; define it as AC_PROG_LN_S result.
1465         (dist, srcdist, bindist): New build objectives; implement them.
1466         (install, installdirs, install-strip, maintainer-clean): Likewise.
1467         (SRCDIST_FILES, SRCDIST_SUBDIRS): New macros; define them.
1468         (PACKAGE_DISTNAME, PACKAGE_DISTVERSION): Likewise.
1469         (PACKAGE_DISTROOT, PACKAGE_ROOTVERSION): Likewise.
1470         (PACKAGE_CONFIG_DIR): Likewise.
1471
1472 2010-02-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
1473
1474         Implement package installer for tar archives.
1475
1476         * src/pkgexec.cpp (pkgXmlDocument::Execute): Replace existing
1477         stub implementation of installer, using methods provided by...
1478         * src/pkgproc.h, src/tarproc.cpp: ...these new files, with trap...
1479         * src/pkgdeps.cpp (pkgXmlDocument::Schedule) [installed]: Add entry...
1480         (pkgActionItem::Selection) [to_remove]: ...for this; use it to detect
1481         `install' requests for packages which are aleady installed.
1482
1483         * Makefile.in (CORE_DLL_OBJECTS): Add tarproc.$(OBJEXT); specify
1484         dependencies as appropriate.
1485
1486         * src/sysroot.cpp (pkgXmlDocument::LoadSystemMap): Don't commit
1487         newly created `sysroot' mapping records to disk; defer to...
1488         (pkgXmlDocument::UpdateSystemMap): ...this new method.
1489         (sigpath): Make it a global variable, with file (static) scope.
1490
1491         * src/climain.cpp (pkgXmlDocument::UpdateSystemMap): Invoke it.
1492
1493         * src/pkgkeys.h (download_key, modified_key, source_key): New global
1494         string variables; declare them, providing their implementations...
1495         * src/pkgkeys.c (download_key, modified_key, source_key): ...here.
1496         * src/pkgname.cpp (download_key, source_key): Use them.
1497
1498         * src/pkginet.cpp (pkgActionItem::ArchivePath): Delete; replace...
1499         * src/mkpath.c (pkgArchivePath): ...with this free standing function.
1500         * src/mkpath.h (pkgArchivePath): Declare its prototype.
1501
1502         * src/pkgbase.h (pkgActionItem::ArchivePath): Delete declaration.
1503         (pkgXmlDocument): Add a default constructor; implement as `inline'.
1504         (pkgXmlDocument::AddDeclaration): Use heap memory to allocate the new
1505         declaration object, instead of `auto' variable, to avoid scope error.
1506         (pkgXmlDocument::UpdateSystemMap): Declare it.
1507
1508 2010-01-26  Keith Marshall  <keithmarshall@users.sourceforge.net>
1509
1510         Implement rudimentary dependency resolver.
1511
1512         * src/pkgdeps.cpp: New file.
1513
1514         * Makefile.in (CORE_DLL_OBJECTS): Add pkgdeps.$(OBJEXT) reference;
1515         establish header file dependencies.
1516
1517         * src/pkgbase.h (to_remove, to_install, selection_types): New enum.
1518         (pkgActionItem::selection): Extend it to store as enumerated pair...
1519         (pkgActionItem::SelectPackage): New inline method; assign them.
1520         (pkgActionItem::Selection): New inline method; retrieve them.
1521         (pkgXmlNode::GetInstallationRecord): New method; declare it.
1522
1523         * src/pkgexec.cpp (pkgActionItem): In constructor...
1524         (selection): ...initialise both references in enumerated pair.
1525         (pkgActionItem::GetReference): Use `Selection()' method.
1526         (pkgActionItem::SelectIfMostRecent): Ditto; also correct logic for
1527         making selection, and assign to `to_install' element.
1528         (pkgXmlDocument::Schedule): Don't update `request'.
1529         (pkgActionItem::Execute): Implement as stub.
1530
1531         * src/pkginet.cpp (pkgActionItem::DownloadArchiveFiles): Use new
1532         `Selection()' method.
1533
1534         * src/pkgkeys.h (yes_value, no_value): Declare new string constants.
1535         * src/pkgkeys.c (yes_value, no_value): Implement them.
1536
1537         * src/vercmp.cpp: Update copyright notice.
1538         (pkgVersionInfo::operator<=): Bug fix; must test for `<', but had `>'.
1539
1540 2010-01-23  Keith Marshall  <keithmarshall@users.sourceforge.net>
1541
1542         Avoid segmentation faults when processing invalid data streams.
1543
1544         * src/pkgstrm.h: Update copyright notice.
1545         (pkgArchiveStream::IsReady): New pure virtual method.
1546         (pkgRawArchiveStream::IsReady): Provide inline implementation.
1547         (pkgGzipArchiveStream::IsReady): Likewise.
1548         (pkgBzipArchiveStream::IsReady): Likewise.
1549         (pkgLzmaArchiveStream::IsReady): Likewise.
1550         (pkgXzArchiveStream::IsReady): Likewise.
1551
1552         * src/pkgstrm.cpp: Update copyright notice.
1553         (pkgLzmaArchiveStream, pkgXzArchiveStream) [fd == -1]: Decline to
1554         perform any form of read or decode processing.
1555
1556         * src/pkginet.cpp (pkgInternetLzmaStreamingAgent): Use `fd = -2' as
1557         pseudo-descriptor for the pkgLzmaArchiveStream derived component of
1558         this internet data streaming class.
1559
1560 2010-01-23  Keith Marshall  <keithmarshall@users.sourceforge.net>
1561
1562         Require liblzma >= liblzma-4.999.9beta_20091209-3-mingw32-dev
1563
1564         * src/pkgstrm.h (LZMA_API_STATIC): Remove definition and associated
1565         comment; it was required to permit, (but not to enforce), linking to
1566         the static liblzma.a library, with earlier beta releases, but this
1567         anomaly has now been corrected.
1568
1569 2010-01-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
1570
1571         Remove zlib sources from trunk.
1572         (Application builders should use free standing implementation of
1573          zlib, from MinGW's package distribution page on SourceForge).
1574
1575 2010-01-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
1576
1577         Remove bzip2 sources from trunk.
1578         (Application builders should use free standing implementation of
1579          bzip2, from MinGW's package distribution page on SourceForge).
1580
1581 2010-01-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
1582
1583         Add subsystem specific sysroot mapping facility.
1584
1585         * src/pkghash.c: New file; required by...
1586         * src/sysroot.cpp: New file; it implements...
1587         (pkgXmlDocument::LoadSystemMap, pkgXmlNode::GetSysRoot): New methods.
1588
1589         * src/pkgbase.h: Update copyright notice.
1590         (pkgXmlDocument::LoadSystemMap): Declare it.
1591         (pkgXmlDocument::AddDeclaration): New inline method.
1592         (pkgXmlDocument::SetRoot, pkgXmlDocument::Save): Likewise.
1593         (pkgXmlNode::GetSysRoot): Declare it.
1594         (pkgXmlNode::GetDocumentRoot): New inline method.
1595         (pkgXmlNode::AddChild, pkgXmlNode::DeleteChild): Likewise.
1596
1597         * src/climain.cpp: Update copyright notice.
1598         (climain): Invoke pkgXmlDocument::LoadSystemMap() as required.
1599
1600         * Makefile.in (CORE_DLL_OBJECTS): Add ...
1601         (pkghash.$(OBJEXT), sysroot.$(OBJEXT)): ...these; upate dependencies.
1602         (DEBUGLEVEL): New macro; define it.
1603         (CPPFLAGS): Use it.
1604
1605 2010-01-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
1606
1607         Assign standardised keys for XML database lookup.
1608
1609         * src/pkgkeys.h: New file; provide public key declarations.
1610         * src/pkgkeys.c: New file; implement them.
1611
1612         * src/pkgbind.cpp: Use them; update copyright notice.
1613         * src/pkgexec.cpp, src/pkgfind.cpp, src/pkginet.cpp: Likewise.
1614         * src/pkgname.cpp, src/pkgspec.cpp: Likewise.
1615
1616         * Makfile.in (CORE_DLL_OBJECTS): Add pkgkeys.$(OBJEXT); update all
1617         dependencies accordingly.
1618
1619 2010-01-08  Keith Marshall  <keithmarshall@users.sourceforge.net>
1620
1621         Add CLI version reporting option.
1622
1623         * configure.ac: Update copyright notice for new year.
1624         (COPYRIGHT_HOLDER): New AC_SUBST variable; define it.
1625         (YEARS_OF_ISSUE): New AC_SUBST variable; define it.
1626         (AC_CONFIG_FILES): Add `version.c'; source it from...
1627
1628         * version.c.in: ...this new file.
1629
1630         * Makefile.in: Update copyright notice for new year.
1631         (mingw-get$(EXEEXT)): Add dependency on `version.$(OBJEXT)'.
1632         (distclean): Add `version.c'.
1633
1634         * configure: Regenerated.
1635
1636         * src/clistub.c: Update copyright notice for new year.
1637         (options): New array of `struct option'; define and use it as the
1638         reference for `argv' parsing with `getopt_long_only()'.
1639
1640 2009-12-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
1641
1642         Add CLI support for "update" action.
1643
1644         * src/pkgtask.h (ACTION_UPDATE): Define it, derived from...
1645         (action_update): ...this new entry in anonymous enumeration.
1646         
1647         * src/pkgexec.cpp (action_name): Add "update" keyword identification.
1648
1649         * src/pkgbase.h: Typo in comment; s/xwXmlDocument/wxXmlDocument/.
1650         (pkgXmlDocument::BindRepositories): Add `force_update' parameter...
1651         * src/pkgbind.cpp (pkgXmlDocument::BindRepositories): Use it to...
1652         (pkgXmlDocument::SyncRepository): ...invoke this method when passed as
1653         a `true' flag, in addition to (as previously) first time reference.
1654
1655         * src/climain.cpp (climain): Interpret "update" keyword for...
1656         [ACTION_UPDATE]: ...passing state as `force_update' parameter to...
1657         (pkgXmlDocument::BindRepositories): ...this method, then...
1658         [!ACTION_UPDATE]: Follow with normal action processing.
1659
1660 2009-12-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
1661
1662         Add status checking for Internet URL connections.
1663
1664         * src/pkginet.cpp (pkgInternetAgent::QueryStatus): New method.
1665         (pkgInternetStreamingAgent::Get): Use it; set `dl_status' as return
1666         value, deferring failure diagnostics to callers, i.e. to...
1667         (pkgXmlDocument::SyncRepositories): ...this, and to...
1668         (pkgActionItem::DownloadArchiveFiles): ...this.
1669
1670 2009-11-23  Keith Marshall  <keithmarshall@users.sourceforge.net>
1671
1672         Add package download and repository synchronisation machinery.
1673
1674         * src/pkgstrm.h: New header file.
1675
1676         * src/pkgbind.cpp, src/pkginet.cpp, src/pkgstrm.cpp,
1677         src/pkgfind.cpp, src/pkgname.cpp, src/keyword.c: New files.
1678         * Makefile.in (CORE_DLL_OBJECTS): Add build goals for them.
1679
1680         * xml: New directory.
1681
1682         * src/climain.cpp (climain): Establish repository bindings from...
1683         * xml/profile.xml: ...this new configuration file.
1684
1685 2009-11-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
1686
1687         Add XML database bindings and preliminary action executive for CLI.
1688
1689         * src/pkgbase.h, src/pkgtask.h,
1690         src/mkpath.h, src/vercmp.h: New header files.
1691
1692         * src/climain.cpp, src/pkgexec.cpp, src/pkgspec.cpp,
1693         src/mkpath.c, src/vercmp.cpp, src/xmlfile.c: New files.
1694
1695         * Makefile.in (CORE_DLL_OBJECTS): Define initial set of files...
1696         (mingw-get-0.dll): ...build them into this new DLL target; add it...
1697         (all): ...as prerequisite for this primary build goal.
1698
1699 2009-11-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1700
1701         Avoid some potential GCC warnings.
1702
1703         * src/clistub.c: Include process.h for `execv' prototype...
1704         (main): Cast `argv' to appropriately matched type when calling it.
1705
1706         * src/pkginfo/driver.c: Include stdlib.h for `free' prototype.
1707
1708 2009-11-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
1709
1710         Create diagnostic message handler for CLI usage.
1711
1712         * src/dmh.h: New header file; it defines the public interface.
1713         * src/dmh.cpp: New file; it implements the message handler.
1714
1715 2009-11-05  Keith Marshall  <keithmarshall@users.sourceforge.net>
1716
1717         Correct some identified TinyXML issues.
1718
1719         * tinyxml/tinyxml.h (IsWhiteSpace): Add FIXME annotation to flag
1720         probable redundancy of checks for '\n' and '\r'.
1721         * tinyxml/tinyxmlparser.cpp: Revert John E's 2008-08-09 change; remove
1722         all such redundancies in IsWhiteSpace() calls throughout.
1723
1724         * tinyxml/tinyxml.cpp (TiXmlAttribute::SetDoubleValue): Correct format
1725         specification in sprintf()/snprintf() calls; "%lf" is invalid; replace
1726         with "%f".
1727
1728 2009-10-31  Keith Marshall  <keithmarshall@users.sourceforge.net>
1729
1730         Add CLI loader stub.
1731
1732         * src/clistub.c: New file.
1733         * Makefile.in: Add build rule for it; build as...
1734         (mingw-get.exe): ...this; also add to...
1735         (clean): ...this goal.
1736
1737 2009-10-31  Keith Marshall  <keithmarshall@users.sourceforge.net>
1738
1739         Set up build mechanism.
1740
1741         * configure.ac, Makefile.in: New files.
1742         * .cvsignore (configure, autom4te.cache): Add to ignored files.
1743
1744 2009-10-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
1745
1746         Add GPL-v3 licensing terms.
1747
1748         * COPYING: New file, sourced from gnu.org.
1749
1750 2009-10-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1751
1752         Add pkginfo implementation.
1753
1754         * src, src/pkginfo: New directories.
1755         * src/pkginfo/pkginfo.h, src/pkginfo/pkginfo.l: New files.
1756         * src/pkginfo/driver.c: New file.
1757
1758 2009-10-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1759
1760         Create tdm-branch.
1761
1762         * All files (tdm-branch): Assign new branch tag.
1763         * All top-level files: Remove from trunk.
1764         * ChangeLog: New file.