initial commit
[rofl0r-KOL.git] / system / readme.txt
blob823cf862eb99b85bbdec0025daf4dad44bda9225
1 XCL - eXtream Class Library - FREEWARE OPEN SOURCE project.\r
2 Idea: by Kladov Vladimir (C) 1999, 2000.\r
3 \r
4 KOL - Key Objects Library - FREEWARE OPEN SOURCE project.\r
5 Idea: by Kladov Vladimir (C) 2000\r
6 \r
7 DELPHI SYSTEM.DCU REPLACEMENT (C) 2000 by Kladov Vladimir\r
8 VERSION 1.1\r
9 \r
10 Part of KOL / XCL technology: \r
11 system.dcu, sysinit.dcu and some other sysxxxxx.dcu (with sources)\r
12 to replace Delphi standard ones and make all XCL (and other Delphi\r
13 non-VCL based) projects even smaller (difference is 6-20K depending\r
14 on project). Dcu's are provided for Delphi5 only, but with sources,\r
15 and You can adjust it for earlier Delphi versions too. \r
17 What is done here (briefly, see also sources - all changes are\r
18 marked with '{X' characters):\r
20 ***  references to console input/output routines (AssignFile, Read, \r
21 Write, etc) removed (it is possible to call UseInputOutput to provide \r
22 it therefore);\r
24 ***  floating point initialization removed (if You want, call manually \r
25 one of FpuInit or FpuInitConsiderNECWindows procedures);\r
27 ***  references to both WriteLn and MessageBox are removed in error \r
28 handling routine. You have to call manually one of UseErrorMessageBox \r
29 or UseErrorMessageWrite procedure to provide it again.\r
31 ***  Variables CmdShow and CmdLine are replaced with same-named \r
32 functions - to allow smart-linking.\r
34 ***  Embedded support of Wide strings, Wide String arrays and Variants \r
35 removed. (It is yet possible to use wide strings/wide string arrays and \r
36 (or) variants by placing reference(s) to units SysWStr and (or) SysVarnt \r
37 units into uses clause of dpr, but with some small restrictions, e.g. it \r
38 is not possible to initialize such variables in dpr itself). And with \r
39 this change, well-know "feature" of linking every Delphi program with \r
40 oleaut.dll is gone.\r
42 ***  Overblotted Delphi memory manager is replaced by very simple one, \r
43 which just calls LocalAlloc, LocalFree, LocalReAlloc. (It is yet possible \r
44 to call UseDelphiMemoryManager to restore it, or to call SetMemoryManager \r
45 to setup your own memory manager).\r
47 ***  Try-except-finally & raise handling support routines removed, \r
48 including steps of units initializations / finalization. (But therefore \r
49 it can be turned on again by adding a reference to SysSfIni unit in uses \r
50 clause of project's dpr file).\r
52 ***  Safe-thread string reference count (and dynamic arrays too) handling \r
53 feature removed (all LOCK prefixes are commented, and there is no way to \r
54 enable this again - except uncommenting it again and recompiling system.pas).\r
56 In result, size of empty project is only 4,5K after compiling. And if some \r
57 ansi string operations are added, size is about 5,5K. For dynamic array of \r
58 strings, size of executable is about 6,5K. And so on.\r
60 *** In version 1.1 (15-Jun-2000):\r
61 [-] System.Move fixed. There are now three versions there for lovers:\r
62     1. Borland's; 2. Small; 3. Fast (the last is turned on).\r
64 [-] SysSfIni.pas usage fixed (changes made in SetExceptionHandler).\r
66 [+] Some declarations moved from SysInit.pas to System.pas to avoid of\r
67     creating second import section from kernel32.dll (thanks to Alexey\r
68     Torgashin).\r
70 [+] ErrorAddr now is not set to nil in _Halt0 (by advice of Alexey \r
71     Torgashin - to allow check ErrorAddr in the rest of finalization\r
72     sections).\r
75 INSTALLATION:\r
77 - DO NOT REPLACE EXISTING FILES with new ones. Place it in any other directory\r
78 where You wish, and add path to it in your project AS FIRST path.\r
79 Provided DCU's are only for DELPHI5 and compiled with -DDEBUG key (so, it\r
80 is possible to step into system.pas, sysinit.pas, getmem.inc and others\r
81 while debugging. If You want to turn debug info off, recompile it as it is said\r
82 below).\r
85 RECOMPILING:\r
87 - If You want to make some changes and recompile units provided, do following:\r
89 1. Backup files in your existing Delphi5\Lib directory (with Delphi5\Lib\Debug\r
90 subdirectory) and make copy of existing system.pas, sysinit.pas, getmem.inc\r
91 (and other which You want to change) - in Delphi5\Source\Rtl\Sys directory.\r
93 2. Place new versions of source files (system.pas, sysinit.pas, getmem.inc,\r
94 syssfini.pas, syswstr.pas, sysvarnt.pas) to your Delphi5\Source\Rtl\Sys\r
95 directory, replacing existing ones.\r
96    Copy existing sysconst.dcu from Delphi5\Lib to Source\Rtl\Lib (this last\r
97 directory must not contain other files before recompiling).\r
99 3. Place provided file named 'makefile' to Delphi5\Source\Rtl directory,\r
100 replacing existing one (You can also rename existing makefile to save it too).\r
102 4. Copy make.exe from Delphi5\Bin to Delphi5\Source\Rtl directory. You can\r
103 open also makefile to read recompiling instructions there.\r
105 5. Open your lovely DOS Shell program (NC, DN, Far, VC, WC, etc.) or command\r
106 line prompt and go to the Delphi5\Source\Rtl directory. Run there make.exe\r
107 with desired parameters, e.g.:\r
109 > make -DDEBUG >1.txt\r
111 or\r
113 > make >2.txt\r
115 6. Go to Delphi5\Source\Rtl\Lib and watch resulting dcu's there. Cut them and\r
116 paste to Delphi5\Lib or Delphi5\Lib\Debug, replacing existing ones.\r
118 7. If Delphi IDE is yet open, close it. (It is better to close it before\r
119 compiling, but it seems no matter - it is just have to be restarted).\r
121 8. Open Delphi again and enjoy.\r
123 TIP: if You plan to make some changes and to test it in standard programming\r
124 cycle - writing-compiling-debugging, make bat-file to perform steps 5-6 more\r
125 easy. Do not forget, that Source\Rtl\Lib must be empty before recompiling,\r
126 but sysconst.dcu.\r
128 =============================================================================\r
129 If You adjust changed files to earlier versions of Delphi, or have found\r
130 some bugs, or could suggest some useful changes, and even if You have\r
131 (unique) opinion about the work, please e-mail me:\r
133 mailto: bonanzas@xcl.cjb.net?subject=system\r
135 Web page: http://xcl.cjb.net\r
137 LET US MAKE OUR DELPHI PROGRAMS SMALL ! (C) me