OSDN Git Service

f308e0854d60471395437318a13c21d8f344521c
[mingw/mingw-get.git] / ChangeLog
1 2013-01-07  Keith Marshall  <keithmarshall@users.sourceforge.net>
2
3         Update copyright notification for development in new year.
4
5         * configure.ac (YEARS_OF_ISSUE): Add year 2013.
6
7         * Makefile.in (version.c, guidata.$OBJEXT): Make them depend on...
8         (Makefile): ...this, so YEARS_OF_ISSUE propagates to built objects.
9
10 2012-12-24  Keith Marshall  <keithmarshall@users.sourceforge.net>
11
12         Work around a GUI action scheduling instability.
13
14         * src/guimain.h (AppWindowMaker::UpdateDataSheet): Declare new method.
15         * src/pkgdata.cpp (AppWindowMaker::UpdateDataSheet): Implement it.
16         (AppWindowMaker::OnNotify): Use it.
17
18         * src/guiexec.cpp (AppWindowMaker::OnCommand) [IDD_REPO_APPLY]:
19         Don't refresh package list view in-place; clear and reload it instead.
20
21 2012-12-21  Keith Marshall  <keithmarshall@users.sourceforge.net>
22
23         Update distribution build rules.
24
25         * Makefile.in (SRCDIST_FILES): Remove version.c.in; this was moved
26         to src/version.c.in, and is now automatically included via...
27         (SRCDIST_SUBDIRS): ...this; remove build-aux and build-aux/m4; we want
28         only selected files from these, as filtered by specification in...
29         (BUILD_AUX_DIRS, BUILD_AUX_FILES): ...these new macros; define them.
30         (BLDTAG, SCMTAG, GCMTAG): New release class macros; define them.
31         (bindist, licdist, srcdist): Use them.
32
33 2012-12-21  Keith Marshall  <keithmarshall@users.sourceforge.net>
34
35         Update CLI implementation hooks for GUI integration.
36
37         * Makefile.in (LIBEXEC_PROGRAMS): Replace gui$EXEEXT with
38         guistub$EXEEXT; update make goal references accordingly.
39
40         * src/rites.c (MINGW_GET_GUI): Redefine to be guimain$EXEEXT.
41         (MINGW_GET_GFB): Define new fall-back; let it be guistub$EXEEXT.
42         (RITES_IMPLEMENTATION): Perform rites for MINGW_GET_GUI.
43
44         * src/clistub.c (main) [cannot exec MINGW_GET_GUI]: Try
45         MINGW_GET_GFB instead.
46
47 2012-12-21  Keith Marshall  <keithmarshall@users.sourceforge.net>
48
49         Rename executive core file for GUI implementation.
50
51         * src/guixmld.cpp: File renamed...
52         * src/guiexec.cpp: ...to this; its function exceeds original intent.
53         * Makefile.in (GUIMAIN_OBJECTS): Update reference accordingly.
54
55 2012-12-20  Keith Marshall  <keithmarshall@users.sourceforge.net>
56
57         Create foundation for implementation of package category tree view.
58
59         * Makefile.in (GUIMAIN_OBJECTS): Add pkgtree.$OBJEXT reference to...
60         * src/pkgtree.cpp: ...incorporate this new file; it implements...
61         (AppWindowMaker::InitPackageTreeView): ...this new class method...
62         (pkgInitCategoryTreeGraft): ...and this new extern "C" function.
63
64         * src/guimain.h (pkgInitCategoryTreeGraft): Declare prototype.
65         (AppWindowMaker::InitPackageTreeView): New private method; declare it.
66         (AppWindowMaker::PackageTreeView): New member variable; declare it.
67
68         * src/guixmld.cpp (AppWindowMaker::LoadPackageData): Call
69         pkgInitCategoryTreeGraft(), after loading profile.xml
70         (AppWindowMaker::Invoked): Call InitPackageTreeView()
71
72         * src/pkgview.cpp (AppWindowMaker::LayoutEngine):
73         [ID_PACKAGE_TREEVIEW]: Handle it.
74
75 2012-12-19  Keith Marshall  <keithmarshall@users.sourceforge.net>
76
77         Make the "Apply Changes" dialogue "failure-aware".
78
79         * src/pkgtask.h (ACTION_APPLY_FAILED): Redefine, in terms of...
80         (ACTION_INSTALL_FAILED, ACTION_REMOVE_FAILED): New manifest defines.
81         (ACTION_UNSUCCESSFUL): New manifest constant; define it.
82
83         * src/pkgdata.cpp (pkgActionItem::EnumeratePendingActions):
84         [ACTION_UNSUCCESSFUL]: Make it a special case for enumeration.
85
86         * src/guixmld.cpp (pkgApplyChanges): Enumerate...
87         [ACTION_UNSUCCESSFUL > 0]: ...all such cases; when true...
88         [IDD_AUTO_CLOSE_OPTION]: ...this; select alternative close-out
89         messages, as appropriate.
90         (pkgActionItem::Assert): Factor out; relocate to...
91         * src/pkgexec.cpp (pkgActionItem::Assert): ...here; this moves its
92         object code into the mingw-get DLL.
93
94         * src/pkgunst.cpp (pkgRemove) [ACTION_REMOVE_FAILED]:
95         * src/pkginst.cpp (pkgInstall) [ACTION_INSTALL_FAILED]:
96         Assert as appropriate.
97
98 2012-12-19  Keith Marshall  <keithmarshall@users.sourceforge.net>
99
100         Improve progress reporting in "Apply Changes" dialogue.
101
102         * src/pkgstat.h: New header file; it declares...
103         (pkgSpinWait): ...this new pure abstract base class; it specifies an
104         infrastructure for posting arbitrary text to dialogue controls.
105
106         * src/pkgexec.cpp (pkgSpinWait): Implement its static elements.
107         (pkgActionItem::Execute): Dispatch progress reports, handled by...
108         (pkgSpinWait::Report, pkgSpinWait::Indicator): ...these.
109
110         * src/guixmld.cpp (pkgDialogueSpinWait): New class; declare it and
111         implement locally.  It is derived from, and provides a listener for...
112         (pkgSpinWait): ...this abstract class.
113         (pkgApplyChanges): Use it.
114
115         * src/tarproc.cpp (pkgTarArchiveInstaller::ProcessDataStream): Call...
116         (pkgSpinWait::Report): ...this, to report extracted files.
117
118         * src/pkgunst.cpp (pkg_unst): Call...
119         (pkgSpinWait::Report): ...this, to report deleted files.
120
121         * src/sysroot.cpp (pkgXmlDocument::UpdateSystemMap): Call...
122         (pkgSpinWait::Report, pkgSpinWait::Indicator): ...these, to confirm
123         continuing database update activity.
124
125 2012-12-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
126
127         Update tab display on right-click in package list view.
128
129         * src/pkgdata.cpp (AppWindowMaker::OnNotify) [NM_RCLICK]:
130         Call DataSheetMaker::DisplayData(), before invoking pop-up menu.
131
132 2012-12-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
133
134         Add more protection against NULL pointer abuse.
135
136         * src/pkgbase.h (pkgActionItem::Reset): Method renamed to...
137         * src/guixmld.cpp (pkgActionItem::Assert): ...this; also renamed here.
138         (AppWindowMaker::OnCommand): When calling...
139         (pkgListViewMaker::MarkScheduledActions): ...this, pass argument as...
140         (pkgXmlDocument::ClearScheduledActions): ...pointer returned by this.
141
142         * src/pkgdata.cpp (AppWindowMaker::MarkSchedule):
143         [pending_actions == NULL]: Do not propagate invocation request to...
144         (pkgListViewMaker::MarkScheduledActions): ...this.
145
146         * src/pkglist.cpp (pkgListViewMaker::MarkScheduledActions):
147         [schedule == NULL]: Do nothing.
148
149 2012-12-14  Keith Marshall  <keithmarshall@users.sourceforge.net>
150
151         Implement some additional permanent debugging support.
152
153         * src/pkgdeps.cpp (pkgXmlDocument::ResolveDependencies):
154         [DEBUG_TRACE_DEPENDENCIES]: Enable DMH digest mode for messages.
155
156         * src/tarproc.cpp (pkgTarArchiveInstaller::ProcessDataStream):
157         [DEBUG_TRACE_TRANSACTIONS]: Add logging of installed file path names.
158
159 2012-12-14  Keith Marshall  <keithmarshall@users.sourceforge.net>
160
161         Insert a missing snprintf format effector.
162
163         * src/pkgnget.cpp (pkgDownloadMeterGUI::Update): Add omitted '%'
164         format specifier, in "%%", for formatting percentage-complete value.
165         Rename "size_buf" automatic variable as "buf"; this results in shorter
166         source lines, and consequently a tidier source code layout.
167         (pkgDownloadMeterGUI::ResetGUI): Likewise s/size_buf/buf/
168
169 2012-12-14  Keith Marshall  <keithmarshall@users.sourceforge.net>
170
171         Add a missing header reference.
172
173         * src/approot.h: Include stdint.h; this ensures that wchar_t is
174         properly typedef'd, before attempting to use it.
175
176 2012-12-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
177
178         Make a clone of the package menu available as a pop-up.
179
180         * src/guimain.h (AppWindowMaker::SelectPackageAction): New private
181         method; declare it.
182
183         * src/pkgdata.cpp (AppWindowMaker::SelectPackageAction): Implement it.
184         (AppWindowMaker::OnNotify) [ID_PACKAGE_LISTVIEW]: Use it.
185
186 2012-12-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
187
188         Improve conditionally enabled state manipulation for menu items.
189
190         * src/guidata.rc (IDM_REPO_APPLY): Set its initial state as GRAYED.
191
192         * src/pkgdata.cpp (AppWindowMaker::UpdatePackageMenuBindings):
193         [IDM_PACKAGE_REINSTALL]: Always leave it GRAYED; this is a temporary
194         provision, until the GUI is updated to support "reinstall" capability.
195         [IDM_REPO_APPLY && !(EnumeratePendingActions > 0)]: Make it GRAYED.
196         [IDM_REPO_APPLY && (EnumeratePendingActions > 0)]: Enable it.
197
198 2012-12-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
199
200         Implement GUI bindings for processing a schedule of actions.
201
202         * src/guimain.h (IDD_DMH_CONSOLE): New resource ID; define it.
203         (IDD_APPLY_EXECUTE): New dialogue template resource ID; define it.
204         (AppWindowMaker::ExecuteScheduledActions): New method; declare it.
205
206         * src/guidata.rc (IDD_APPLY_EXECUTE): Implement dialogue template.
207
208         * src/guixmld.cpp (pkgApplyChanges): New thread function; implement it.
209         (AppWindowMaker::OnCommand) [IDD_REPO_APPLY]: Use it; it is invoked...
210         (IDD_APPLY_EXECUTE): ...via this dialogue box, subsequently calling...
211         (AppWindowMaker::ExecuteScheduledActions): ...this; implement it.
212
213         * src/pkgexec.cpp (pkgActionItem::Execute): Add argument; use it.
214         (pkgActionItem::~pkgActionItem): Unlink chained references.
215
216         * src/pkgbase.h (pkgActionItem::Execute): Adjust prototype.
217
218 2012-12-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
219
220         Do not preserve unnecessary download requests.
221
222         * src/pkginet.cpp (pkgActionItem::DownloadArchiveFiles):
223         [(flags & ACTION_INSTALL) != ACTION_INSTALL]: Actions having no
224         "install" effect do not require a download; cancel any associated
225         download request.
226
227 2012-12-10  Keith Marshall  <keithmarshall@users.sourceforge.net>
228
229         Implement GUI bindings for package download agent.
230
231         * src/guimain.h (IDD_PROGRESS_VAL, IDD_PROGRESS_MAX):
232         (IDD_PROGRESS_PCT): New manifest resource IDs; define them.  They will
233         be used to identify dialogue controls, to be associated with...
234         (IDD_APPLY_DOWNLOAD): ...this new dialogue template ID; define it.
235         (AppWindowMaker::DownloadArchiveFiles): New inline method; declare it.
236
237         * src/guidata.rc (IDD_APPLY_DOWNLOAD): Implement dialogue template.
238
239         * src/pkgbase.h (pkgActionItem::DownloadArchiveFiles): New public
240         inline method; declare it.  It overloads an existing private method of
241         the same name, which it subsequently invokes.
242
243         * src/pkginet.h: New header file; it declares...
244         (pkgInvokeDownload): ...this new extern "C" function prototype, and...
245         (pkgDownloadMeter): ...this abstract class; it is factored from its
246         original implementation in pkginet.cpp, augmented by addition of...
247         (pkgDownloadMeter::primary): New static member variable; declare it.
248         (pkgDownloadMeter::UseGUI): New public method; implement it inline.
249         (pkgDownloadMeter::ResetGUI): New public method; declare it, providing
250         a do-nothing inline default implementation.  Any derived class, which
251         supports GUI capability, should override this.
252
253         * src/pkgnget.cpp: New file; it implements...
254         (pkgDownloadMeterGUI): New class, derived from pkgDownloadMeter.
255         (pkgActionItem::DownloadArchiveFiles): New overloaded inline method.
256         (AppWindowMaker::DownloadArchiveFiles): New inline method.
257         (pkgInvokeDownload): New dialogue box worker thread handler.
258
259         * src/pkginet.cpp: Include pkginet.h; hence...
260         (pkgDownloadMeter): ...remove redundant class declaration.
261         (pkgDownloadMeter::primary): Define and initialise it.
262         (pkgInternetStreamingAgent::Get) [pkgDownloadMeter::UseGUI]: Delegate
263         progress metering to referenced pkgDownloadMeterGUI class instance.
264         [! pkgDownloadMeter::UseGUI]: Continue to use the existing built-in
265         pkgDownloadMeterTTY mechanism.
266         (pkgActionItem::DownloadSingleArchive) [ACTION_DOWLOAD_FAILED]: Assert
267         this initially; subsequently clear it on successful completion.
268         (pkgActionItem::DownloadArchiveFiles): Collect diagnostic messages
269         into a single DMH_BEGIN_DIGEST ... DMH_END_DIGEST group.
270
271         * src/guixmld.cpp: Include pkginet.h; it is required by...
272         (AppWindowMaker::OnCommand) [IDD_REPO_APPLY]: Use pkgInvokeDownload.
273
274         * Makefile.in (GUIMAIN_OBJECTS): Include pkgnget.$OBJEXT
275
276 2012-12-08  Keith Marshall  <keithmarshall@users.sourceforge.net>
277
278         Implement "Discard" handler for GUI "Apply Changes" dialogue.
279
280         * src/pkgbase.h (pkgActionItem::Reset): New public method; declare it.
281         (pkgActionItem::Clear): New public method; declare two overloaded
282         variants, of which implement one inline.
283         (pkgXmlDocument::ClearScheduledActions): New public method; declare
284         and implement it inline.
285
286         * src/pkgtask.h (ACTION_DOWNLOAD_FAILED, ACTION_APPLY_FAILED): New
287         manifest bit-flag constants; define them.  They provide a mechanism
288         for blocking the discard event in respect of failed actions.
289
290         * src/guixmld.cpp (pkgActionItem::Reset): Implement it.
291         (pkgActionItem::Clear): Implement second, out-of-line variant.
292         (ACTION_PRESERVE_FAILED): New local manifest bit-flag constant; define
293         it as an aggregate of ACTION_DOWNLOAD_FAILED and ACTION_APPLY_FAILED.
294         (AppWindowMaker::OnCommand) [IDD_REPO_APPLY]: Use them.
295
296 2012-12-07  Keith Marshall  <keithmarshall@users.sourceforge.net>
297
298         Implement GUI dialogue for "Apply Changes" action approval.
299
300         * src/guidata.rc (ID_MAIN_WINDOW_MENU): Rename...
301         ("&Repository"): ...this drop-down menu entry...
302         ("&Installation"): ...this; add...
303         ("&Apply Changes"): ...this new selection.
304         (IDD_APPLY_APPROVE): New dialogue box resource template; define it.
305         (SS_CTEXTBOX): New aggregate style convenience macro; define it.
306         (ES_VT100): Likewise.
307
308         * src/guimain.h (IDM_REPO_APPLY): New resource ID; define it.
309         (IDM_REPO_QUIT): Redefined resource ID; was 302; changed to 312.
310         (IDD_APPLY_APPROVE, IDD_PROGRESS_TXT): New resource IDs; define them.
311         (IDD_APPLY_REMOVES_PACKAGES, IDD_APPLY_REMOVES_SUMMARY): Likewise.
312         (IDD_APPLY_INSTALLS_PACKAGES, IDD_APPLY_INSTALLS_SUMMARY): Likewise.
313         (IDD_APPLY_UPGRADES_PACKAGES, IDD_APPLY_UPGRADES_SUMMARY): Likewise.
314         (ID_APPLY, ID_DISCARD, ID_DEFER): New response IDs; define them.
315         (AppWindowMaker::EnumerateActions): New inline method; declare it.
316         (AppWindowMaker::DialogueResponse): New inline method; declare and
317         implement it.
318
319         * src/guixmld.cpp (pkglist.h): #included.
320         (dmh_setpty): Add locally declared prototype.
321         (AppWindowMaker::EnumerateActions): Implement it.
322         (pkgActionCount): New static helper function; implement it.
323         (ACTION_APPLY, APPLIES_TO): New macros; define them.
324         (FMT_APPLY_REMOVES, FMT_APPLY_INSTALLS, FMT_APPLY_UPGRADES): New
325         manifest string constants; define them.
326         (pkgApplyApproved): New static call-back function; implement...
327         (AppWindowMaker::OnCommand) [IDM_REPO_APPLY]: ...and use it.
328
329 2012-12-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
330
331         Implement enhanced action item enumeration capability.
332
333         * src/pkgbase.h (pkgActionItem::EnumeratePendingActions): New public
334         method; declare it.  It provides the capability to enumerate scheduled
335         actions, filtered by action classification; when invoked such that it
336         selects all actions, it may be used as a replacement for...
337         (pkgActionItem::Unapplied): ...this; delete declaration.
338
339         * src/pkgdata.cpp (pkgActionItem::EnumeratePendingActions): Implement
340         it; it is derived, with enhancement, from original implementation...
341         (pkgActionItem::Unapplied): ...of this; delete it, and...
342         (AppWindowMaker::OnClose): ...update calling reference accordingly.
343
344 2012-12-05  Keith Marshall  <keithmarshall@users.sourceforge.net>
345
346         Implement PTY display emulation for GUI mode DMH.
347
348         * src/dmhcore.h (dmhTypeGeneric::set_console_hook): New public virtual
349         method; declare it, providing inline default do-nothing implementation.
350         (dmhTypeGeneric::severity_tag): New protected static method; declare it.
351         (dmhTypeGeneric::notification_format): New protected static property;
352         declare it.
353
354         * src/dmh.cpp (dmhTypeGeneric::severity_tag): Implement it.
355         (dmhTypeGeneric::notification_format): Define and initialise it.
356         (dmhTypeTTY::notify): Use them.
357         (dmh_setpty): New function; declare prototype and implement it.
358
359         * src/guidmh.cpp (dmhTypePTY): New locally implemented class.
360         (dmhTypeGUI::set_console_hook): New virtual method; declare and
361         implement it; it stores a dmhTypePTY reference pointer into...
362         (dmhTypeGUI::console_hook): ...this new private member variable.
363         (dmhTypeGUI::dmhTypeGUI): Initialise it.
364         (dmhTypeGUI::notify) [console_hook != NULL]: Delegate to it.
365         (dmhTypeGUI::printf) [console_hook != NULL]: Likewise.
366
367 2012-12-03  Keith Marshall  <keithmarshall@users.sourceforge.net>
368
369         Implement generalised API for dialogue boxes with worker threads.
370
371         * src/guimain.h (pkgDialogueThread): New typedef; declare it.
372         (AppWindowMaker::DialogueThread): New static property; declare it.
373         (AppWindowMaker::DispatchDialogueThread): New method; declare it.
374
375         * src/guixmld.cpp: Formatting of several comments adjusted.
376         (pkgUpdate, pkgInitDataLoad): Defunct functions; replaced by...
377         (pkgDialogue): ...this new static call-back function; implement it.
378         (AppWindowMaker::DialogueThread): Instantiate and initialise it.
379         (AppWindowMaker::DispatchDialogueThread): Implement it.
380         (AppWindowMaker::Invoked): Use it to invoke pkgInvokeInitDataLoad()...
381         (AppWindowMaker::OnCommand): ...and pkgInvokeUpdate().
382
383 2012-12-03  Keith Marshall  <keithmarshall@users.sourceforge.net>
384
385         Consolidate GUI implementation for package list view management.
386
387         * src/pkglist.h (pkgListViewMaker::GetTitle): Disused overloaded
388         method; remove all declarations.
389         (pkgListViewMaker::GetVersionString): Disused method; remove
390         declaration.
391         (pkgListViewMaker::GetItem): New private inline method; declare it.
392         (pkgListViewMaker::UpdateItem): New private method; declare it.
393         (pkgListViewMaker::UpdateListView): New public method; declare it.
394         (pkgListViewMaker::MarkScheduledActions): Likewise.
395
396         * src/guimain.h (AppWindowMaker::MarkSchedule): New public inline
397         method; declare it, but defer implementation to...
398
399         * src/pkgdata.cpp (AppWindowMaker::MarkSchedule): ...here; not used
400         elsewhere, it is derived from, and replaces...
401         (pkgMarkSchedule): ...this function; factor out redundant code, in
402         favour of delegation to pkgListViewMaker::MarkScheduledActions(), with
403         following call to AppWindowMaker::UpdatePackageMenuBindings(); update
404         calling function references...
405         (AppWindowMaker::UnmarkSelectedPackage): ...here, and...
406         (AppWindowMaker::Schedule): ...here.
407
408         * src/pkglist.cpp (pkgVersionString): New static function; implement
409         it as a local replacement for...
410         (pkgListViewMaker::GetVersionString): ...this defunct class method.
411         (pkgGetTitle): New overloaded static function; implement two variants,
412         as local replacements for...
413         (pkgListViewMaker::GetTitle): ...this defunct overloaded class method.
414         (pkgListViewMaker::UpdateItem): Implement it; factor code from...
415         (pkgListViewMaker::InsertItem): ...here, whence use it.
416         (pkgListViewMaker::MarkScheduledActions): Implement it.
417         (pkgListViewMaker::UpdateListView): Implement it.
418         (pkgListViewMaker::pkgListViewMaker): Remove references to...
419         (LVIF_TEXT): ...this.
420
421 2012-11-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
422
423         Increase width of window sash bars by 50%.
424
425         * src/guimain.h (SASH_BAR_THICKNESS): Increase from 4 to 6; this makes
426         it easier to grab the sash bars, so they may be dragged; IMO, it also
427         results in a better appearance.
428
429 2012-11-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
430
431         Maintain consistent internal vs. external installation records.
432
433         * src/pkginst.cpp (pkgInstall): Set "installed" attribute on internal
434         package reference, to "yes", after installation; CLI didn't need this,
435         but GUI will do so, for any package revisited in a single session.
436
437         * src/pkgunst.cpp (pkgRemove): Similarly, negate "installed" attribute
438         after package removal.
439
440 2012-11-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
441
442         Refactor to consolidate three instances of duplicate code.
443
444         * src/pkglist.h (pkgGetStatus): New function; declare it.
445         * src/pkglist.cpp (pkgGetStatus): Implement it; factor out from...
446         (pkgListViewMaker::InsertItem): ...here, whence use it.
447         * src/pkgdata.cpp (pkgMarkSchedule): Likewise here...
448         (DataSheetMaker::DisplayGeneralData): ...and here.
449
450 2012-11-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
451
452         Add GUI support for install, upgrade, and remove action scheduling.
453
454         * src/guimain.h (EXTERN_C): Ensure it is defined.
455         (pkgActionItem): Add forward declaration of class name.
456         (pkgMarkSchedule): New EXTERN_C function; declare and prototype it.
457         (AppWindowMaker::OnClose): New virtual method; declare it.
458         (AppWindowMaker::Schedule): New public method; declare it.
459         (AppWindowMaker::UnmarkSelectedPackage): Likewise.
460
461         * src/pkgbase.h (pkgActionItem::HasAttribute) [this == NULL]: Add
462         protective logic; ignore attempts to access non-existent objects.
463         (pkgActionItem::SelectPackage) [this == NULL]: Likewise.
464         (pkgActionItem::Selection) [this == NULL]: Likewise.
465         (pkgActionItem::GetReference): New overloaded public method; declare
466         prototype variant with argument type of pkgXmlNode*.
467         (pkgActionItem::Unapplied): New public method; declare it.
468         (pkgActionItem::CancelScheduledAction): Likewise.
469         (pkgXmlDocument::Schedule): Change return type from void to
470         pkgActionItem*; add default argument values.
471
472         * src/guixmld.cpp (AppWindowMaker::OnCommand): Add menu case hooks...
473         [IDM_PACKAGE_INSTALL]: ...to schedule package 'install' action...
474         [IDM_PACKAGE_UPGRADE]: ...package 'upgrade' action...
475         [IDM_PACKAGE_REMOVE]: ...package 'remove' action, or...
476         [IDM_PACKAGE_UNMARK]: ...to cancel any of these scheduling requests.
477         [IDM_REPO_QUIT]: Correct typo; s/WM_QUIT/WM_CLOSE/ in comment.
478
479         * src/pkgdata.cpp (pkgMarkSchedule): Implement it.
480         (pkgActionItem::CancelScheduledAction): Implement it.
481         (pkgActionItem::Unapplied): Implement it.
482         (AppWindowMaker::UpdatePackageMenuBindings): Improve comments.
483         (AppWindowMaker::UnmarkSelectedPackage): Implement it.
484         (AppWindowMaker::Schedule): Implement it.
485         (AppWindowMaker::OnClose): Implement it.
486
487         * src/pkgdeps.cpp (pkgActionItem::GetReference): Implement overload.
488         (pkgXmlDocument::Schedule): Change return type, and return value.
489         [this == NULL]: Add protective logic; ignore non-existent objects.
490         [name == NULL]: Do not schedule; just return existing action list.
491
492 2012-11-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
493
494         Add dynamically enabled state control for package menu items.
495
496         * src/guimain.h (AppWindowMaker::UpdatePackageMenuBindings): New
497         private method; declare it.
498
499         * src/pkgdata.cpp (AppWindowMaker::UpdatePackageMenuBindings):
500         Implement it, and...
501         (AppWindowMaker::OnNotify): ...use it.
502
503 2012-11-01  Keith Marshall  <keithmarshall@users.sourceforge.net>
504
505         Avoid excessive inter-word spaces in adjusted text.
506
507         * src/pkgdata.cpp (pkgTroffLayoutEngine::WriteLn): Check extent of
508         padding to be added at each inter-word space, when adjusting text; do
509         not adjust, if it exceeds 5% of available display pane width.
510
511 2012-11-01  Keith Marshall  <keithmarshall@users.sourceforge.net>
512
513         Elide unbreakable text which will not fit within display width.
514
515         * src/pkgdata.cpp (pkgTroffLayoutEngine::WriteLn): Add logic to detect
516         over-width unbreakable text; elide characters from the right, to make
517         it fit within the display width, with trailing ellipsis.
518
519 2012-11-01  Keith Marshall  <keithmarshall@users.sourceforge.net>
520
521         Add content compiler for package data sheet "general" tab.
522
523         * src/pkgbase.h (pkgActionItem::PrintURI): Make it public.  Add a
524         call-back reference argument, for output function; assign puts() as
525         default, where previously had hard coded printf() emulating puts()
526
527         * src/pkginet.cpp (pkgActionItem::PrintURI): Use call-back hook.
528
529         * src/pkgdata.cpp (DataSheetMaker::Display): New static property; it
530         stores a reference to the active class instance, so static call-back
531         methods may delegate processing requests to non-static methods.
532         (DataSheetMaker::Advance): New static property; it is used to instruct
533         call-back methods to interpose paragraph leading it the output stream.
534         (DataSheetMaker::FormatRecord): New private method; implement it.
535         (DataSheetMaker::FormatText): Don't pass "canvas" as an argument; we
536         can access it directly as a class property.  Update all callers as
537         necessary, to conform to modified function prototype.
538         (pkgListSelection): New static function; implement it, and...
539         (DataSheetMaker::OnPaint): ...use it in switch cases, when calling...
540         [PKG_DATASHEET_GENERAL]: DataSheetMaker::DisplayGeneralData(), and...
541         [PKG_DATASHEET_DESCRIPTION]: DataSheetMaker::DisplayDescription().
542         (DataSheetMaker::DisplayGeneralData): New public method; implement it.
543         (DataSheetMaker::DisplayPackageURL): New static method; implement it.
544         (DataSheetMaker::DisplayLicenceURL): Likewise.
545         (DataSheetMaker::DisplaySourceURL): Likewise.
546
547 2012-10-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
548
549         Fix error in counting of catalogue files during loading.
550
551         * src/pkgbind.cpp (pkgRepository::GetPackageList): Increment count
552         variable once only, at start of each cycle of the catalogue loading
553         loop; previous strategy of counting in discrete logic paths could
554         miss several required increments, particularly in CLI mode.
555
556 2012-10-27  Keith Marshall  <keithmarshall@users.sourceforge.net>
557
558         Avoid DMH message digest fragmentation when downloading.
559
560         * src/dmh.h (DMH_GET_CONTROL_STATE): New macro; define it.
561         * src/pkginet.cpp (pkgInternetAgent::OpenURL): Use it; do not close
562         locally opened message digest, when called with one already open.
563
564 2012-10-27  Keith Marshall  <keithmarshall@users.sourceforge.net>
565
566         Initiate progress metering for catalogue load and update operations.
567
568         * src/guidata.rc (IDD_REPO_UPDATE): New dialogue template; define it.
569         (IDM_REPO_UPDATE): Enable selection from "Repository" drop-down menu.
570
571         * src/guimain.h (IDD_REPO_UPDATE, IDD_CLOSE_OPTIONS):
572         (IDD_AUTO_CLOSE_OPTION, IDD_PROGRESS_BAR, IDD_PROGRESS_MSG): New
573         resource identification manifest constants; define them.
574         (pkgXmlNode, pkgProgressMeter): Add forward class declarations.
575         (AppWindowMaker::AttachedProgressMeter): New private data; define...
576         (AppWindowMaker::AppWindowMaker): ...and initialise it.
577         (AppWindowMaker::AttachProgressMeter): New public method; declare it.
578         (AppWindowMaker::DetachProgressMeter): Likewise.
579         (AppWindowMaker::LoadPackageData, AppWindowMaker::ClearPackageList):
580         (AppWindowMaker::UpdatePackageList): Make them public.
581
582         * src/pkgbase.h (pkgProgressMeter): New abstract class; declare it.
583         (AppWindowMaker) [GUIMAIN_H undefined]: Add forward class declaration.
584         (pkgXmlDocument::progress_meter): New private data member; declare...
585         (pkgXmlDocument::pkgXmlDocument): ...and initialise it.
586         (pkgXmlDocument::ProgressMeter, pkgXmlDocument::AttachProgressMeter):
587         (pkgXmlDocument::DetachProgressMeter): New public inline methods;
588         implement them.
589
590         * src/pkgview.cpp (WTK::GenericDialogue): Delete disused reference.
591         (AppWindowMaker::OnCommand): Factor out implementation; relocate it...
592         * src/guixmld.cpp: ...to here; thus it may utilise dependants of...
593         (ProgressMeterMaker): ...this new locally implemented class.
594         (AppWindowMaker::AttachProgressMeter): Implement it.
595         (AppWindowMaker::AttachProgressMeter): Likewise.
596         (pkgProgressMeter::~pkgProgressMeter): Likewise.
597         (pkgUpdate, pkgInvokeUpdate): New static functions; implement them.
598         (AppWindowMaker::Invoked): Replace direct call to LoadPackageData by
599         an indirect invocation, via a progress metering dialogue box using...
600         (pkgInitDataLoad): ...this new static callback function, invoking...
601         (pkgInvokeInitDataLoad): ...this new static thread function, whence...
602         (AppWindowMaker::LoadPackageData): ...this; add hook-up call to...
603         (pkgXmlDocument::AttachProgressMeter): ...incorporate this.
604
605         * src/pkgbind.cpp (pkgRepository::total, pkgRepository::count): New
606         private static properties; declare and instantiate them; provide...
607         (pkgRepository::Reset, pkgRepository::IncrementTotal): ...new public
608         static methods to manipulate them; declare and implement them inline.
609         (pkgRepository::GetPackageList): Use them to manage updates to the
610         pkgProgressMeter class instance, if any, which has been bound to
611         the controlling pkgXmlDocument class instance, when invoking...
612         (pkgXmlXmlDocument::BindRepositories): ...this.
613
614 2012-10-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
615
616         Associate DMH message boxes with active dialogues.
617
618         * src/guidmh.cpp (last_active_popup): New static inline function.
619         (dmhTypeGUI::dispatch_message): Use it.
620
621 2012-10-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
622
623         Fix Diagnostic Message Handler initialisation logic.
624
625         * src/dmh.cpp (dmh_init) [DMH_SUBSYSTEM_GUI]: Correct a logic error;
626         it previously fell through after any successful initialisation of the
627         DMH_SUBSYSTEM_GUI handler, replacing it with a DMH_SUBSYSTEM_TTY type
628         handler.  Also, assign a heap copy of the passed "progname" string
629         resource, which is volatile, to ensure that the handler retains a
630         valid reference.
631
632 2012-10-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
633
634         Implement preliminary GUI mode data sheet compiler.
635
636         * src/guimain.h (DataSheetMaker): New class; forward declare it.
637         (AppWindowMaker::InitPackageTabControl): New private method; declare it.
638         (AppWindowMaker::DataSheet, AppWindowMaker::PackageTabControl):
639         (AppWindowMaker::TabDataPane, AppWindowMaker::PackageTabPane): New
640         private data members; declare them.
641         (ID_SASH_WINDOW_PANE_CLASS): New string resource identifier; define it.
642         (ID_PACKAGE_DATASHEET, ID_PACKAGE_TABPANE): New window identifiers;
643         define them.
644
645         * src/guidata.rc (ID_SASH_WINDOW_PANE_CLASS): Specify string resource.
646
647         * src/pkgview.cpp (AppWindowMaker::OnSize): Add handler for...
648         (ID_PACKAGE_TABPANE, ID_PACKAGE_TABCONTROL, ID_PACKAGE_DATASHHET):
649         ...this group of sash pane child window entities.
650         (AppWindowMaker::OnNotify): Comment out disused stub implementation.
651
652         * src/pkgshow.cpp (pkgUTF8Parser): Factor out class declaration...
653         (UTF32_MAX, UTF32_OVERFLOW, UTF32_INVALID): ...these definitions...
654         (utf32_t): ...and this typedef; relocate to, and #include...
655         * src/pkgdata.h: ...this new header file.
656
657         * src/pkgdata.cpp (DataSheetMaker): New class; declare and implement it.
658         (AppWindowMaker::InitPackageTabControl): Implement it.
659         (AppWindowMaker::OnNotify): Reimplement it.
660
661         * Makefile.in (GUIMAIN_OBJECTS): Add pkgdata.OBJEXT
662
663         * src/guixmld.cpp (AppWindowMaker::Invoked): Add call to invoke
664         AppWindowMaker::InitPackageTabControl()
665
666 2012-10-09  Keith Marshall  <keithmarshall@users.sourceforge.net>
667
668         Remove a grossly heuristic list view hack.
669
670         * src/pkglist.cpp (pkgListViewMaker::GetTitle): Remove code for the
671         heuristic deletion of any redundant package name prefixes from package
672         title attributes; by now, all such prefixes should have been removed
673         from the catalogue, explicitly, at source.
674
675 2012-10-08  Keith Marshall  <keithmarshall@users.sourceforge.net>
676
677         Implement GUI list view compiler for XML catalogue.
678
679         * src/pkgview.cpp (AppWindowMaker::LayoutEngine): Add case handler...
680         [pane_id == ID_PACKAGE_LISTVIEW]: ...for this window pane class.
681
682         * src/guimain.h (ID_PKGLIST_TABLE_HEADINGS):
683         (ID_PKGNAME_COLUMN_HEADING, ID_PKGTYPE_COLUMN_HEADING):
684         (ID_INSTVER_COLUMN_HEADING, ID_REPOVER_COLUMN_HEADING):
685         (ID_PKGDESC_COLUMN_HEADING): New resource identifiers; define them.
686         (ID_PKGSTATE_AVAILABLE, ID_PKGSTATE_AVAILABLE_NEW):
687         (ID_PKGSTATE_AVAILABLE_LOCKED, ID_PKGSTATE_AVAILABLE_INSTALL):
688         (ID_PKGSTATE_INSTALLED_CURRENT, ID_PKGSTATE_INSTALLED_LOCKED):
689         (ID_PKGSTATE_INSTALLED_OLD, ID_PKGSTATE_UPGRADE, ID_PKGSTATE_REMOVE):
690         (ID_PKGSTATE_REINSTALL, ID_PKGSTATE_DOWNGRADE, ID_PKGSTATE_BROKEN):
691         (ID_PKGSTATE_PURGE): New icon resource identifiers; define them.
692         (AppWindowMaker::InitPackageListView): New private method; declare it.
693         (AppWindowMaker::UpdatePackageList): New private method; declare it.
694         (AppWindowMaker::ClearPackageList): New private method; declare and
695         implement it inline.
696
697         * src/guidata.rc (ID_PKGSTATE_AVAILABLE, ID_PKGSTATE_AVAILABLE_NEW):
698         (ID_PKGSTATE_AVAILABLE_LOCKED, ID_PKGSTATE_AVAILABLE_INSTALL):
699         (ID_PKGSTATE_INSTALLED_CURRENT, ID_PKGSTATE_INSTALLED_LOCKED):
700         (ID_PKGSTATE_INSTALLED_OLD, ID_PKGSTATE_UPGRADE, ID_PKGSTATE_REMOVE):
701         (ID_PKGSTATE_REINSTALL, ID_PKGSTATE_DOWNGRADE, ID_PKGSTATE_BROKEN):
702         (ID_PKGSTATE_PURGE): New icon resources; implement them.
703
704         * icons/state01.ico icons/state02.ico icons/state03.ico:
705         * icons/state04.ico icons/state05.ico icons/state06.ico:
706         * icons/state07.ico icons/state08.ico icons/state09.ico:
707         * icons/state10.ico icons/state11.ico icons/state12.ico:
708         * icons/state13.ico: New files.  All are cloned from synaptic icons;
709         see src/guimain.rc for symbolic/functional reference names.
710
711         * src/pkglist.h [GUIMAIN_H defined] (pkgListViewMaker): New class;
712         declare it for use in modules which #include guimain.h
713
714         * src/pkglist.cpp: New file; it implements...
715         (pkgListViewMaker): ...this new class, and its clients...
716         (AppWindowMaker::InitPackageListView): New method.
717         (AppWindowMaker::UpdatePackageList): Likewise.
718
719         * Makefile.in (GUIMAIN_OBJECTS): Add pkglist.OBJEXT
720
721         * src/guixmld.cpp (AppWindowMaker::Invoke): Call InitCommonControls(),
722         as prerequisite to AppWindowMaker::InitPackageListView(); follow up by
723         calling AppWindowMaker::AdjustLayout().
724
725 2012-10-07  Keith Marshall  <keithmarshall@users.sourceforge.net>
726
727         Add GUI initialiser hook for XML catalogue interface.
728
729         * src/guimain.h (AppWindowMaker::Invoke): New public method; declare
730         it; it overrides the generic WTK::MainWindowMaker::Invoke() method, so
731         providing the initialiser hook which will invoke this...
732         (AppWindowMaker::LoadPackageData): ...new private method; declare it.
733
734         * src/guixmld.cpp: New file.
735         (AppWindowMaker::Invoke): Implement it.
736         (AppWindowMaker::LoadPackageData): Likewise.
737
738         * Makefile.in (GUIMAIN_OBJECTS): Add guixmld.OBJEXT
739
740 2012-09-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
741
742         Add initial working GUI mode DMH class implementation.
743
744         * src/dmh.h (DMH_SEVERITY_MASK): New manifest constant; define it.
745         (DMH_DIGEST_MASK, DMH_COMPILE_DIGEST, DMH_DISPATCH_DIGEST): Likewise.
746         (DMH_BEGIN_DIGEST, DMH_END_DIGEST): Redefine in terms of above.
747
748         * src/dmhcore.h: New header file; it declares...
749         (dmhTypeGeneric): ...this abstract base class, factored from...
750
751         * src/dmh.cpp (dmhTypeGeneric): ...here, whence remove it; it is
752         still required, thus include dmhcore.h so that it remains visible.
753         (dmh_exception): Remove errant namespace qualifier from constructor.
754         (dmhTypeGUI): Delete class declaration and original constructor.
755         (dmh_init): Delete reference to dmhTypeGUI; replace by call to...
756         (dmh_init_gui): ...this new static function; it is a stub which
757         invokes a DLL import of the same name, to instantiate a dmhTypeGUI.
758         (dmhTypeGUI::control, dmhTypeGUI::notify, dmhTypeGUI::printf): Delete
759         original method stubs.
760
761         * src/guidmh.cpp: New file; it reimplements...
762         (dmhTypeGUI): ...this class; declare it and implement its constructor.
763         (dmh_init_gui): Provide its DLL exported implementation.
764         (dmhTypeGUI::dispatch_message): New private method; add it to the
765         class declaration and implement it; it is a helper method for...
766         (dmhTypeGUI::control, dmhTypeGUI::notify): ...these; implement them.
767         (dmhTypeGUI::printf): Provide a replacement stub.
768
769         * Makefile.in (GUIMAIN_OBJECTS): Add guidmh.OBJEXT
770
771         * src/guimain.h (AppWindowMaker::Create): New method; add it to the
772         class declaration; it overrides the default Create() method inherited
773         from WTK::MainWindowMaker
774
775         * src/pkgview.cpp (AppWindowMaker::Create): Implement it; it handles
776         window class registration and dmhTypeGUI initialisation, in addition
777         to the inherited CreateWindow() behaviour.
778
779         * src/guimain.cpp: Include dmh.h
780         (WinMain): Add catch block for dmh_exception.  Remove window class
781         registration request; it is now delegated to AppWindowMaker::Create()
782
783 2012-09-26  Keith Marshall  <keithmarshall@users.sourceforge.net>
784
785         Add .hgignore as tracked file.
786
787         * .hgignore: New file.
788
789 2012-09-25  Keith Marshall  <keithmarshall@users.sourceforge.net>
790
791         Defer generation of version.c until "make" time.
792
793         * version.c.in: Move it...
794         * src/version.c.in: ...to here.
795         (PACKAGE_NAME, PACKAGE_VERSION, COPYRIGHT_HOLDER, YEARS_OF_ISSUE):
796         Change substitution field marker character from "@" to "%".
797
798         * configure.ac (AC_CONFIG_FILES): Remove version.c
799
800         * Makefile.in (TAG_SCRIPT): New macro, factored out from...
801         (RC_SCRIPT): ...here, whence use it; also use it to implement...
802         (VERSION_SCRIPT): ...this further new macro; use it in...
803         (%.c): ...this generic template rule for version.c
804         (time-stamp, %.time, %.tagged.time, %.tag): New generic build
805         goals; use them to track package release progression via...
806         (build.tag): ...this new intermediate; make it a pre-requisite...
807         (guidata.OBJEXT, version.c): ...of these.
808
809 2012-09-21  Keith Marshall  <keithmarshall@users.sourceforge.net>
810
811         Implement framework for GUI sash window layout controller.
812
813         * configure.ac (AC_INIT): Bump version number to 0.6
814         (CLI_RELEASE_CLASS): New AC_SUBST variable; default to "beta".
815         (GUI_RELEASE_CLASS): New AC_SUBST variable; default to "alpha".
816         (SNAPSHOT_CLASS): Recognise as user specified environent variable
817         override for both CLI_RELEASE_CLASS and GUI_RELEASE_CLASS.
818         (RC): New AC_CHECK_TOOL substitution variable name; it replaces...
819         (WINDRES): ...this, as reference name for the resource compiler.
820         (MINGW_AC_ASSERT_MISSING): Add AC_CHECK_HEADER traps for missing
821         "lua-dev" and "wtklite-dev" support.
822
823         * Makefile.in (CLI_RELEASE_CLASS, GUI_RELEASE_CLASS): Use them.
824         (BUILD_TAG, RC_SCRIPT, RC_INCLUDES): New macros; define and use...
825         (RC): ...with this, to implement new target rule for compiling...
826         (%.rc): ...resource definition files to %.OBJEXT objects.
827         (GUIMAIN_OBJECTS, GUIMAIN_LIBS): New macros; define and use...
828         (guimain.EXEEXT): ...to implement build rule for this.
829         (LIBEXEC_PROGRAMS): Add guimain.EXEEXT
830         (lastrites.EXEEXT): Use GUI_LDFLAGS.
831         
832         * src/guimain.h src/guimain.cpp src/guidata.rc: New files.
833         * src/pkgview.cpp: New file.
834
835 2012-09-20  Keith Marshall  <keithmarshall@users.sourceforge.net>
836
837         Adjust incorrectly resolved 2012-09-14 merge from master.
838
839         * src/Makefile.in: Restore lost reference to guistub.cpp
840
841 2012-09-14  Keith Marshall  <keithmarshall@users.sourceforge.net>
842
843         Implement GUI hooks in "rites of passage" internal API.
844
845         * src/pkglock.h: New file; it adds the pkgLock() and pkgRelease()
846         inline wrapper functions, through which the GUI application acquires
847         and manages an exclusive access lock for the XML catalogue.
848
849         * src/rites.c (lockfile_name): Explicitly cast memory allocated for
850         the returned name to (char *), so this may be embedded in C++ code.
851         (pkgInitRites): Factor out lock acquisition failure diagnostics...
852         (pkgLockFail): ...to this inline helper function; conditionally...
853         [ifdef GUIMAIN_H]: ...provide one implementation for GUI use...
854         [ifndef GUIMAIN_H]: ...and an alternative for CLI use.
855
856 2012-09-14  Keith Marshall  <keithmarshall@users.sourceforge.net>
857
858         Be case agnostic when matching shortcut targets.
859
860         * scripts/libexec/unlink.js [ref.TargetPath == chklink]: Apply
861         toLowerCase() on both sides of the comparison.
862
863 2012-09-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
864
865         Note relocation of m4 when packaging source distribution.
866
867         * Makefile.in (SRCDIST_SUBDIRS): Refer to build-aux/m4, not m4.
868
869 2012-09-10  Keith Marshall  <keithmarshall@users.sourceforge.net>
870
871         Move guimain.cpp out of the way.
872
873         * src/guimain.cpp: Rename file as...
874         * src/guistub.cpp: ...this; we want to keep current features for now,
875         but to use the guimain.cpp name for main GUI application development.
876         * Makefile.in: Adjust references accordingly.
877
878 2012-09-09  Keith Marshall  <keithmarshall@users.sourceforge.net>
879
880         Fix typo, and update licensing terms for embedded getopt.c
881
882         * src/getopt.c: Incorporate MIT/X style licence; update copyright
883         notice, to reflect chronology of publication; correct degenerate RCS
884         keyword usage in EOF marker comment.
885
886 2012-09-03  Keith Marshall  <keithmarshall@users.sourceforge.net>
887
888         Correct omission from copyright notice.
889
890         * src/pkgkeys.c: Add year 2012, to reflect 2012-09-02 update.
891
892 2012-09-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
893
894         Redefine paragraph_key with project global scope.
895
896         * src/pkgkeys.h (paragraph_key): Declare it.
897         * src/pkgkeys.c (paragraph_key): Define it.
898
899         * src/pkgshow.cpp (pkgDirectoryViewer::EmitDescription): Delete
900         function local definition; use global definition instead.
901
902 2012-09-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
903
904         Correct defect introduced by 2012-08-03 commit.
905
906         * src/approot.c (AppPathNameW): Add omitted 'else', so that tail
907         pointer isn't moved after the APPROOT prefix is truncated.
908
909 2012-09-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
910
911         Remap Mercurial subrepository reference via local hg-git clone.
912
913         * .hgsub (build-aux): Point to ../build-aux; this must be a locally
914         hosted hg clone of the git origin repository, and it must pre-exist as
915         a sibling of any created hg clone of the mingw-get repository.
916
917         * .hgsubstate: New file, automatically generated by Mercurial.
918
919 2012-08-31  Keith Marshall  <keithmarshall@users.sourceforge.net>
920
921         Add Mercurial subrepository reference for build-aux.
922
923         * .hgsub: New file.
924
925 2012-08-03  Keith Marshall  <keithmarshall@users.sourceforge.net>
926
927         More code refactoring, to facilitate GUI implementation.
928
929         * src/clistub.c (AppPathNameW): Factor out; relocate to...
930         * src/approot.c: ...this new file; it reproduces the original
931         implementation, modified to also consider any "libexec" directory in
932         the executable path as the first child of the APPROOT prefix.  Note
933         also, that no longer terminates APPROOT with a trailing backslash.
934
935         * src/approot.h: New file; it trivially declares the prototype for...
936         (AppPathNameW): ...this relocated extern "C" function.
937
938         * src/clistub.c (main): Adapt usage of AppPathNameW(), to reinstate
939         trailing backslash on assignment to APPROOT environment variable.
940
941         * Makefile.in (CLI_EXE_OBJECTS): New macro; define it as the original
942         set of prerequisites, with the addition of approot.OBJEXT, for...
943         (mingw-get.EXEEXT): ...this; use it.
944
945         * src/rites.c: Add comment regarding APPROOT usage.
946
947 2012-08-02  Earnie Boyd  <earnie@users.sourceforge.net>
948
949         Find missing.m4 in build-aux/m4 directory.
950
951         * aclocal.m4: Change path  m4/missing.m4 to build-aux/m4/missing.m4.
952
953 2012-07-31  Earnie Boyd  <earnie@users.sourceforge.net>
954
955         Add build-aux as a submodule.
956         Move .cvsignore to .gitignore.
957
958         * .gitmodules: New file.
959         * build-aux: New submodule directory.
960         * .cvsignore: Remove.
961         * .gitignore: New file.
962
963 2012-07-13  Keith Marshall  <keithmarshall@users.sourceforge.net>
964
965         Disable globbing of command line arguments.
966
967         * src/clistub.c (_CRT_glob): Define and initialise to zero; we don't
968         need globbing, and it may cause case transliteration of case-sensitive
969         action keywords, when a file system entity with a case-insensitively
970         matching name exists.
971
972 2012-06-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
973
974         Refactor API to facilitate implementation of GUI ListView hooks.
975
976         * src/pkgkeys.h (title_key, description_key): Declare them.
977         * src/pkgkeys.c (title_key, description_key): Define them; relocate...
978         * src/pkgshow.cpp (pkgDirectoryViewer::EmitDescription): ...from here.
979         (pkgXmlDocument::CalalogueAllPackages): New public method; factor...
980         (pkgXmlDocument::DisplayPackageInfo): ...from here, whence use it.
981         (pkgDirectoryViewerEngine::EnumerateComponents): New private method;
982         implement as a concrete method of this abstract base class; factor...
983         (pkgDirectoryViewer::Dispatch): ...from original inline implementation
984         within this method of the concrete derived class, whence use it.
985         (pkgDirectoryViewerEngine, pkgDirectory): Factor class declarations...
986         * src/pkglist.h: ...into this new header file; include it.
987
988         * src/pkgbase.h (pkgDirectory): Add forward class declaration.
989         (pkgXmlDocument::CatalogueAllPackages): Declare it.
990
991 2012-05-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
992
993         Update help text to document package version selection capability.
994
995         * src/clistub.c (help_text): Add description of command line syntax
996         which may be used to specify an alternative to the default package
997         version selection, for install and upgrade actions.
998
999 2012-05-01  Keith Marshall  <keithmarshall@users.sourceforge.net>
1000
1001         Support options set by preferences assigned within profile.xml
1002
1003         * xml/profile.xml (preferences): New element; add defaults.
1004
1005         * src/pkgopts.h (OPTION_ASSIGNED_FLAGS, OPTION_DESKTOP_ARGS):
1006         (OPTION_START_MENU_ARGS): New enumerated constants; define them.
1007         (OPTION_DESKTOP, OPTION_START_MENU): New manifest constants.
1008         (OPTION_ASSIGNED, mark_option_as_set): New macros; define them.
1009         (pkgOpts::GetValue, pkgOpts::GetString): Restrict look-up index to
1010         least significant 12-bits of full-range index value.
1011         (pkgOpts::IsSet): New inline method; implement it.
1012
1013         * src/clistub.c (main): Reimplement --desktop and --start-menu
1014         options; each now becomes an OPTION_GENERIC optarg string store.
1015         (set_script_hook): Function no longer used; delete it; delegate to...
1016         * src/pkgbase.h (pkgXmlDocument::EstablishPreferences): ...this new
1017         method; declare it, providing its implementation in...
1018         * src/pkgopts.cpp: ...this new file; invoke it...
1019         * src/climain.cpp (climain): ...here.
1020
1021         * Makefile.in (CORE_DLL_OBJECTS): Add pkgopts.$OBJEXT
1022
1023 2012-04-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
1024
1025         Correct sequence of installation/removal progress reporting.
1026
1027         * src/pkgunst.cpp (pkgRemove): Delay output of "removing package ..."
1028         message, until after pre-remove hooks have run; this ensures that any
1029         output from the pre-remove hook scripts appears in correct sequence.
1030
1031         * src/pkginst.cpp (pkgInstall): Likewise, for "installing package ..."
1032         message, in relation to pre-install hooks.
1033
1034 2012-04-26  Keith Marshall  <keithmarshall@users.sourceforge.net>
1035
1036         mingw-get-0.5-beta-20120426-1 released.
1037
1038         * configure.ac (AC_INIT): Version number updated.
1039         * srcdist-doc/NEWS.in: Updated; bug-fix notifications added.
1040         * All files (r0-5-beta-20120426-1): Tag assigned.
1041
1042 2012-04-25  Keith Marshall  <keithmarshall@users.sourceforge.net>
1043
1044         Interim work-around for MinGW-Bug #3520864.
1045
1046         * src/pkgdeps.cpp (pkgXmlDocument::ResolveDependencies):
1047         [DEBUG_TRACE_DEPENDENCIES]: Add request flags to messages reporting
1048         the scheduling of installation activities.
1049
1050         * src/pkgexec.cpp (pkgXmlDocument::Schedule): Add temporary diagnostic
1051         hooks to confirm request flags; bracket them with #if 0 ... #endif.
1052         [ACTION_PRIMARY && pre-scheduled request]: Don't trash request flags
1053         when updating the pre-existing action item data.
1054
1055 2012-04-23  Keith Marshall  <keithmarshall@users.sourceforge.net>
1056
1057         Fix MinGW-Bug #3520488
1058
1059         * src/pkgexec.cpp (action_code): Check for, and reject NULL pointer
1060         passed as action request string; also reject ambiguous abbreviations.
1061
1062         * src/climain.cpp (climain): Discriminate between NULL pointer and
1063         other forms of invalid action keyword matching failures.
1064
1065 2012-04-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
1066
1067         mingw-get-0.5-beta-20120416-1 released.
1068
1069         * configure.ac (AC_INIT): Version number updated.
1070         (YEARS_OF_ISSUE): 2012 added.
1071
1072         * srcdist-doc/NEWS.in: Updated; release notes added.
1073         * All files (r0-5-beta-20120416-1): Tag assigned.
1074
1075 2012-04-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
1076
1077         Assign icon to temporary GUI executable file.
1078
1079         * icons/pkgicon.ico: New file, shamelessly copied from synaptic.
1080
1081         * configure.ac: Add identification for windres; propagate it to...
1082         * Makefile.in: ...here; use it to compile object from icon files...
1083         (srcdir/icons) [%.ico]: ...from this new vpath location.
1084         (gui.exe): Link to compiled icon's object file.
1085         (SRCDIST_SUBDIRS): Add icons directory.
1086
1087 2012-04-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
1088
1089         Ensure that package removal requests are correctly scheduled.
1090
1091         * src/pkgdeps.cpp (pkgXmlDocument::Schedule) [ACTION_REMOVE]: Schedule
1092         as a distinct case, when the installed version is not the most recent
1093         available release; consideration of this distinct case was previously
1094         erroneously overlooked.
1095
1096 2012-04-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
1097
1098         Correct scheduling of new prerequisites when upgrading.
1099
1100         * src/pkgdeps.cpp (pkgXmlDocument::ResolveDependencies):
1101         [ACTION_UPGRADE && ACTION_PRIMARY]: Don't exclude scheduling for this
1102         case of a prerequisite with no previously installed version; it may be
1103         a delegated primary requirement of a meta-package.
1104
1105 2012-04-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
1106
1107         Don't require subsystem within user specified version bounds.
1108
1109         * src/pkgdeps.cpp (pkgActionItem::ApplyBounds): Automatically consider
1110         "*" wild-card matches for subsystem, if user doesn't specify it.
1111
1112 2012-04-09  Charles Wilson  <mingw@cwilson.fastmail.fm>
1113
1114         Fix missing include.
1115
1116         * src/pkgdeps.cpp (pkgopts.h): Include unconditionally; do not rely...
1117         (debug.h) [DEBUG_TRACE_DYNAMIC]: ...on this, for indirect inclusion.
1118
1119 2012-04-07  Keith Marshall  <keithmarshall@users.sourceforge.net>
1120
1121         Correct a srcdist package construction defect.
1122
1123         * Makefile.in (srcdist) [for SRCDIST_SUBDIRS]: Use...
1124         (mkinstalldirs): ...this, to create package image directories.
1125
1126 2012-04-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
1127
1128         Add scripting hooks to support creation of MS-Windows shortcuts.
1129
1130         * src/clistub.c (progname): New static variable with file scope; it
1131         replaces former automatic variable, of same name, in main() function.
1132         (set_script_hook): New static function; implement it, and call it...
1133         (main) [--desktop, --start-menu]: ...from here, to interpret these new
1134         command line options; they are propagated to scripts via...
1135         (MINGW_GET_DESKTOP_HOOK, MINGW_GET_START_MENU_HOOK): ...these new
1136         internally assigned environment variables.
1137         (help_text): Document --desktop and --start-menu.
1138
1139         * scripts/libexec/setup.lua scripts/libexec/wsh.lua: New lua module
1140         files; they implement a lua scripting API; they delegate requests to
1141         the Windows Scripting Host, via either of this pair of...
1142         * scripts/libexec/shlink.js: ...new script to create shortcuts, or...
1143         * scripts/libexec/unlink.js: ...its complement, to remove them.
1144         * Makefile.in (SRCDIST_SUBDIRS): Integrate them; enumerate them in...
1145         (scripts_srcdir, LIBEXEC_SCRIPTS): ...these new macros; use to...
1146         (install): ...install them.
1147
1148 2012-04-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
1149
1150         Initialise $LUA_PATH to locate mingw-get specific scripts.
1151
1152         * src/pkgexec.cpp (lua_path_init): New static inline function.
1153         (pkgXmlNode::DispatchScript): Call it on first time invocation, per...
1154         [lua_path_setup == false]: ...this static function local variable.
1155
1156 2012-04-01  Keith Marshall  <keithmarshall@users.sourceforge.net>
1157
1158         Support installation of releases other than latest available.
1159
1160         * src/pkgbase.h (pkgActionItem::ApplyBounds): New method; declare it.
1161
1162         * src/pkgdeps.cpp (pkgActionItem::ApplyBounds): Implement it.
1163         (pkgXmlDocument::Schedule): Use it to interpret user specified version
1164         bounds, and apply them to scheduled action items.  Having used...
1165         (get_version_bounds): ...this new static inline function...
1166         ...to acquire any user specified version bounds, check that they can
1167         be honoured, before scheduling any action; delegate diagnostics to...
1168         (dmh_notify_no_match): ...this new local helper function, to report
1169         when they can't, and to indicate viable alternatives.
1170
1171 2012-03-26  Keith Marshall  <keithmarshall@users.sourceforge.net>
1172
1173         Rework previously inadequate solution for MinGW-Bug #3424406
1174
1175         * src/pkgtask.h: Update copyright notice for current year.
1176         (ACTION_MAY_SELECT): New manifest constant for use as flag; define it.
1177         * src/pkgexec.cpp (pkgActionItem::SelectIfMostRecentFit): Assign it.
1178
1179         * src/pkgdeps.cpp (STATIC_INLINE): New macro; define it.
1180         (ACTION_RECURSIVE_REINSTALL, ACTION_RECURSIVE_UPGRADE):
1181         (ACTION_RECURSIVE_REPLACE): New action code constants; define them.
1182         (with_flags): Original macro deleted; replace it with...
1183         (with_request_flags): ...this new static inline function.
1184         (if_noref, if_match, if_alias, with_download, promote): New static
1185         inline functions; they replace original macros of the same names.
1186         (is_recursive_action): Function no longer used; delete it.
1187         (action_class): New static inline function; implement and use it...
1188         (pkgXmlDocument::ResolveDependencies): ...here, to identify scheduling
1189         requirements for packages which are already installed; depends on...
1190         (request_mode): ...this new automatic variable; it augments and...
1191         (recursive_mode): ...replaces this one; rename it accordingly.
1192         (viable): Automatic variable no longer used; delete it.
1193         [DEBUG_REQUEST & DEBUG_TRACE_DEPENDENCIES]: Emit notification for
1194         scheduled installation.
1195         (pkgXmlDocument::Schedule): Add an implied...
1196         (ACTION_REMOVE): ...when scheduling a reinstallation.
1197
1198 2012-03-13  Keith Marshall  <keithmarshall@users.sourceforge.net>
1199
1200         Address reinstallation issues per MinGW-Bugs #3416013 and #3424406
1201
1202         * src/pkgexec.cpp (reinstall_action_scheduled): New inline function.
1203         (pkgActionItem::Execute): Use it to identify cases where...
1204         [--reinstall]: ...implicit package removal is required, and also to
1205         facilitate improved progress reporting in such cases.
1206
1207         * src/pkgdeps.cpp (is_recursive_action): New inline function.
1208         (pkgXmlDocument::ResolveDependencies): Use it in tandem with...
1209         (recursive_mode): ...this new automatic variable, so as to handle...
1210         [meta-package dependency]: ...implicit recursion, to extend the scope
1211         of the current action to the first level of non-meta dependency.
1212         [install --reinstall]: ...reinstall original version of nominated
1213         package, ignoring any available upgrade; extend scope of operation...
1214         [install --reinstall --recursive]: ...to all prerequisite packages.
1215         [upgrade --reinstall]: ...upgrade nominated package if possible; if no
1216         upgrade available, reinstall current version; extend scope...
1217         [upgrade --reinstall --recursive]: ...to all prerequisites.
1218         (pkgXmlDocument::Schedule): Partially revert 2012-03-05 change;
1219         reimplement selectively; never promote...
1220         [install, install --reinstall]: ...these operations to become...
1221         [upgrade]: ...this, even if available; issue diagnostic instead.
1222
1223 2012-03-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1224
1225         Rationalise implementation and usage of --all-related option.
1226
1227         * src/pkgopts.h: Update copyright notice; add year 2012.
1228         (OPTION_RECURSIVE, OPTION_ALL_RELATED): New constants; define them.
1229         (pkgOpts::SetFlags): New method; declare and implement it inline.
1230
1231         * src/clistub.c: Update copyright notice; add year 2012.
1232         (options) [recursive, all-related]: Redefine in terms of...
1233         (OPTION_RECURSIVE, OPTION_ALL_RELATED): ...these.
1234         (help_text): Update appropriately.
1235
1236         * src/climain.cpp: Update copyright notice; add year 2012.
1237         (climain) [all-related]: Associate its use exclusively with...
1238         (source, licence): ...these package processing operations; use...
1239         (pkgOptions::SetFlags): ...this, to propagate its effect.
1240
1241 2012-03-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1242
1243         Don't report failed downloads in respect of virtual packages.
1244
1245         * src/pkginet.cpp (pkgActionItem::DownloadArchiveFiles): Clear...
1246         [ACTION_DOWNLOAD]: ...this status flag for any package identified as
1247         a meta-package; this corrects a further regression introduced with the
1248         2011-11-09 update, whereby pending download requests for such virtual
1249         packages were not cancelled, resulting in failure to install due to
1250         failed downloads, when no download is actually required.
1251
1252 2012-03-05  Keith Marshall  <keithmarshall@users.sourceforge.net>
1253
1254         Don't suppress implied downloads for top-level actions.
1255
1256         * src/pkgdeps.cpp: Update copyright notice for new year.
1257         (pkgXmlDocument::Schedule) [!OPTION_PRINT_URIS]: Ensure that...
1258         [ACTION_DOWNLOAD]: ...this is enabled, when scheduling an install or
1259         an upgrade action for a package specified as a command line argument;
1260         this corrects a regression introduced on 2011-11-09, which resulted in
1261         ACTION_DOWNLOAD being enabled only for second tier dependent actions.
1262
1263 2012-02-20  Keith Marshall  <keithmarshall@users.sourceforge.net>
1264
1265         Copyright notice updates.
1266
1267         * Makefile.in: Add 2012 as year of republication.
1268         * src/pkgbase.h src/sysroot.cpp src/pkgexec.cpp: Likewise.
1269         * src/rites.c src/pkginst.cpp src/pkgunst.cpp: Likewise.
1270
1271 2012-02-20  Keith Marshall  <keithmarshall@users.sourceforge.net>
1272
1273         Fix ill-advised optimisation in $APPROOT environment lookup.
1274
1275         * src/rites.c (approot_path): Don't save result of getenv() lookup
1276         across calls; the environment may have been moved in the interim,
1277         making the original result invalid on any subsequent call.  Also,
1278         prefer MS-Windows style (with backslashes) for default.
1279         (pkgLastRites): Report full path name for lastrites.exe, on execl()
1280         failure, rather than only the path relative to $APPROOT.
1281
1282 2012-02-20  Keith Marshall  <keithmarshall@users.sourceforge.net>
1283
1284         Propagate sysroot path settings to scripts via the environment.
1285
1286         * src/pkgbase.h (PKG_PUTENV_FLAGS_MASK): New constant; it maps...
1287         (PKG_PUTENV_DIRSEP_MSW, PKG_PUTENV_DIRSEP_POSIX): ...these flags...
1288         (PKG_PUTENV_SCAN_VARNAME, PKG_PUTENV_NAME_TOUPPER): ...and these;
1289         they are used to specify optional behavioural choices for...
1290         (pkgPutEnv): ...this new function; declare it.
1291
1292         * src/sysroot.cpp (pkgPutEnv): Implement it.
1293         (pkgXmlDocument::LoadSystemMap): Use it to add $SUBSYSTEM_SYSROOT path
1294         specifications to the environment, for each named subsystem associated
1295         with the active system map.
1296
1297         * src/pkgexec.cpp (pkgActionItem::Execute): Invoke pkgPutEnv() prior
1298         to processing of each package install, upgrade, or remove action, so
1299         as to update environment variable $SYSROOT to represent the sysroot
1300         path for each package processed, during execution of script hooks.
1301
1302 2012-02-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
1303
1304         Implement hooks to support lua scripting interface.
1305
1306         * Makefile.in (LIBS): Add -llua.
1307
1308         * src/pkgbase.h (pkgXmlNode::InvokeScript): New method; declare it
1309         as private, and provide overloaded public inline API implementation.
1310         (pkgXmlNode::DispatchScript): New private method; declare it.
1311
1312         * src/pkgexec.cpp (pkgXmlNode::InvokeScript): Implement it.
1313         (pkgXmlNode::DispatchScript): Likewise; it directs InvokeScript to...
1314         (pkgInvokeScript): ...this new static function; implement it.
1315
1316         * src/pkginst.cpp (pkgInstall): Call InvokeScript as appropriate.
1317         * src/pkgunst.cpp (pkgRemove): Likewise.
1318
1319 2011-11-24  Keith Marshall  <keithmarshall@users.sourceforge.net>
1320
1321         Avoid implicit cast warnings; reported by Robert Hartmann.
1322
1323         * src/dmh.h (DMH_BEGIN_DIGEST): Explicitly cast to uint16_t.
1324         (DMH_END_DIGEST): Likewise.
1325
1326 2011-11-09  Keith Marshall  <keithmarshall@users.sourceforge.net>
1327
1328         Avoid unnecessary downloads for already installed packages.
1329
1330         * src/pkginet.cpp (pkgActionItem::DownloadSingleArchive): Require
1331         external scheduling of ACTION_DOWNLOAD; cancel the scheduled request
1332         on completion, or when not required due to pre-existing local copy.
1333
1334         * src/climain.cpp (pkgActionItem::GetSourceArchive): Must always be
1335         prepared to download the associated archive; enable ACTION_DOWNLOAD.
1336
1337         * src/pkgexec.cpp (pkgActionItem::Schedule) [OPTION_REINSTALL]:
1338         May need to download the archive, even when the requested package was
1339         previously installed; schedule ACTION_DOWNLOAD to enable this.
1340
1341         * src/pkgdeps.cpp (promote): Macro redefined in terms of...
1342         (with_flags, with_download): ...these new macros; implement and...
1343         (pkgXmlDocument::ResolveDependencies): ...use them to enable/schedule
1344         ACTION_DOWNLOAD only when expected that it may be necessary.
1345
1346 2011-11-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
1347
1348         Fix packaging anomalies for source and licence distributions.
1349
1350         * Makefile.in (licdist): Link README from ${CURDIR}, not from '..'.
1351         (srcdist): Explicitly link pkginfo.c from ${CURDIR} to src/pkginfo,
1352         rather than as implied prerequisite; this avoids a bogus attempt to
1353         link srcdist-doc into src/pkginfo.
1354
1355 2011-11-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
1356
1357         Bump version number for subsequent CVS snapshots.
1358
1359         * configure.ac (AC_INIT): Set version to 0.4-alpha-1.1cvs
1360
1361 2011-11-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
1362
1363         mingw-get-0.4-mingw32-alpha-1 released.
1364
1365         * configure.ac (AC_INIT): Adjust version number.
1366         * srcdist-doc/NEWS.in: Updated; document new features and bugs fixed.
1367         * All files (r0-4-alpha-1): Tag assigned.
1368
1369 2011-11-04  Keith Marshall  <keithmarshall@users.sourceforge.net>
1370
1371         Don't upgrade installed DLL components to incompatible version.
1372         Provide clearer diagnostics for failed requests on implied packages.
1373
1374         * src/pkgdeps.cpp (is_abi_compatible): New static inline function.
1375         (pkgXmlDocument::ResolveDependencies) [is_installed]: Use it.
1376         (pkgXmlDocument::ResolveDependencies) [DEBUG_TRACE_DEPENDENCIES]:
1377         Clean up and improve diagnostic message content and formatting.
1378         (pkgXmlDocument::Schedule) [(upgrade || remove) && ! installed]:
1379         Downgrade diagnostic to WARNING, for implicitly specified component
1380         packages; provide additional explanatory diagnostics.
1381
1382         * src/pkgspec.cpp (pkgSpecs::VersionComparator):
1383         * src/pkgexec.cpp (pkgActionItem::SelectIfMostRecentFit):
1384         [DEBUG_TRACE_DEPENDENCIES]: Eliminate diagnostic noise.
1385
1386 2011-10-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
1387
1388         Fix --download-only vs. --reinstall conflict.
1389
1390         * src/pkgexec.cpp (pkgActionItem::Execute) [OPTION_DOWNLOAD_ONLY]:
1391         Test for explicit inequality, rather than equality to zero; since the
1392         2011-08-30 update, which made --download-only also imply --reinstall,
1393         it will test as non-zero when --reinstall is specified, even though
1394         --download-only is not.
1395
1396 2011-10-07  Keith Marshall  <keithmarshall@users.sourceforge.net>
1397
1398         Add support for non-specific upgrade of all installed packages.
1399
1400         * src/pkgbase.h (pkgXmlDocument::RescheduleInstalledPackages):
1401         New public method; declare it.
1402
1403         * src/pkgdeps.cpp (pkgXmlDocument::RescheduleInstalledPackages):
1404         Implement it.
1405
1406         * src/climain.cpp (climain) [ACTION_UPGRADE && argc < 2]: Invoke
1407         pkgXmlDocument::RescheduleInstalledPackages() to schedule the upgrade
1408         request for all packages currently registered as installed.
1409
1410 2011-10-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
1411
1412         Implement "source" and "licence" operations.
1413
1414         * src/pkgopts.h (OPTION_ALL_DEPS): New option code; define it.
1415         * src/clistub.c (main): Associate it with...
1416         (all-related, recursive): ...these synonymous option names...
1417         (options): ...defined within this local structured array.
1418         (help_text): Document them; also document "source" and "licence" as
1419         new operations which may be specified on the command line.
1420
1421         * src/pkgtask.h (action_source, action_licence): Enumerate them.
1422         (ACTION_SOURCE, ACTION_LICENCE): Define their manifest values, and...
1423         * src/pkgexec.cpp (action_name): ...associate with operation names.
1424
1425         * src/pkgbase.h (pkgActionItem::GetScheduledSourceArchives):
1426         (pkgActionItem::GetSourceArchive, pkgXmlDocument::GetSourceArchive):
1427         New public methods; declare them for external implementation.
1428         (pkgXmlDocument::GetScheduledSourceArchives): New public method;
1429         implement it as inline.
1430
1431         * src/climain.cpp (pkgProcessedArchives): New pointer to stack of...
1432         (pkgArchiveNameList): ...this new locally defined class; implement it.
1433         (pkgActionItem::GetSourceArchive, pkgXmlDocument::GetSourceArchive):
1434         (pkgActionItem::GetScheduledSourceArchives): Implement them.
1435         (climain): Add invocation hooks.
1436
1437 2011-10-04  Keith Marshall  <keithmarshall@users.sourceforge.net>
1438
1439         Establish mapping from release tarname to source tarname.
1440
1441         * src/pkgreqs.cpp (inherited_requirement): New inline function.
1442         (requirement): Use it; adapt to propagate release archive format and
1443         compression type fields, in addition to version fields, when resolving
1444         "%" wildcard matches within the template for the resultant tarname.
1445         (pkgAssociateName): New public function; implement it for use by...
1446         * src/pkgname.cpp (pkgResolvedName): ...this new inline function.
1447         (pkgXmlNode::SourceArchiveName): Use it; adapt to accept a category
1448         selector, so it may resolve source or licence tarnames on demand.
1449
1450         * src/pkgbase.h (pkgXmlNode::SourceArchiveName): Modify declaration;
1451         add category selector argument to support source/licence choice.
1452
1453 2011-10-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
1454
1455         Facilitate downloads using diverse cache directories.
1456
1457         * src/pkgbase.h (pkgActionItem::DownloadSingleArchive): New private
1458         method; declare it; it handles the download for a single named archive
1459         file, and stores it in a specifed cache directory.
1460
1461         * src/pkginet.cpp (pkgActionItem::DownloadSingleArchive): Implement
1462         it; factor its code from the original implementation within...
1463         (pkgActionItem::DownloadArchiveFiles): ...this; adapt to use it.
1464
1465 2011-10-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
1466
1467         Establish cache directory for source archive downloads.
1468
1469         * src/mkpath.h (pkgSourceArchivePath): New function; declare it.
1470         * src/mkpath.c (pkgSourceArchivePath): Implement it.
1471
1472 2011-08-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
1473
1474         Support archive extraction to arbitrary destination without install.
1475
1476         * src/pkgproc.h (pkgArchiveProcessor::ExtractFile): New virtual
1477         helper method for use, as core helper, by derived classes; declare it.
1478         (pkgArchiveProcessor::CreateExtractionDirectory): Likewise.
1479         (pkgTarArchiveProcessor): Declare overloaded default constructor.
1480         (pkgTarArchiveExtractor): New class definition; it is derived from
1481         pkgTarArchiveProcessor.
1482
1483         * src/tarproc.cpp (pkgArchiveProcessor::ExtractFile): Implement it.
1484         (pkgArchiveProcessor::CreateExtractionDirectory): Likewise.
1485         (pkgTarArchiveExtractor): Implement constructor, together with...
1486         (pkgTarArchiveExtractor::ProcessDirectory): ...this method, and also...
1487         (pkgTarArchiveExtractor::ProcessDataStream): ...this one; these are
1488         declared as abstract, in the pkgTarArchiveProcessor base class.
1489         (pkgTarArchiveInstaller::ProcessDirectory): Simplify; it now delegates
1490         directory creation to pkgArchiveProcessor::CreateExtractionDirectory.
1491         (pkgTarArchiveInstaller::ProcessDataStream): Simplify; delegate file
1492         handling to pkgArchiveProcessor::ExtractFile, as appropriate.
1493
1494 2011-08-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
1495
1496         Make --download-only and --print-uris imply --reinstall.
1497
1498         * src/pkgopts.h (OPTION_PRINT_URIS): Adjust definition.
1499         (OPTION_DNLOAD_ONLY, OPTION_DOWNLOAD_ONLY): Likewise.
1500
1501 2011-08-07  Keith Marshall  <keithmarshall@users.sourceforge.net>
1502
1503         Implement --download-only and --print-uris options.
1504
1505         * src/pkgopts.h (OPTION_DOWNLOAD_ONLY, OPTION_PRINT_URIS):
1506         New manifest constants, identifying flag bits; define them.
1507         (OPTION_DNLOAD_ONLY): Likewise; an alias for OPTION_DOWNLOAD_ONLY.
1508
1509         * src/pkgbase.h (pkgActionItem::PrintURI): New private method.
1510         * src/pkginet.cpp: Implement it.
1511
1512         * src/clistub.c (options): Add "download-only" and "print-uris".
1513         (help_text): Document them.
1514         * src/pkgexec.cpp (pkgActionItem::Execute): Process them.
1515
1516 2011-07-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
1517
1518         mingw-get-0.3-mingw32-alpha-2.1 released.
1519
1520         * configure.ac (AC_INIT): Adjust version number.
1521         * srcdist-doc/NEWS.in: Updated; document bugs fixed.
1522         * All files (r0-3-alpha-2-1): Tag assigned.
1523
1524 2011-07-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
1525
1526         Adopt tar.xz as default package archive format.
1527
1528         * Makefile.in (TARZIP, TAREXT): New macros; define them.
1529         (bindist, licdist, srcdist): Use them in place of hardcoded tar.gz
1530         (maintainer-clean): Expunge tar files of any compression format.
1531
1532 2011-07-27  Keith Marshall  <keithmarshall@users.sourceforge.net>
1533
1534         Correct handling of release status in requirements specifications.
1535
1536         * src/debug.h (DEBUG_TRACE_DEPENDENCIES): New tracing hook; define it.
1537         * src/pkgexec.cpp (pkgActionItem::SelectIfMostRecentFit): Use it; add
1538         function entry/exit tracing report hooks.
1539         * src/pkgdeps.cpp (pkgXmlDocument::ResolveDependencies): Likewise;
1540         also add internal trace point reporting, which may also require...
1541         (show_required): ...this new static inline DEBUG_INVOKED function.
1542
1543         * src/pkgreqs.cpp (requirement): Propagate release status and release
1544         reference index fields from requirer, when package version requirement
1545         is specified by a '%' token, and no explicit release status override
1546         is included in the requirement specification.
1547
1548         * src/pkgspec.cpp (is_wildcard_spec): New static inline helper.
1549         (pkgSpecs::VersionComparator): Use it to identify any package version
1550         specification which may require the extension of a wildcard match, to
1551         span the package version and release status fields; also add tracing
1552         hooks, triggered on DEBUG_TRACE_DEPENDENCIES, to facilitate debugging.
1553
1554 2011-06-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
1555
1556         Avoid accidental RCS keyword substitutions.
1557
1558         * Makefile.in (DOLLAR): New macro; define it.
1559         (readme.txt, readme.txt.in): Use it, where unexpanded RCS Id keyword
1560         matching is intended.
1561
1562 2011-06-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
1563
1564         Mercurial support revisited.
1565
1566         * .cvsignore (.hgtags): Add to CVS untracked list.
1567
1568 2011-06-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
1569
1570         Update readme.txt ID tag-line to track NEWS rather than README.
1571
1572         * Makefile.in (readme.txt.in): New rule; implement it.
1573         (readme.txt.tag): Likewise; this implements the tag-line tracking.
1574         (readme.txt): Rule redefined in terms of the preceding pair.
1575
1576 2011-06-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
1577
1578         mingw-get-0.3-mingw32-alpha-2 released.
1579
1580         * configure.ac (AC_INIT): Adjust version number.
1581         * srcdist-doc/NEWS.in: Updated; document new features and bugs fixed.
1582         * All files (r0-3-alpha-2): Tag assigned.
1583
1584 2011-06-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
1585
1586         Add internal documentation for --reinstall option.
1587
1588         * src/clistub.c (help_text): Add description for "--reinstall".
1589
1590 2011-06-14  Keith Marshall  <keithmarshall@users.sourceforge.net>
1591
1592         Support use of Mercurial within a CVS working copy.
1593
1594         * .cvsignore (.hg, .hgignore): Don't have CVS track these.
1595
1596 2011-06-13  Keith Marshall  <keithmarshall@users.sourceforge.net>
1597
1598         Implement --reinstall option.
1599
1600         * src/pkgopts.h (OPTION_REINSTALL): New macro; define it.
1601         (OPTION_GENERIC, OPTION_SHIFT_MASK): Likewise.
1602         (OPTION_EXTRA_FLAGS): New field; declare it.
1603
1604         * src/clistub.c (options): Add "reinstall".
1605         (OPTION_GENERIC): Use it where appropriate; within its scope...
1606         (OPTION_STORAGE_CLASS): Improve descriptive comments; add handling for
1607         default case of flag type options requiring an alignment shift.
1608
1609         * src/pkgexec.cpp: Remove previous "always reinstall" kludge.
1610         (pkgOptionSelected, PKG_OPTION_REINSTALL): Remove obsolete macros.
1611         (pkgActionItem::Execute): Check for "upgrade" request on any package
1612         which is already up to date; report this state, otherwise...
1613         [OPTION_REINSTALL || ACTION_UPGRADE]: Mark package as "removed", to
1614         avoid bail-out on "package already installed", when calling...
1615         (pkgInstall): ...this.
1616
1617 2011-06-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1618
1619         Don't require -vv to report progress of update operation.
1620
1621         * src/pkgbind.cpp (pkgRepository::GetPackageList): Eliminate all
1622         basename() calls; `dname' already tells us what it should return.
1623         [update]: Report progress, irrespective of verbosity setting.
1624
1625 2011-06-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
1626
1627         Fix MinGW-Bug #3313806.
1628
1629         * src/pkginfo/pkginfo.l (CMS_KEYWORDS): Do not match them within the
1630         PACKAGE_NAME field; this avoids misinterpretation as a release status
1631         qualifier when intended as part of the package name, as in msys-cvs.
1632
1633 2011-06-07  Keith Marshall  <keithmarshall@users.sourceforge.net>
1634
1635         Provisional correction for MinGW-Bug #3309438.
1636
1637         * src/debug.h [DEBUGLEVEL == 0]: Provide defaults for...
1638         (DEBUG_ENABLED, DEBUG_REQUEST): ...these macros.
1639
1640         * src/tarproc.cpp (pkgTarArchiveInstaller::ProcessDirectory):
1641         (pkgTarArchiveInstaller::ProcessDataStream): Use DEBUG_REQUEST to
1642         enable runtime trace activation for previous compile time choices.
1643
1644 2011-05-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
1645
1646         mingw-get-0.3-mingw32-alpha-1 released.
1647
1648         * configure.ac (AC_INIT): Adjust version number.
1649         * srcdist-doc/NEWS.in: Updated; document new features.
1650         * All files (r0-3-alpha-1): Tag assigned.
1651
1652 2011-05-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
1653
1654         Support assignment of DEBUGLEVEL at configure time.
1655
1656         * configure.ac (DEBUGLEVEL): Declare as a precious variable, using
1657         AC_ARG_VAR; also declare with AC_SUBST, to ensure it is initialised.
1658
1659         * Makefile.in (DEBUGLEVEL): Let AC_SUBST assign it.
1660
1661 2011-05-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
1662
1663         Work around bugs in MinGW and GNU getopt_long_only() implementations.
1664
1665         * src/getopt.c: New file; this is a free-standing replacement for any
1666         implementation provided by system libraries.  We will always use this
1667         to ensure correct operation irrespective of system bugs; (different
1668         bug manifestations have been identified in the stock MinGW and GNU
1669         implementations).
1670
1671         * Makefile.in (mingw-get.EXEEXT): Use it.
1672
1673         * src/clistub.c (options): Remove redundant declaration of `-v' as a
1674         long form option.
1675
1676 2011-05-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
1677
1678         Implement user selection of traceable features at run-time.
1679
1680         * src.pkgopts.h (OPTION_VERBOSE_MAX): New macro; define it.
1681
1682         * src/debug.h (DEBUG_ENABLED): New macro; define it.
1683         (DEBUG_REQUEST, DEBUG_REQUEST_FLAGS, DEBUG_TRACE_DYNAMIC): Likewise.
1684
1685         * src/clistub.c (main) [--trace]: Don't make it available unless...
1686         [DEBUG_ENABLED(DEBUG_TRACE_DYNAMIC)]: ...this is set (at compile-time).
1687         [--verbose]: Limit to OPTION_VERBOSE_MAX, using...
1688         (atmost): ...this new macro; define it.
1689         (options): Declare `-v' as both long and short form, pending bug fix
1690         in MinGW's getopt_long_only() implementation.
1691
1692         * src/pkginet.cpp (pkgInternetAgent::OpenURL): Use DEBUG_REQUEST.
1693         (pkgInternetLzmaStreamingAgent::TransferData): Likewise.
1694         (pkgInternetStreamingAgent::TransferData): Likewise.
1695         (pkgInternetStreamingAgent::Get): Likewise.
1696
1697         * src/pkgunst.cpp (pkgActionItem::SetAuthorities): Use DEBUG_REQUEST.
1698         (pkg_rmdir, pkg_unlink): Likewise.
1699
1700         * src/sysroot.cpp (pkgXmlDocument::LoadSystemMap): Use DEBUG_REQUEST.
1701
1702 2011-05-21  Keith Marshall  <keithmarshall@users.sourceforge.net>
1703
1704         Implement protocol for processing global program options.
1705
1706         * src/pkgopts.h: New file.
1707
1708         * src/climain.cpp (cli_setopts): New function; implement it.
1709         (pkgOptions): Likewise.
1710
1711         * src/clistub.c (xatoi): New function; implement it.
1712         (cli_setargv): New inline helper function; implement it.
1713         (main): Use it.  Also incorporate implementation of...
1714         (parsed_options): New structure; it accommodates...
1715         (verbose, trace): New options; interpret them, and...
1716         (help_text): ...document them.
1717
1718         * src/pkgbind.cpp (pkgRepository::GetPackageList): Make catalogue
1719         loading notifications and progress reports conditional on...
1720         [OPTION_VERBOSE > 1]: ...this.
1721
1722 2011-05-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
1723
1724         Augment known development status keywords and accept CMS labels.
1725
1726         * src/pkginfo/pkginfo.l (CMS_KEYWORDS): Define new provisional list;
1727         add transitional state scanner rule and code to interpret them.
1728         (STATUS_KEYWORDS): Add "pre" and "rc" to existing list; modify scanner
1729         code to maintain consistency with CMS_KEYWORDS processing; also extend
1730         this coding strategy to other rules.
1731
1732         * src/pkginfo/driver.c (spec): Strip initial '$' token from displayed
1733         field values; (we expect it only for a CMS_KEYWORDS field value).
1734
1735         * src/pkgreqs.cpp (pkgSpecs::GetTarName): Remove any initial '$' token
1736         from PACKAGE_RELEASE_STATUS field, when performing reverse of tarname
1737         decomposition transformation.
1738
1739 2011-05-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
1740
1741         Correct omission from 2011-02-18 commit.
1742
1743         * src/tarproc.cpp (Copyright Notice): Add 2011 as year of release.
1744
1745 2011-05-14  Keith Marshall  <keithmarshall@users.sourceforge.net>
1746
1747         mingw-get-0.2-mingw32-alpha-4 released.
1748
1749         * configure.ac (AC_INIT): Adjust version number.
1750         * srcdist-doc/NEWS.in: Updated; add bug-fix/feature descriptions.
1751         * All files (r0-2-alpha-4): Tag assigned.
1752
1753 2011-05-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1754
1755         Fix MinGW-Bug #3297660 (reported by Chris Sutcliffe).
1756
1757         * src/pkgbase.h (pkgActionItem::SetAuthorities): Return unsigned long.
1758         (pkgActionItem::HasAttribute): New inline method; implement it.
1759
1760         * src/pkgtask.h (ACTION_DOWNLOAD, ACTION_DOWNLOAD_OK): New macros.
1761
1762         * src/pkginet.cpp (pkgActionItem::DownloadArchiveFiles):
1763         [ACTION_DOWNLOAD]: Assert it at commencement of each package download;
1764         clear it again, on successful download completion.
1765
1766         * src/pkginst.cpp (pkgtask.h): #include it.
1767         (pkgInstall) [ACTION_DOWNLOAD]: Don't proceed with installation when
1768         set; this indicates failed download; diagnose it.
1769
1770         * src/pkgunst.cpp (pkgRemove) [ACTION_DOWNLOAD && ACTION_UPGRADE]:
1771         Don't proceed with pre-emptive removal when both set; this indicates
1772         failed download of replacement package; diagnose it.
1773
1774 2011-05-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1775
1776         Fix MinGW-Bug #3295526 (reported by Charles Wilson).
1777
1778         * src/pkgunst.cpp (sys/stat.h): #include it; we need it for...
1779         (pkg_unlink): ...chmod( file, S_IWRITE ), emulating `rm -f' semantics.
1780
1781 2011-05-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1782
1783         Diagnose and aggressively retry failed download connections.
1784
1785         * src/debug.h (DEBUG_TRACE_INTERNET_REQUESTS): New macro; define it.
1786
1787         * src/pkginet.cpp (debug.h): #include it.
1788         (pkgDownloadMeter): New abstract class; declare it and implement its
1789         default (non-abstract) data and methods; derive...
1790         (pkgDownloadMeterTTY): ...this new class from it; implement it...
1791         (pkgInternetStreamingAgent::Get): ...and instantiate it (naively for
1792         now), as associated pkgDownloadMeter object; add tracing diagnostic.
1793         (pkgInternetAgent::OpenURL): Don't inline it; move implementation out
1794         of line; add retry loops to aggressively retry failed connections.
1795         (pkgInternetAgent::QueryContentLength): New method; implement it.
1796         (pkgInternetStreamingAgent::TransferData): Avoid Microsoft specific
1797         data type `DWORD'; prefer equivalent standard `unsigned long'.  Add
1798         tracing diagnostic.  Remove progress diagnostic; replace it with an
1799         `Update' request to associated pkgDownloadMeter.
1800         (pkgInternetLzmaStreamingAgent::GetRawData): Avoid `DWORD' data type.
1801         (pkgInternetLzmaStreamingAgent::TransferData): Likewise; add tracing
1802         diagnostic on failure.
1803
1804 2011-03-31  Keith Marshall  <keithmarshall@users.sourceforge.net>
1805
1806         mingw-get-0.2-mingw32-alpha-3 released.
1807
1808         * configure.ac (AC_INIT): Adjust version number.
1809         * srcdist-doc/NEWS.in: Updated; add bug-fix description.
1810         * All files (r0-2-alpha-3): Tag assigned.
1811
1812 2011-03-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
1813
1814         Provisional handling for http proxy authentication.
1815         (Adapted from patch by Scott Michel <pingbak@users.sourceforge.net>)
1816         (ref: MinGW-Patch #3158453)
1817
1818         * src/pkginet.cpp: Several format/layout adjustments; add comments.
1819         Eliminate several instances of Microsoft specific typedef nastiness.
1820         (dmh_dialogue_context): New macro; kludge definition to support...
1821         (pkgInternetAgent::OpenURL) [HTTP_STATUS_PROXY_AUTH_REQ]: Detect
1822         and handle it.
1823
1824 2011-03-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
1825
1826         Expand macros in path names for files and directories to be removed.
1827
1828         * src/pkgunst.cpp (pkgRemove): Format sysroot as a template, so...
1829         (pkg_rmdir, pkg_unlink): ...are able to use mkpath() to construct the
1830         full path name for each file or directory to be removed.
1831
1832 2011-03-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
1833
1834         Correct defective activation logic for some debugging hooks.
1835
1836         * src/pkgunst.cpp (pkg_rmdir, pkg_unlink) [DEBUG_INVOKE_IF]:
1837         (pkgActionItem::SetAuthorities) [DEBUG_INVOKE_IF]: Use bit-wise `&'
1838         operator, not `&&', to evaluate DEBUGLEVEL state.
1839
1840 2011-03-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
1841
1842         Avoid Unicode hyphens in generated ASCII document files.
1843
1844         * Makefile.in (NROFF): New macro; define it to invoke `nroff -Tascii'.
1845         (%.dist, readme.txt): Use it to ensure that output is pure ASCII.
1846
1847 2011-03-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
1848
1849         mingw-get-0.2-mingw32-alpha-2 released.
1850
1851         * configure.ac (AC_INIT): Adjust version number.
1852         * srcdist-doc/NEWS.in: Updated; add bug-fix description.
1853         * All files (r0-2-alpha-2): Tag assigned.
1854
1855 2011-03-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
1856
1857         Fix MinGW-Bug 3212246.
1858
1859         * src/keyword.c (has_keyword): Avoid incrementing the comparison
1860         pointers when a significant character in one string is not matched in
1861         the other; previously the pointers were left pointing one character to
1862         the right of the mismatch, and this was overlooked if the mismatch
1863         occurred at the rightmost character in both strings.
1864
1865 2011-03-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1866
1867         mingw-get-0.2-mingw32-alpha-1 released.
1868
1869         * configure.ac (AC_INIT): Set version number; correct capitalisation
1870         in URI reference to bug reporting instructions.
1871
1872         * srcdist-doc/NEWS.in: Confirm release date.
1873         [bug reporting]: Remove redundant paragraph; the information is
1874         provided, via reference to mingw.org. in the README and INSTALL files.
1875
1876         * All files (r0-2-alpha-1): Tag assigned.
1877
1878 2011-03-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
1879
1880         * srcdist-doc/INSTALL.in [building]: Qualify liblzma.a requirement;
1881         add earliest acceptable snapshot release date.
1882
1883 2011-03-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
1884
1885         Remove unused 7zip and boost source code from CVS trunk.
1886
1887         * 7z: Directory and all content removed.
1888         * boost: Likewise.
1889
1890 2011-03-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
1891
1892         Refactor and update existing installation and usage instructions.
1893
1894         * src/clistub.c (help_text): Updated.
1895
1896         * srcdist-doc: New directory.
1897
1898         * README: Deleted; its content refactored into...
1899         * srcdist-doc/README.in srcdist-doc/INSTALL.in srcdist-doc/NEWS.in:
1900         ...these new template files, updated for current development state.
1901
1902         * srcdist-doc/gendoc.sed.in: New sed script; it directs formatting of
1903         generated text files derived from the srcdist-doc templates.
1904
1905         * Makefile.in (SRCDIST_SUBDIRS): Add srcdist-doc.
1906         (SRCDIST_FILES): Add NEWS and INSTALL.
1907         (srcdist-doc): New build rule to generate README, NEWS and INSTALL.
1908         (srcdist, licdist): Adjust path to locate them.
1909         (readme.txt): New build rule to generate on-line package description.
1910         (dist): Require it.
1911         (distclean): Don't remove Makefile...
1912         (maintainer-clean): ...but do it here instead.  Also remove generated
1913         README, NEWS and INSTALL, the autom4te cache, and all distributable
1914         zip files, in addition to tarballs, for the current version.
1915
1916 2011-02-27  Keith Marshall  <keithmarshall@users.sourceforge.net>
1917
1918         Initial implementation for "remove" feature.
1919
1920         * src/pkgbase.h: Update copyright notice; add current year.
1921         (pkgActionItem::SetPrimary): New inline public method; declare it.
1922         (pkgActionItem::SetAuthorities): New public method; declare it.
1923
1924         * src/pkgtask.h (ACTION_PREFLIGHT, ACTION_REMOVE_OK): New defines.
1925
1926         * src/pkgproc.h: Update copyright notice; add current year.
1927         (pkgManifest::GetSysRootReference): New public method; declare it.
1928         (pkgManifest::GetRoot): New inline method; declare and implement it.
1929         (pkgManifest::DetachSysRoot): Argument type changed to const char*.
1930         (pkgRemove): New extern "C" function; declare it.
1931
1932         * src/pkgexec.cpp (pkgActionItem::SetPrimary): Implement it, and...
1933         (pkgXmlDocument::Schedule): ...use it to promote actions on all user
1934         specified packages, as listed on the command line, to primary status.
1935         (pkgActionItem::Execute): Repeatedly invoke...
1936         (pkgActionItem::SetAuthorities): ...this; incorporate call of...
1937         (pkgActionItem::DownloadArchiveFiles): ...this, within the loop, so
1938         that we retry failed downloads at least a second time.
1939         [ACTION_REMOVE]: Delete stub; invoke pkgRemove().
1940
1941         * src/pkgunst.cpp: New file.
1942         (pkgActionItem::SetAuthorities): Implement it.
1943         (pkgManifest::GetSysRootReference): Implement it.
1944         (pkgManifest::DetachSysRoot): Implement it per new declaration.
1945         (pkgRemove): Implement it.
1946
1947         * Makefile.in (CORE_DLL_OBJECTS): Add pkgunst.OBJEXT
1948
1949 2011-02-26  Keith Marshall  <keithmarshall@users.sourceforge.net>
1950
1951         Work-around for improper stderr buffering in MSYS mintty and rxvt.
1952         (Merged from r0-1-alpha-5 branch).
1953
1954         * src/dmh.cpp (dmhTypeTTY::emit_and_flush): New private method.
1955         (dmhTypeTTY::printf, dmhTypeTTY::notify): Use it to force an fflush()
1956         after each output record is written to stderr.
1957
1958         * README: Update as appropriate.
1959
1960 2011-02-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
1961
1962         Tidy up some debugging hooks.
1963
1964         * src/debug.h (DEBUG_INVOKED): New macro; define it.
1965         (DEBUG_INVOKE_IF): Likewise; this takes arguments providing for
1966         conditional invocation of code when DEBUGLEVEL is non-zero; make it
1967         expand to nothing, when DEBUGLEVEL is zero.
1968         (DEBUG_TRACE_INIT): Redefined macro; value changed to 0x0010.
1969         (DEBUG_TRACE_TRANSACTIONS, DEBUG_SUPPRESS_INSTALLATION):
1970         (DEBUG_UPDATE_INVENTORY): New macros; define them.
1971
1972         * src/tarproc.cpp (pkgTarArchiveInstaller::ProcessDirectory):
1973         (pkgTarArchiveInstaller::ProcessDataStream): Refactor debugging hooks;
1974         implement them in terms of DEBUGLEVEL, with reference to...
1975         (DEBUG_SUPPRESS_INSTALLATION, DEBUG_UPDATE_INVENTORY): ...these.
1976
1977 2011-02-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
1978
1979         Make package version comparisons more robust.
1980
1981         Fixes an issue reported by Chris Sutcliffe: previously, version
1982         comparisons were evaluated solely on the basis of differences in the
1983         package version field itself.  Henceforth, if this field compares as
1984         equal, then the comparison is extended to also consider differences
1985         between development phase qualifiers, and, if these too compare as
1986         equal, to differences in the target subsystem version fields.
1987
1988         * src/pkginfo/pkginfo.h (pkgSpecs::VersionComparator): New private
1989         method; declare it.
1990
1991         * src/pkgspec.cpp (pkgSpecs::VersionComparator): Implement it.
1992         (pkgSpecs::operator<, pkgSpecs::operator<=, pkgSpecs::operator>=):
1993         (pkgSpecs::operator>): Use it, replacing...
1994         (version): ...this static function; now unreferenced; delete it.
1995
1996         * src/vercmp.h (pkgVersionInfo::pkgVersionInfo): Make it inline; it
1997         now delegates the entire class construction operation to...
1998         (pkgVersionInfo::Parse): ...this new private method; declare it.  This
1999         is also used to facilitate implementation of...
2000         (pkgVersionInfo::Reset): ...this new inline method, also requiring...
2001         (pkgVersionInfo::FreeAll): ...this new inline method; also now used by
2002         the class destructor, it encapsulates separate calls to...
2003         (pkgVersionInfo::Free): ...this original inline method, renamed...
2004         (pkgVersionInfo::FreeEntry): ...as this.
2005
2006         * src/vercmp.cpp (pkgVersionInfo::Parse): Implement it.
2007
2008 2011-02-13  Keith Marshall  <keithmarshall@users.sourceforge.net>
2009
2010         Merge from mingw-get-0.1-mingw32-alpha-5 bug-fix branch.
2011
2012         * src/pkgdeps.cpp (pkgXmlDocument::ResolveDependencies): Promote
2013         "install" action on new prerequisites, where a previously uninstalled
2014         package is required to satisfy any "upgrade" dependency.
2015
2016         * src/pkgexec.cpp (pkgActionList::Execute): Don't make misleading
2017         claims concerning package removal.
2018
2019         * src/pkgtask.h (STRICTLY_GT, STRICTLY_LT, ACTION_PRIMARY): Add one
2020         level of parentheses around defining expressions.
2021
2022 2011-02-10  Keith Marshall  <keithmarshall@users.sourceforge.net>
2023
2024         Publish mingw-get-0.0-mingw32-alpha-5.1 bug-fix release.
2025
2026         * README: Updated to reflect changes.
2027
2028 2011-02-08  Keith Marshall  <keithmarshall@users.sourceforge.net>
2029
2030         Improve diagnostics for failed GUI invocation.
2031
2032         * src/guimain.cpp: New file; currently delivers only a diagnostic
2033         stub, provided by Sze Howe Koh <axfangli@users.sourceforge.net>, to
2034         pop-up a message block explaining why GUI mode cannot be invoked.
2035
2036         * Makefile.in (GUI_LDFLAGS): New macro; it is required by...
2037         (gui$EXEEXT): ...this new build rule; add to prerequisites of...
2038         (all): ...this [default] build rule; redefine this in terms of...
2039         (BIN_PROGRAMS, LIBEXEC_PROGRAMS, LIBEXEC_DATA): ...these new macros;
2040         define them, and also use them as loop iterator objectives for...
2041         (install, install_strip): ...these; also schedule them...
2042         (clean): ...for removal by this.
2043
2044         * src/clistub.c (Copyright): Add new year.
2045         (main): Amend error message, if gui$EXEEXT doesn't start; make it
2046         more intelligible to normal users.
2047
2048 2011-02-07  Keith Marshall  <keithmarshall@users.sourceforge.net>
2049
2050         Correct omissions from packaged source tarball.
2051
2052         * Makefile.in (Copyright): Add new year.
2053         (SRCDIST_FILES): Add aclocal.m4
2054         (SRCDIST_SUBDIRS): Add m4
2055
2056 2011-01-05  Keith Marshall  <keithmarshall@users.sourceforge.net>
2057
2058         Reduce path names to base names, in some diagnostic message contexts.
2059
2060         * src/climain.cpp: Update copyright notice for new year.
2061         (climain): Extract base name from argv[0], to pass as program name tag
2062         in initialisation of diagnostic message handler.
2063
2064         * src/dmh.h, src/dmh.cpp: Update copyright notices; make some layout
2065         adjustments, for more consistent formatting style.
2066
2067         * src/pkgbind.cpp: Update copyright notice.
2068         (pkgRepository::GetPackageList): Reduce path names for catalogue files
2069         to their base names, when reporting them in diagnostic messages.
2070
2071 2011-01-05  Keith Marshall  <keithmarshall@users.sourceforge.net>
2072
2073         Avoid a potential out-of-range action name look-up.
2074
2075         * src/pkgdeps.cpp: Update copyright notice for new year.
2076         (pkgXmlDocument::Schedule): Mask action code with ACTION_MASK, to
2077         determine correct action name when diagnosing uninstalled package.
2078
2079 2011-01-03  Keith Marshall  <keithmarshall@users.sourceforge.net>
2080
2081         Make "install" and "remove" notifications symmetric.
2082
2083         * configure.ac (AC_INIT): Bump version to "0.1-alpha-6cvs".
2084         (YEARS_OF_ISSUE): Add new year.
2085         
2086         * src/pkginst.cpp: Update copyright notice for new year.
2087         (pkgInstall): Add notification for package being installed.
2088
2089 2010-12-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
2090
2091         Add preliminary CLI support for "list" and "show" actions.
2092
2093         * src/pkgtask.h (ACTION_PRIMARY): New manifest constant; define it.
2094         (ACTION_LIST, ACTION_SHOW): Likewise; cast to enumerated values for...
2095         (action_list, action_show): ...these; define them.
2096
2097         * src/pkgexec.cpp (action_name): Add defining text for...
2098         (action_list, action_show): ...these.
2099
2100         * src/climain.cpp: Partially revert 2010-11-01 change...
2101         (climain) [! ACTION_UPDATE]: Reinstate original "if" block, moving
2102         the "switch" block within it, but without the ACTION_UPDATE case.
2103         [ACTION_LIST, ACTION_SHOW]: New "switch" cases; they invoke...
2104         (pkgXmlDocument::DisplayPackageInfo): ...this new method.
2105
2106         * src/pkgbase.h (pkgXmlDocument::DisplayPackageInfo): Declare it.
2107         (pkgActionItem::ConfirmInstallationStatus): New method; declare it.
2108         (pkgXmlNode::GetSysRoot): Make declaration style consistent with
2109         others in the class; do not name arguments in the declaration.
2110         (pkgXmlNode::FindFirstAssociate): Likewise.
2111         (pkgXmlNode::FindNextAssociate): Likewise.
2112
2113         * src/pkgshow.cpp: New file.
2114         (pkgXmlDocument::DisplayPackageInfo): Implement it.
2115
2116         * src/pkgdeps.cpp (pkgMsgUnknownPackage): New extern "C" function;
2117         implement it temporarily, pending a future i18n reimplementation.
2118         (assert_installed): Drop "inline" attribute; leave it as "static".
2119         Set "tarname" correctly, to match the installed package version; (it
2120         previously incorrectly returned the latest available version).
2121         (pkgActionItem::ConfirmInstallationStatus): Implement it.
2122         (pkgXmlDocument::Schedule) [ACTION_PRIMARY]: Set as appropriate.
2123         (pkgXmlDocument::Schedule) [ACTION_REMOVE || ACTION_UPGRADE]: Complain
2124         if requested package is not recorded as having been installed.
2125         (pkgXmlDocument::ResolveDependencies) [! ACTION_INSTALL]: Do not
2126         invoke it recursively.
2127
2128         * Makefile.in (pkgshow.$OBJEXT): Add reference.
2129
2130 2010-11-01  Keith Marshall  <keithmarshall@users.sourceforge.net>
2131
2132         Lay groundwork for implentation of additional actions.
2133
2134         * src/climain.cpp (climain): Adjust indentation; replace `if' block...
2135         [action != ACTION_UPDATE]: ...with this default `switch' case, and...
2136         [action == ACTION_UPDATE]: ...this as explicit "do nothing" case.
2137
2138 2010-10-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
2139
2140         mingw-get-0.1-mingw32-alpha-5 released.
2141
2142         * configure.ac (AC_INIT): Bump version to 0.1-alpha-5.
2143         * README: Update release notes accordingly.
2144         * All files (r0-1-alpha-5): Tag assigned.
2145
2146 2010-10-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
2147
2148         Make pkgInitRites/pkgLastRites processing more robust;
2149         avoid a potential race condition in mingw-get-inst.
2150
2151         * src/rites.c: Refactor conditional code to segregate execution of...
2152         [defined IMPLEMENT_INITIATION_RITES]: ...this into distinct phases.
2153         (PHASE_ONE_RITES, PHASE_TWO_RITES): Define constants to identify them.
2154         (do_init_rites): Renamed to...
2155         (invoke_rites): ...this; inline it.
2156         (pkgLastRites): Invoke it, to pre-empt rename action of...
2157         (lastrites.exe): ...this, subsequently exec()ed process.
2158         (perror): Issue more informative diagnostic on exec() failure.
2159
2160         * src/clistub.c (IMPLEMENT_INITIATION_RITES): Stipulate as...
2161         (PHASE_ONE_RITES): ...this phase of implementation only.
2162
2163         * src/pkgexec.cpp (IMPLEMENT_INITIATION_RITES): Define to provide...
2164         (PHASE_TWO_RITES): ...this phase of implementation, facilitated by...
2165         (self_upgrade_rites): ...this locally defined RITES_INLINE function.
2166         (pkgActionItem::Execute): Invoke it, in remove/install loop, while...
2167         [init_rites_pending]: ...new loop local variable remains true.
2168
2169 2010-09-10  Charles Wilson  <mingw@cwilson.fastmail.fm>
2170
2171         Fix packaging bug in -lic package.
2172
2173         * Makefile.in (licdist): Use directory named
2174         "share", not "shared".
2175
2176 2010-09-10  Charles Wilson  <mingw@cwilson.fastmail.fm>
2177
2178         mingw-get-0.1-mingw32-alpha-4 released.
2179
2180         * All files (r0-1-alpha-4): Tag assigned.
2181
2182 2010-09-10  Charles Wilson  <mingw@cwilson.fastmail.fm>
2183
2184         Add rudimentary help option.
2185
2186         * README: Update release notes.
2187
2188         * src/clistub.c: Add --help option.
2189
2190 2010-09-10  Charles Wilson  <mingw@cwilson.fastmail.fm>
2191
2192         Fix "mingw-get deletes itself" bug in last rites handling.
2193
2194         * README: Add new release notes.
2195
2196         * configure.ac: Bump version to 0.1-alpha-4.
2197
2198         * src/dmh.h: If __cplusplus, include <exception> and
2199         declare dmh_exception class.
2200
2201         * src/dmh.cpp (class dmh_exception): Implement.
2202         (abort_if_fatal): If DMH_FATAL, throw dmh_exception rather
2203         than calling exit().
2204
2205         * src/climain.cpp (climain): Wrap entire function body in try/
2206         catch block. If dmh_exception is caught, return EXIT_FAILURE.
2207
2208         * src/clistub.c (main): Capture return value of climain(). If
2209         non-zero, perform last rites and return EXIT_FAILURE.
2210
2211 2010-08-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
2212
2213         mingw-get-0.1-mingw32-alpha-3 released.
2214
2215         * README: Add new release notes.
2216
2217         * All files (r0-1-alpha-3): Tag assigned.
2218
2219 2010-08-27  Keith Marshall  <keithmarshall@users.sourceforge.net>
2220
2221         Add runtime hooks to support self-upgrade for future releases.
2222
2223         * src/rites.c: New file; compile it free-standing, to provide...
2224         (lastrites.exe): ...this helper application for context clean-up;
2225         alternatively, use it as an include file, with pre-definition of...
2226         (IMPLEMENT_INITIATION_RITES): ...this, to implement...
2227         (pkgInitRites, pkgLastRites): ...these inline functions.
2228
2229         * src/clistub.c (main) [argc > 1]: Use them.
2230         (progname): New local variable within `main'; set it once, then use it
2231         instead of repeated references to `basename(*argv)' in diagnostics.
2232         (MINGW_GET_DLL, MINGW_GET_GUI): Relocate to `src/rites.c'.
2233
2234         * src/debug.h (DEBUG_INHIBIT_RITES_OF_PASSAGE):
2235         (DEBUG_FAIL_FILE_RENAME_RITE, DEBUG_FAIL_FILE_UNLINK_RITE): New
2236         defines; they facilitate debugging of the src/rites.c code.
2237
2238         * Makefile.in (lastrites$EXEEXT): New target; build as prerequisite...
2239         (all): ...of this primary target.
2240         (install, install-strip): Install it.
2241         (SRCDIST_FILES): Remove install-sh; it is now included in...
2242         (build-aux): ...this directory; add it to...
2243         (SRCDIST_SUBDIRS): ...this.
2244
2245 2010-08-24  Keith Marshall  <keithmarshall@users.sourceforge.net>
2246
2247         Set default sysroots relative to mingw-get installation directory.
2248
2249         * xml/profile.xml (system-map) [name == default]: For each of...
2250         [subsystem == mingw32]: ...set sysroot path to value of %R macro...
2251         [subsystem == msys]: ...and to its %R/msys/1.0 subdirectory.
2252
2253 2010-08-19  Keith Marshall  <keithmarshall@users.sourceforge.net>
2254
2255         Some dependency resolver enhancements and bug fixes.
2256
2257         * src/pkgbase.h (pkgXmlNode::GetContainerAttribute): New method;
2258         declare it.
2259
2260         * src/pkgdeps.cpp (pkgXmlNode::GetContainerAttribute): Implement it;
2261         it is used to retrieve package name attributes from the containing
2262         'package' element, when given a pointer to a 'release' element by...
2263         (assert_unmatched, assert_installed): ...these new static functions.
2264         (pkgXmlDocument::Schedule): Use them to reconstruct and register
2265         dependency reference data for previously installed packages which are
2266         no longer included in the distribution manifest.
2267         (pkgXmlDocument::ResolveDependencies): Fix a block nesting error;
2268         catch and diagnose unresolved dependencies; don't look beyond the XML
2269         document root node, (tinyxml error not caught?), when searching for
2270         requirements specified on container nodes.
2271
2272 2010-08-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
2273
2274         Improve scheduling of package processing requests.
2275
2276         * src/pkgexec.cpp (pkgXmlDocument::Schedule): Inspect entire `actions'
2277         list, when checking for duplicate package processing requests; decline
2278         to schedule any such duplicate, or any request which lacks a package
2279         association.
2280
2281 2010-08-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
2282
2283         Lay foundation for selective compilation of debugging code.
2284
2285         * src/debug.h: New file...
2286         * src/sysroot.cpp: Include it.
2287         (pkgXmlDocument::LoadSystemMap): Make debugging output conditional...
2288         [DEBUGLEVEL & DEBUG_TRACE_INIT]: ...on this new debugging state.
2289
2290 2010-08-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
2291
2292         * src/pkgkeys.h: Typo in comment: file was previously identified as
2293         pkgkeys.c; corrected.
2294
2295 2010-08-13  Keith Marshall  <keithmarshall@users.sourceforge.net>
2296
2297         Improve diagnostics for invalid references to non-release XML nodes.
2298
2299         * src/pkgkeys.h (value_unknown): New global string; declare it.
2300         * src/pkgkeys.c (value_unknown): Implement it.
2301
2302         * src/pkgname.cpp (pkgArchiveName): Identify XML element type when
2303         diagnosing references to elements of types other than release; use...
2304         (value_unknown): ...this, as appropriate.
2305
2306 2010-08-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
2307
2308         Guard against a potential buffer overrun.
2309
2310         * src/pkgreqs.cpp (pkgSpecs::SetProperty): Allocate an additional
2311         byte to accommodate an extra field separator, when inserting a new
2312         data value into a previously empty field.
2313
2314 2010-07-27  Cesar Strauss  <cestrauss@gmail.com>
2315
2316         Handle the GNU long name tar header format.
2317
2318         * src/pkgproc.h (TAR_ENTITY_TYPE_GNU_LONGNAME): New manifest constant;
2319         define it.
2320         (pkgTarArchiveProcessor::EntityDataAsString): New protected method;
2321         declare and...
2322         * src/tarproc.cpp: ...implement it.
2323         (pkgTarArchiveProcessor::Process): Before building the entry pathname,
2324         check for a GNU long name type header; when found, read pathname from
2325         the entry data area, before fetching the following header, from which
2326         to retrieve the associated entity data.
2327
2328 2010-06-24  Keith Marshall  <keithmarshall@users.sourceforge.net>
2329
2330         Work around an autoconf bug (reported by Stefano Sabatini).
2331
2332         * Makefile.in (VPATH): Use @top_srcdir@ instead of ${srcdir}; current
2333         autoconf incorrectly elides references to @srcdir@ and ${srcdir} when
2334         substituting within a VPATH specification for building `in-source'.
2335         Also, prefer colons to blanks as path name separators, for improved
2336         portability to non-GNU implementations of make; (recommendation by
2337         Ralf Wildenhues).
2338
2339 2010-06-24  Keith Marshall  <keithmarshall@users.sourceforge.net>
2340
2341         Include alias search, when matching component package name.
2342
2343         * src/keyword.c (has_keyword): Rearrange argument declarations for
2344         more natural order; update all callers accordingly.  Simplify; compare
2345         keyword to be matched with each successive candidate from match-list,
2346         character-by-character and in-place, so avoiding memory allocation
2347         for any local duplicate of the passed match-list; thus...
2348         (safe_strdup): ...this static function no longer required; delete it.
2349         (string.h): No references remain; do not include it.
2350
2351         * src/pkgfind.cpp (pkgXmlNode::FindPackageByName): Augment component
2352         package name matching to include potential matches of the look-up name
2353         with trailing component name stripped off, when that matches the class
2354         name of an identified component package, and the initial substring of
2355         the look-up name, after stripping, matches any specified alias name
2356         for the containing package.
2357
2358 2010-06-10  Keith Marshall  <keithmarshall@users.sourceforge.net>
2359
2360         Address FIXME relating to identification of distributable files.
2361
2362         * install-sh: Move to...
2363         * build-aux: ...this new directory.
2364
2365         * Makefile.in (PACKAGE_DISTVERSION): Modify `sed' edit sequence; make
2366         it depend on, and ensure that it incorporates the expansion of...
2367         (PACKAGE_SUBSYSTEM): ...this new macro; defined as substitution of...
2368         (host_os): ...this autoconf variable, set by...
2369
2370         * configure.ac (AC_CANONICAL_HOST): ...this; add it, requiring...
2371         (AC_CONFIG_AUX_DIR): ...`build-aux' directory reference, providing...
2372
2373         * build-aux/config.guess, build-aux/config.sub: ...these new standard
2374         files; import them from the standard `build-aux' repository.
2375
2376 2010-05-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
2377
2378         Bump version for next release cycle.
2379
2380         * configure.ac (AC_INIT): Bump version suffix to alpha-3.
2381
2382 2010-05-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
2383
2384         mingw-get-0.1-mingw32-alpha-2 released.
2385
2386         * README: Add new release notes.
2387
2388         * xml/profile.xml: Update to use default referencing for...
2389         (package-list.xml.lzma): ...this repository master catalogue.
2390
2391         * All files (r0-1-alpha-2): Tag assigned.
2392
2393 2010-05-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
2394
2395         Make provision to protect user's profile settings during upgrade.
2396
2397         * Makefile.in (install): Remove `profile.xml'; replace it with...
2398         (install-profile): ...this new prerequisite installation goal; it
2399         renames the installed copy of `profile.xml' as `defaults.xml', within
2400         the installed package image.
2401
2402         * src/pkgkeys.h (defaults_key): New key; declare it.
2403         * src/pkgkeys.c: Some cosmetic formatting (tabulation) adjustments.
2404         (defaults_key): Implement it; it refers to the `defaults.xml' file.
2405
2406         * src/climain.cpp (climain): Check `profile_key' for accessibility of
2407         the `profile.xml' file; if [! R_OK] emit a diagnostic warning, fall
2408         back on `defaults_key', and attempt to load configuration from the
2409         distributed `defaults.xml' file.
2410
2411 2010-05-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
2412
2413         Add preliminary support for future `-reinstall' option.
2414
2415         * src/pkgexec.cpp (pkgActionItem::Execute) [ACTION_INSTALL]: Force
2416         installation if `-reinstall' option is selected, overriding state of
2417         any prior installation; temporarily assume that this option is always
2418         selected, to permit proper `upgrade' operation in the absence of any
2419         functional `uninstall' capability, and pending implementation of a
2420         mechanism for interpreting user specified options.
2421
2422 2010-05-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
2423
2424         Correct handling for "%R" macro in relative sysroot path specs.
2425
2426         * src/tarproc.cpp (pkgTarArchiveProcessor): In constructor, expand the
2427         sysroot path specification a second time, to capture the effect of any
2428         embedded macros, before computing the recorded `sysroot_len' value.
2429
2430 2010-05-05  Keith Marshall  <keithmarshall@users.sourceforge.net>
2431
2432         Handle "%" wildcard matches in package and subsystem version strings.
2433
2434         * src/pkgbase.h (pkgSpecs): Forward declare it.
2435         (pkgActionItem::~pkgActionItem): Declare explicit destructor.
2436         (pkgActionItem::SetRequirements): Add extra `pkgSpecs*' argument;
2437         update references, passing additional argument in...
2438
2439         * src/pkgdeps.cpp (pkgXmlDocument::ResolveDependencies): ...this.
2440
2441         * src/pkgexec.cpp (pkgActionItem::~pkgActionItem): Implement it.
2442         (pkgActionItem::SetRequirements): Delete obsolete implementation.
2443
2444         * src/pkginfo/pkginfo.h: Update copyright notice; add year 2010.
2445         (pkgSpecs::GetTarName): New public method; declare it.
2446         (pkgSpecs::SetProperty): New private method; declare it.
2447         (pkgSpecs::SetPackageName): New inline method; implement it.
2448         (pkgSpecs::SetPackageVersion, pkgSpecs::SetPackageBuild): Likewise.
2449         (pkgSpecs::SetSubSystemName, pkgSpecs::SetSubSystemVersion): Likewise.
2450         (pkgSpecs::SetSubSystemBuild, pkgSpecs::SetReleaseStatus): Likewise.
2451         (pkgSpecs::SetReleaseIndex, pkgSpecs::SetComponentClass): Likewise.
2452         (pkgSpecs::SetComponentVersion, pkgSpecs::SetPackageFormat): Likewise.
2453         (pkgSpecs::SetCompressionType): Likewise.
2454
2455         * src/pkginfo/pkginfo.l: Update copyright notice; add year 2010.
2456         (TRANS): Interpret "%" as wildcard in version string matches.
2457
2458         * src/pkgreqs.cpp: New file.
2459         (pkgActionItem::SetRequirements): Reimplement per new declaration;
2460         it now always allocates heap memory for requirements specifications.
2461         (pkgSpecs::GetTarName, pkgSpecs::SetProperty): Implement them.
2462
2463         * Makefile.in (CORE_DLL_OBJECTS): Add `pkgreqs.$(OBJEXT)'.
2464
2465 2010-04-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
2466
2467         Revert 2010-04-04 refactoring of tarproc.cpp and tarinst.cpp
2468
2469         * src/tarinst.cpp: File removed; its content merged into...
2470         * src/tarproc.cpp: ...this; it cannot be cleanly separated out.
2471
2472         * Makefile.in (tarinst.$OBJEXT): Remove reference.
2473
2474 2010-04-29  Keith Marshall  <keithmarshall@users.sourceforge.net>
2475
2476         Handle "*" wildcard matches in package and subsystem version strings.
2477
2478         * src/vercmp.h (pkgVersionInfo::version_string): New private member
2479         variable; it stores a pointer to a dynamically allocated local copy of
2480         the invariant `version' argument, to facilitate correct parsing.
2481         (pkgVersionInfo::build_string): Likewise; it provides similar handling
2482         for the invariant `build' argument.
2483         (pkgVersionInfo::Free): New private inline method; it provides a NULL
2484         pointer safe wrapper, calling the C library `free()' function, (since
2485         some implementations are believed to be unsafe); it is used by...
2486         (pkgVersionInfo::~pkgVersionInfo): ...this new inline destructor, to
2487         release the memory allocated by the constructor, for `version_string'
2488         and `build_string'.
2489
2490         * src/vercmp.cpp (pkgVersionInfo::pkgVersionInfo): Allocate memory for
2491         `version_string' and `build_string', as required; populate it.
2492         Explicitly handle "*" as a `match anything' wildcard...
2493         (pkgVersionInfo::Compare): ...matching it as `equal' to everything.
2494
2495 2010-04-18  Keith Marshall  <keithmarshall@users.sourceforge.net>
2496
2497         Correct omission from configure script prerequisite checks.
2498
2499         * aclocal.m4 (MINGW_AC_OUTPUT): New macro; it wraps AC_OUTPUT itself,
2500         adding a trap to force an abort if any preceding prerequisite check
2501         was handled by MINGW_AC_ASSERT_MISSING.
2502
2503         * configure.ac: Qualify package component types, in prerequisite
2504         checks handled by MINGW_AC_ASSERT_MISSING; invoke MINGW_AC_OUTPUT
2505         in place of AC_OUTPUT.
2506
2507 2010-04-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
2508
2509         Add configure script checks for prerequisite library headers.
2510         (Thanks to Cesar Strauss for proposing a rudimentary implementation).
2511
2512         * aclocal.m4: New file; it does no more than include...
2513         * m4/missing.m4: ...this; new file incorporated from build-aux module.
2514
2515         * configure.ac: Add AC_CHECK_HEADER assertions for...
2516         (zlib.h, bzlib.h, lzma.h): ...these; invoke MINGW_AC_ASSERT_MISSING in
2517         respect of each failing assertion.
2518
2519 2010-04-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
2520
2521         Case-insensitive subsystem name matching revisited.
2522
2523         * src/pkgfind.cpp (pkgXmlDocument::FindPackageByName): Use...
2524         (subsystem_strcmp): ...this to match subsystem names, instead of...
2525         (match_if_explicit): ...this.
2526
2527 2010-04-15  Keith Marshall  <keithmarshall@users.sourceforge.net>
2528
2529         Enable recursive processing of repository package lists.
2530
2531         * src/pkgbase.h (pkgXmlDocument::SyncRepository): Make it public.
2532
2533         * src/pkgbind.cpp (pkgRepository): New locally defined and implemented
2534         class; it facilitates recursive loading and parsing of package lists,
2535         replacing much of the original non-recursive functionality within...
2536         (pkgXmlDocument::BindRepositories): ...this; use it.
2537
2538 2010-04-04  Keith Marshall  <keithmarshall@users.sourceforge.net>
2539
2540         Implement installer function; use per-package file manifests.
2541
2542         * src/pkgproc.h (pkgManifest): New class; declare it.
2543         (pkgArchiveProcessor::origin): New protected member variable.
2544         (pkgArchiveProcessor::sysroot_len): New protected member variable.
2545         (pkgArchiveProcessor::installed): Type changed to `pkgManifest *'.
2546         (pkgTarArchiveInstaller::Process): Declare specialisation hook.
2547         (pkgTarArchiveInstaller::UpdateInstallationManifest): Disused member
2548         function; remove redundant declaration from class definition.
2549         (pkgInstall): New generalised installation function; declare it.
2550         (pkgRegister): New function; declare it.
2551
2552         * src/pkginst.cpp: New file.
2553         (pkgManifest, pkgInstall, pkgRegister): Implement them.
2554
2555         * src/pkgexec.cpp (pkgActionItem::Execute): Use `pkgInstall' in place
2556         of stub formerly provided here.
2557
2558         * src/pkgkeys.h (manifest_key, reference_key): New keys; declare them.
2559         * src/pkgkeys.c (manifest_key, reference_key): Implement them.
2560
2561         * src/tarproc.cpp: Code refactored.
2562         (pkgTarArchiveProcessor::sysroot_len): Initialise it.
2563         (pkgTarArchiveProcessor::origin): Initialise it.
2564         (pkgTarArchiveProcessor::installed): Initialise; associate it with a
2565         pkgManifest class entity, and populate this as appropriate.
2566         (pkgTarArchiveProcessor::~pkgTarArchiveProcessor): Add explicit clean
2567         up of linked `pkgManifest *' entity referenced by `installed'.
2568         (pkgTarArchiveProcessor::Process) [TAR_ENTITY_TYPE_DIRECTORY]: Add
2569         braces to demarcate localised inner scope of string scan for removal
2570         of trailing directory name separators; (thanks to Cesar Strauss for
2571         reporting invalid local pointer declaration error in GCC >= 4.4).
2572         (pkgTarArchiveInstaller::UpdateInstallationManifest): Deleted.
2573         (pkgTarArchiveInstaller::pkgTarArchiveInstaller): Factor out.
2574         (pkgTarArchiveInstaller::ProcessDirectory): Likewise.
2575         (pkgTarArchiveInstaller::ProcessDataStream): Likewise.
2576         (commit_saved_entity): Likewise.
2577
2578         * src/tarinst.cpp: New file; it implements...
2579         (pkgTarArchiveInstaller::Process): ...this new specialisation
2580         of the original pkgTarArchiveProcessor::Process method...
2581         (pkgTarArchiveInstaller::pkgTarArchiveInstaller): ...and this
2582         refactored code, abstracted from src/tarproc.cpp and modified to
2583         use the pkgManifest class for installation tracking.
2584         (pkgTarArchiveInstaller::ProcessDirectory): Likewise.
2585         (pkgTarArchiveInstaller::ProcessDataStream): Likewise.
2586         (commit_saved_entity): Relocated from src/tarproc.cpp.
2587
2588         * Makefile.in (CORE_DLL_OBJECTS): Add...
2589         (pkginst.OBJEXT, tarinst.OBJEXT): ...these new object files.
2590
2591 2010-03-31  Keith Marshall  <keithmarshall@users.sourceforge.net>
2592
2593         Guard against NULL pointer dereferences in tinyxml code.
2594
2595         * src/pkgbase.h (pkgXmlNode::GetName): Verify `this' pointer is
2596         non-NULL, before invoking the underlying tinyxml method.
2597         (pkgXmlNode::GetParent, pkgXmlNode::GetChildren): Likewise.
2598         (pkgXmlNode::GetNext, pkgXmlNode::GetPropVal): Likewise.
2599         (pkgXmlNode::AddChild, pkgXmlNode::DeleteChild): Likewise.
2600         (pkgXmlNode::GetDocumentRoot): Likewise.
2601         (pkgXmlNode::IsElementOfType): Likewise.
2602
2603 2010-03-28  Cesar Strauss  <cestrauss@gmail.com>
2604
2605         Avoid running InternetAttemptConnect in pkgInternetAgent
2606         constructor, since it is called during DLL initialisation.
2607
2608         * src/pkginet.cpp (pkgInternetAgent::pkgInternetAgent): Move the
2609         InternetAttemptConnect call from constructor...
2610         (pkgInternetAgent::OpenURL): ...to here.
2611
2612 2010-03-23  Keith Marshall  <keithmarshall@users.sourceforge.net>
2613
2614         Automate object code dependency tracking.
2615
2616         * Makefile.in (DEPFLAGS): New macro; define it.
2617         (%.OBJEXT: %.c, %.OBJEXT: %.cpp): Add dependency generator commands...
2618         (%.d): ...to create these dependency maps; `sinclude' them, and...
2619         (clean): ...remove them.
2620         
2621         * .cvsignore (*.d): Add wild card template to match them.
2622
2623 2010-03-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
2624
2625         Support case insensitive matching for file and subsystem names.
2626
2627         * src/pkgbase.h (safe_strcmp): New inline function; it provides NULL
2628         argument safe comparison of strings, returning the boolean inverse of
2629         the `strcmp' result, using either case-sensitive or case-insensitive
2630         semantics; derive it from...
2631         (match_if_explicit): ...this; redefine as macro; invoke `safe_strcmp'
2632         using explicitly case-sensitive semantics.
2633         (subsystem_strcmp): New macro; it invokes `safe_strcmp' with either
2634         case-sensitive or case-insensitive semantics, depending on...
2635         (CASE_INSENSITIVE_SUBSYSTEMS): ...this new context selection macro; it
2636         fixes the choice between case-sensitive and case-insensitive matching
2637         semantics for any given implementation, at compile time.
2638         (pkg_strcmp): New macro; it invokes `safe_strcmp' with either
2639         case-sensitive or case-insensitive semantics, depending on...
2640         (CASE_INSENSITIVE_FILESYSTEM): ...this new context selection macro; it
2641         fixes the choice between case-sensitive and case-insensitive matching
2642         semantics for any given implementation, at compile time.
2643
2644         * src/sysroot.cpp (pkgXmlNode::GetSysRoot): Use `subsystem_strcmp'.
2645
2646 2010-03-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
2647
2648         Add preliminary support for virtual packages.
2649
2650         * src/pkgkeys.h (yes_value, no_value): Redefine as aliases...
2651         (value_yes, value_no): ...for these new global strings; declare them.
2652         (value_none, value_virtual): New global strings; declare them.
2653
2654         * src/pkgkeys.c (yes_value, no_value): Rename...
2655         (value_yes, value_no): ...to implement these, respectively.
2656         (value_none, value_virtual): Implement them.
2657
2658         * src/pkgname.cpp (pkgXmlNode::ArchiveName): Check containing package
2659         node for `class' attribute set to `value_virtual'; if present, always
2660         return the effective `tarname' property as `value_none'.
2661
2662         * src/pkginet.cpp (pkgActionItem::DownloadArchiveFiles): For packages
2663         with an effective `tarname' of `value_none', do not download anything.
2664
2665         * src/pkgexec.cpp (pkgActionItem::Execute): For packages with an
2666         effective `tarname' of `value_none', do not invoke any tar archive
2667         processing function.
2668
2669 2010-03-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
2670
2671         Don't write installation records for unavailable packages.
2672
2673         * src/tarproc.cpp (pkgTarArchiveInstaller): In constructor, ensure
2674         archive is ready for processing, before initialising an installation
2675         manifest record.
2676
2677 2010-03-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
2678
2679         Rationalise path identification for XML file locations.
2680
2681         * src/sysroot.cpp (pkgXmlDocument::LoadSystemMap): Use `xmlfile()'
2682         function to locate `sysroot' map file; free memory when done.
2683         (pkgXmlDocument::UpdateSystemMap): Likewise.
2684         (sigpath): Static global variable disused; delete it.
2685
2686 2010-03-01  Keith Marshall  <keithmarshall@users.sourceforge.net>
2687
2688         Extend package name search to include component packages.
2689
2690         * src/pkgfind.cpp (pkgHasMatchingName): Remove; fold it into...
2691         (pkgXmlNode::FindPackageByName): ...this; augment to extend search
2692         within package definition elements, seeking a potential match on an
2693         included component package name or component class-implied name.
2694
2695         * src/pkgkeys.h (class_key): New global string constant; declare it.
2696         * src/pkgkeys.c (class_key): Implement it.
2697
2698 2010-02-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
2699
2700         Bump version for next release cycle.
2701
2702         * configure.ac (AC_INIT): Bump version suffix to alpha-2.
2703
2704 2010-02-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
2705
2706         mingw-get-0.1-mingw32-alpha-1 released.
2707
2708 2010-02-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
2709
2710         Prepare initial package release.
2711
2712         * README: New file; use it to source release notes.
2713
2714         * Makefile.in (SRCDIST_FILES): Use ...
2715         (LICENCE_FILES): ...this new macro; define it.
2716         (licdist): New build goal; implement it.
2717         (bindist): Require it; add alternative `zip' format package.
2718
2719         * xml/profile.xml (repository): Set default `package-index' name.
2720         (system-map): Normalise spelling for default `sysroot' path names.
2721
2722 2010-02-10  Keith Marshall  <keithmarshall@users.sourceforge.net>
2723
2724         Add directory/file records in installation manifests.
2725
2726         * src/pkgkeys.h (dirname_key, filename_key): New strings; declare...
2727         * src/pkgkeys.c (dirname_key, filename_key): ...and implement them.
2728
2729         * src/pkgproc.h (pkgArchiveProcessor::installed): New class member
2730         variable; declare it.
2731         (pkgTarArchiveInstaller::UpdateInstallationManifest): New method;
2732         declare it.
2733
2734         * src/tarproc.cpp: Miscellaneous comment updates.
2735         (pkgTarArchiveInstaller): In constructor...
2736         (pkgTarArchiveInstaller::installed): ...use new member variable...
2737         (pkgArchiveProcessor::installed): ...inherited from this.
2738         (pkgTarArchiveInstaller::UpdateInstallationManifest): Implement and...
2739         (pkgTarArchiveInstaller::ProcessDataStream): ...use it.
2740         (pkgTarArchiveInstaller::ProcessDirectory): Likewise.
2741
2742 2010-02-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
2743
2744         Work around a deficiency in Microsoft's stat() implementation.
2745
2746         * src/tarproc.cpp (pkgTarArchiveProcessor::ProcessDirectory): Don't
2747         pass a `pathname' argument with trailing slashes; strip them off.
2748
2749 2010-02-06  Keith Marshall  <keithmarshall@users.sourceforge.net>
2750
2751         Add machinery for installation and packaging for distribution.
2752
2753         * install-sh: New file; source it from autoconf distribution.
2754
2755         * configure.ac (AC_PREFIX_DEFAULT): Assign it as `C:/MinGW'.
2756         (AC_PROG_MKDIR_P, AC_PROG_INSTALL, AC_PROG_LN_S): Invoke these.
2757         (STRIP): New output variable; use AC_CHECK_TOOL to define it.
2758
2759         * Makefile.in (abs_top_srcdir): Define to AC_SUBST value.
2760         (PACKAGE_TARNAME, PACKAGE_VERSION): Define to AC_SUBST values.
2761         (prefix, exec_prefix, bindir, libexecdir, localstatedir): Likewise.
2762         (INSTALL, INSTALL_PROGRAM, INSTALL_SCRIPT, INSTALL_DATA): Likewise.
2763         (STRIP): New macro; define it using AC_CHECK_TOOL substitution.
2764         (mkinstalldirs): New macro; define it as AC_PROG_MKDIR_P result.
2765         (LN_S): New macro; define it as AC_PROG_LN_S result.
2766         (dist, srcdist, bindist): New build objectives; implement them.
2767         (install, installdirs, install-strip, maintainer-clean): Likewise.
2768         (SRCDIST_FILES, SRCDIST_SUBDIRS): New macros; define them.
2769         (PACKAGE_DISTNAME, PACKAGE_DISTVERSION): Likewise.
2770         (PACKAGE_DISTROOT, PACKAGE_ROOTVERSION): Likewise.
2771         (PACKAGE_CONFIG_DIR): Likewise.
2772
2773 2010-02-02  Keith Marshall  <keithmarshall@users.sourceforge.net>
2774
2775         Implement package installer for tar archives.
2776
2777         * src/pkgexec.cpp (pkgXmlDocument::Execute): Replace existing
2778         stub implementation of installer, using methods provided by...
2779         * src/pkgproc.h, src/tarproc.cpp: ...these new files, with trap...
2780         * src/pkgdeps.cpp (pkgXmlDocument::Schedule) [installed]: Add entry...
2781         (pkgActionItem::Selection) [to_remove]: ...for this; use it to detect
2782         `install' requests for packages which are aleady installed.
2783
2784         * Makefile.in (CORE_DLL_OBJECTS): Add tarproc.$(OBJEXT); specify
2785         dependencies as appropriate.
2786
2787         * src/sysroot.cpp (pkgXmlDocument::LoadSystemMap): Don't commit
2788         newly created `sysroot' mapping records to disk; defer to...
2789         (pkgXmlDocument::UpdateSystemMap): ...this new method.
2790         (sigpath): Make it a global variable, with file (static) scope.
2791
2792         * src/climain.cpp (pkgXmlDocument::UpdateSystemMap): Invoke it.
2793
2794         * src/pkgkeys.h (download_key, modified_key, source_key): New global
2795         string variables; declare them, providing their implementations...
2796         * src/pkgkeys.c (download_key, modified_key, source_key): ...here.
2797         * src/pkgname.cpp (download_key, source_key): Use them.
2798
2799         * src/pkginet.cpp (pkgActionItem::ArchivePath): Delete; replace...
2800         * src/mkpath.c (pkgArchivePath): ...with this free standing function.
2801         * src/mkpath.h (pkgArchivePath): Declare its prototype.
2802
2803         * src/pkgbase.h (pkgActionItem::ArchivePath): Delete declaration.
2804         (pkgXmlDocument): Add a default constructor; implement as `inline'.
2805         (pkgXmlDocument::AddDeclaration): Use heap memory to allocate the new
2806         declaration object, instead of `auto' variable, to avoid scope error.
2807         (pkgXmlDocument::UpdateSystemMap): Declare it.
2808
2809 2010-01-26  Keith Marshall  <keithmarshall@users.sourceforge.net>
2810
2811         Implement rudimentary dependency resolver.
2812
2813         * src/pkgdeps.cpp: New file.
2814
2815         * Makefile.in (CORE_DLL_OBJECTS): Add pkgdeps.$(OBJEXT) reference;
2816         establish header file dependencies.
2817
2818         * src/pkgbase.h (to_remove, to_install, selection_types): New enum.
2819         (pkgActionItem::selection): Extend it to store as enumerated pair...
2820         (pkgActionItem::SelectPackage): New inline method; assign them.
2821         (pkgActionItem::Selection): New inline method; retrieve them.
2822         (pkgXmlNode::GetInstallationRecord): New method; declare it.
2823
2824         * src/pkgexec.cpp (pkgActionItem): In constructor...
2825         (selection): ...initialise both references in enumerated pair.
2826         (pkgActionItem::GetReference): Use `Selection()' method.
2827         (pkgActionItem::SelectIfMostRecent): Ditto; also correct logic for
2828         making selection, and assign to `to_install' element.
2829         (pkgXmlDocument::Schedule): Don't update `request'.
2830         (pkgActionItem::Execute): Implement as stub.
2831
2832         * src/pkginet.cpp (pkgActionItem::DownloadArchiveFiles): Use new
2833         `Selection()' method.
2834
2835         * src/pkgkeys.h (yes_value, no_value): Declare new string constants.
2836         * src/pkgkeys.c (yes_value, no_value): Implement them.
2837
2838         * src/vercmp.cpp: Update copyright notice.
2839         (pkgVersionInfo::operator<=): Bug fix; must test for `<', but had `>'.
2840
2841 2010-01-23  Keith Marshall  <keithmarshall@users.sourceforge.net>
2842
2843         Avoid segmentation faults when processing invalid data streams.
2844
2845         * src/pkgstrm.h: Update copyright notice.
2846         (pkgArchiveStream::IsReady): New pure virtual method.
2847         (pkgRawArchiveStream::IsReady): Provide inline implementation.
2848         (pkgGzipArchiveStream::IsReady): Likewise.
2849         (pkgBzipArchiveStream::IsReady): Likewise.
2850         (pkgLzmaArchiveStream::IsReady): Likewise.
2851         (pkgXzArchiveStream::IsReady): Likewise.
2852
2853         * src/pkgstrm.cpp: Update copyright notice.
2854         (pkgLzmaArchiveStream, pkgXzArchiveStream) [fd == -1]: Decline to
2855         perform any form of read or decode processing.
2856
2857         * src/pkginet.cpp (pkgInternetLzmaStreamingAgent): Use `fd = -2' as
2858         pseudo-descriptor for the pkgLzmaArchiveStream derived component of
2859         this internet data streaming class.
2860
2861 2010-01-23  Keith Marshall  <keithmarshall@users.sourceforge.net>
2862
2863         Require liblzma >= liblzma-4.999.9beta_20091209-3-mingw32-dev
2864
2865         * src/pkgstrm.h (LZMA_API_STATIC): Remove definition and associated
2866         comment; it was required to permit, (but not to enforce), linking to
2867         the static liblzma.a library, with earlier beta releases, but this
2868         anomaly has now been corrected.
2869
2870 2010-01-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
2871
2872         Remove zlib sources from trunk.
2873         (Application builders should use free standing implementation of
2874          zlib, from MinGW's package distribution page on SourceForge).
2875
2876 2010-01-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
2877
2878         Remove bzip2 sources from trunk.
2879         (Application builders should use free standing implementation of
2880          bzip2, from MinGW's package distribution page on SourceForge).
2881
2882 2010-01-22  Keith Marshall  <keithmarshall@users.sourceforge.net>
2883
2884         Add subsystem specific sysroot mapping facility.
2885
2886         * src/pkghash.c: New file; required by...
2887         * src/sysroot.cpp: New file; it implements...
2888         (pkgXmlDocument::LoadSystemMap, pkgXmlNode::GetSysRoot): New methods.
2889
2890         * src/pkgbase.h: Update copyright notice.
2891         (pkgXmlDocument::LoadSystemMap): Declare it.
2892         (pkgXmlDocument::AddDeclaration): New inline method.
2893         (pkgXmlDocument::SetRoot, pkgXmlDocument::Save): Likewise.
2894         (pkgXmlNode::GetSysRoot): Declare it.
2895         (pkgXmlNode::GetDocumentRoot): New inline method.
2896         (pkgXmlNode::AddChild, pkgXmlNode::DeleteChild): Likewise.
2897
2898         * src/climain.cpp: Update copyright notice.
2899         (climain): Invoke pkgXmlDocument::LoadSystemMap() as required.
2900
2901         * Makefile.in (CORE_DLL_OBJECTS): Add ...
2902         (pkghash.$(OBJEXT), sysroot.$(OBJEXT)): ...these; upate dependencies.
2903         (DEBUGLEVEL): New macro; define it.
2904         (CPPFLAGS): Use it.
2905
2906 2010-01-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
2907
2908         Assign standardised keys for XML database lookup.
2909
2910         * src/pkgkeys.h: New file; provide public key declarations.
2911         * src/pkgkeys.c: New file; implement them.
2912
2913         * src/pkgbind.cpp: Use them; update copyright notice.
2914         * src/pkgexec.cpp, src/pkgfind.cpp, src/pkginet.cpp: Likewise.
2915         * src/pkgname.cpp, src/pkgspec.cpp: Likewise.
2916
2917         * Makfile.in (CORE_DLL_OBJECTS): Add pkgkeys.$(OBJEXT); update all
2918         dependencies accordingly.
2919
2920 2010-01-08  Keith Marshall  <keithmarshall@users.sourceforge.net>
2921
2922         Add CLI version reporting option.
2923
2924         * configure.ac: Update copyright notice for new year.
2925         (COPYRIGHT_HOLDER): New AC_SUBST variable; define it.
2926         (YEARS_OF_ISSUE): New AC_SUBST variable; define it.
2927         (AC_CONFIG_FILES): Add `version.c'; source it from...
2928
2929         * version.c.in: ...this new file.
2930
2931         * Makefile.in: Update copyright notice for new year.
2932         (mingw-get$(EXEEXT)): Add dependency on `version.$(OBJEXT)'.
2933         (distclean): Add `version.c'.
2934
2935         * configure: Regenerated.
2936
2937         * src/clistub.c: Update copyright notice for new year.
2938         (options): New array of `struct option'; define and use it as the
2939         reference for `argv' parsing with `getopt_long_only()'.
2940
2941 2009-12-17  Keith Marshall  <keithmarshall@users.sourceforge.net>
2942
2943         Add CLI support for "update" action.
2944
2945         * src/pkgtask.h (ACTION_UPDATE): Define it, derived from...
2946         (action_update): ...this new entry in anonymous enumeration.
2947         
2948         * src/pkgexec.cpp (action_name): Add "update" keyword identification.
2949
2950         * src/pkgbase.h: Typo in comment; s/xwXmlDocument/wxXmlDocument/.
2951         (pkgXmlDocument::BindRepositories): Add `force_update' parameter...
2952         * src/pkgbind.cpp (pkgXmlDocument::BindRepositories): Use it to...
2953         (pkgXmlDocument::SyncRepository): ...invoke this method when passed as
2954         a `true' flag, in addition to (as previously) first time reference.
2955
2956         * src/climain.cpp (climain): Interpret "update" keyword for...
2957         [ACTION_UPDATE]: ...passing state as `force_update' parameter to...
2958         (pkgXmlDocument::BindRepositories): ...this method, then...
2959         [!ACTION_UPDATE]: Follow with normal action processing.
2960
2961 2009-12-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
2962
2963         Add status checking for Internet URL connections.
2964
2965         * src/pkginet.cpp (pkgInternetAgent::QueryStatus): New method.
2966         (pkgInternetStreamingAgent::Get): Use it; set `dl_status' as return
2967         value, deferring failure diagnostics to callers, i.e. to...
2968         (pkgXmlDocument::SyncRepositories): ...this, and to...
2969         (pkgActionItem::DownloadArchiveFiles): ...this.
2970
2971 2009-11-23  Keith Marshall  <keithmarshall@users.sourceforge.net>
2972
2973         Add package download and repository synchronisation machinery.
2974
2975         * src/pkgstrm.h: New header file.
2976
2977         * src/pkgbind.cpp, src/pkginet.cpp, src/pkgstrm.cpp,
2978         src/pkgfind.cpp, src/pkgname.cpp, src/keyword.c: New files.
2979         * Makefile.in (CORE_DLL_OBJECTS): Add build goals for them.
2980
2981         * xml: New directory.
2982
2983         * src/climain.cpp (climain): Establish repository bindings from...
2984         * xml/profile.xml: ...this new configuration file.
2985
2986 2009-11-16  Keith Marshall  <keithmarshall@users.sourceforge.net>
2987
2988         Add XML database bindings and preliminary action executive for CLI.
2989
2990         * src/pkgbase.h, src/pkgtask.h,
2991         src/mkpath.h, src/vercmp.h: New header files.
2992
2993         * src/climain.cpp, src/pkgexec.cpp, src/pkgspec.cpp,
2994         src/mkpath.c, src/vercmp.cpp, src/xmlfile.c: New files.
2995
2996         * Makefile.in (CORE_DLL_OBJECTS): Define initial set of files...
2997         (mingw-get-0.dll): ...build them into this new DLL target; add it...
2998         (all): ...as prerequisite for this primary build goal.
2999
3000 2009-11-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
3001
3002         Avoid some potential GCC warnings.
3003
3004         * src/clistub.c: Include process.h for `execv' prototype...
3005         (main): Cast `argv' to appropriately matched type when calling it.
3006
3007         * src/pkginfo/driver.c: Include stdlib.h for `free' prototype.
3008
3009 2009-11-11  Keith Marshall  <keithmarshall@users.sourceforge.net>
3010
3011         Create diagnostic message handler for CLI usage.
3012
3013         * src/dmh.h: New header file; it defines the public interface.
3014         * src/dmh.cpp: New file; it implements the message handler.
3015
3016 2009-11-05  Keith Marshall  <keithmarshall@users.sourceforge.net>
3017
3018         Correct some identified TinyXML issues.
3019
3020         * tinyxml/tinyxml.h (IsWhiteSpace): Add FIXME annotation to flag
3021         probable redundancy of checks for '\n' and '\r'.
3022         * tinyxml/tinyxmlparser.cpp: Revert John E's 2008-08-09 change; remove
3023         all such redundancies in IsWhiteSpace() calls throughout.
3024
3025         * tinyxml/tinyxml.cpp (TiXmlAttribute::SetDoubleValue): Correct format
3026         specification in sprintf()/snprintf() calls; "%lf" is invalid; replace
3027         with "%f".
3028
3029 2009-10-31  Keith Marshall  <keithmarshall@users.sourceforge.net>
3030
3031         Add CLI loader stub.
3032
3033         * src/clistub.c: New file.
3034         * Makefile.in: Add build rule for it; build as...
3035         (mingw-get.exe): ...this; also add to...
3036         (clean): ...this goal.
3037
3038 2009-10-31  Keith Marshall  <keithmarshall@users.sourceforge.net>
3039
3040         Set up build mechanism.
3041
3042         * configure.ac, Makefile.in: New files.
3043         * .cvsignore (configure, autom4te.cache): Add to ignored files.
3044
3045 2009-10-30  Keith Marshall  <keithmarshall@users.sourceforge.net>
3046
3047         Add GPL-v3 licensing terms.
3048
3049         * COPYING: New file, sourced from gnu.org.
3050
3051 2009-10-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
3052
3053         Add pkginfo implementation.
3054
3055         * src, src/pkginfo: New directories.
3056         * src/pkginfo/pkginfo.h, src/pkginfo/pkginfo.l: New files.
3057         * src/pkginfo/driver.c: New file.
3058
3059 2009-10-12  Keith Marshall  <keithmarshall@users.sourceforge.net>
3060
3061         Create tdm-branch.
3062
3063         * All files (tdm-branch): Assign new branch tag.
3064         * All top-level files: Remove from trunk.
3065         * ChangeLog: New file.