Basic info about Module Development Kit (MDK)
MDK is a set of programs for conversion of input text data to binary module files for Davar4.
You need to select MDK in installation. All files will be installed in \mdk\ subfolder of main Davar4 directory.
MDK consists of several programs:
- D4DBK.EXE: Program for creation of book modules (*.dbk), e.g. for Bibles
- D4LEX.EXE: Program for creation of lexicon modules (*.lex). Lexicons are SQLite3 database files and sqlite3.dll must be presented when this program is running.
- D4DIC.EXE: Program for creation of dictionary modules (*.dic). Dictionaries are SQLite3 database files and sqlite3.dll must be presented when this program is running.
- D4DWR.EXE: Program for creation of writings modules (*.dwr). It is quite flexible format, which can be used for book data structure of type book-chapter-verse (Bible), also for lexical data keyed by words, dictionaries, Strong#, gematria, notes and other data. Writings are SQLite3 database files and sqlite3.dll must be presented when this program is running.
- D4DWRTXT.EXE: Program for creation of writings modules (*.dwr) as container for library of texts, presented in one file. For example
Extra Biblical texts or
The Early Church Fathers - library of texts, collected in one module, where texts have no book-chapter-verse structure.
Each of programs needs two text input files. Both must be encoded in UTF-8 encoding and without Byte Order Mark (BOM):
info.txt - text file, where are presented various information about created module. For example description of module, copyright info, language of module, list of used tags and other information.
data.txt - text file where is text of module presented. It can be either plain text or it can contain some extra information in the form of TAGS. For example Strong# H403 is inserted as |RH403|Rh into text.
It is upon creator of module to prepare both text files for conversion. While info.txt is easy to modify from existing modules, preparation of data.txt is more demanding, especially when you want a insert a lot of TAGS.
Recommended tools you can use for work with MDK:
- Plain text editor, able to open big text documents: Notepad++ (freeware) or PSPad (freeware). Both are excellent text editors, able to record macros - this can extremely speed up preparation of texts.
- Multifunctional Unicode Editor BabelPad (freeware) if you plan to work with Hebrew texts or other non Latin languages. BabelPad can perform many text conversions and display and print each Unicode language in selected font. Good for handling of R2L texts.
- If you need to perform some complex conversion (e.g. from text exported from other program), AWK is great and free tool. It is an interpreted programming language designed for text processing and typically used as a data extraction and reporting.
- SQLite3 database tools. Except books, all modules are SQLite3 database files. It means, you can create this files not only by mdk convertors, but also in any database manager. Sometimes you may need to view created database in some viewer. You can use for example this free tools: SQLite Database Browser, SQLite Spy, SQLite Studio and other.
Structure of MDK folder
If you installed MDK (typically in \ProgramData\Davar4\mdk\), you will see following structure:
1. Folders with individual programs and sqlite3.dll where necessary. You can copy appropriate info.txt and data.txt into folder and run exe file to create module.
2. Folders with examples, all files prepared, you need just run exe file:
Example1 - KJV+ as DBK
Example2 - LXX+ as DBK
Example3 - HE-EN dictionary as DIC
Example4 - STRIPD_HE as DWR
Example5 - Imitation of Christ as DWR text
Example6 - Thompson Chain Topics as LEX
3. Specifications of all module files, list of tags, morphology encodings etc...
4. Short readme file
5. Zipped source files for all convertors, written in C. You can compile in any ANSI C compiler. All executables in MDK were compiled in GCC, in Code::Blocks opensource IDE.