diff options
author | Andreas Baumann <abaumann@yahoo.com> | 2011-11-05 10:49:12 +0100 |
---|---|---|
committer | Andreas Baumann <abaumann@yahoo.com> | 2011-11-05 10:49:12 +0100 |
commit | 2e5f2a0fb1d0bdb78d43a86d2f51904a23a6670c (patch) | |
tree | 9306d9e52b7c09f2ea1ad004250c5df57d011931 /docs/i18n/EventSourceGenerator.txt | |
parent | b49b7be5f83fa9c1b511dd305a3868a2a367b939 (diff) | |
download | wolfbones-2e5f2a0fb1d0bdb78d43a86d2f51904a23a6670c.tar.gz wolfbones-2e5f2a0fb1d0bdb78d43a86d2f51904a23a6670c.tar.bz2 |
cleaned up todo lists and i18n documentation
Diffstat (limited to 'docs/i18n/EventSourceGenerator.txt')
-rw-r--r-- | docs/i18n/EventSourceGenerator.txt | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/docs/i18n/EventSourceGenerator.txt b/docs/i18n/EventSourceGenerator.txt new file mode 100644 index 0000000..79e79b2 --- /dev/null +++ b/docs/i18n/EventSourceGenerator.txt @@ -0,0 +1,40 @@ +Idea: +- the master is gettext, a logger and a set of category, message ids in a + header file +- produce an .mc file from it, which can be used in the event logger + application as message/category DLL +- maybe its awk/sed in the beginning + +Links: +- members.tripod.com/~ashimg/Parser.html +- cscope +- mcpp_lib + +we must find all wolf_log calls in a given set of source files (in this case +libwolf.dll), later we also need a merger for at least wolfmsg.mc and app.mc + +foreach call to wolf_log we get: +- wolf level: must be mapped to 'Severity' +- the category_id (is passed in ReportEvent directly, we don't need it to + generate the MC file, also the categories and their names are few and + change not too often, so we hard-code them) +- message_id (we need it here expanded) + - the Severity, the Facility and the message_id form the 'MessageId' +- _( ) format string or message: this is the msgid in gettext and gets + the English version in the MC file +- for each msgid we must search for the msgstr in the corresponding gettext + file and map it to the right language +- The 'SymbolicName' is tricky: we need the define from log/messages.h, + unexpanded + +1) Easy way to find all calls of wolf_log with macros correctly expanded +find . -name '*.c' -exec cat {} \; | mcpp -DLINUX + -DOS_MAJOR_VERSION=2 -DOS_MINOR_VERSION=6 -DENABLE_NLS=1 -I. -I +- /usr/lib/gcc/i686-pc-linux-gnu/4.3.3/include -I../include/wolf | grep +- / wolf_log\( + +2) The logger must map the messageid correcly (masks) + +3) Sort out the problems with message.dll installation and the registry in + the event source + |