Fix installation for silc-client and silc-toolkit packages
[silc.git] / README.GIT
1 Compiling SILC from GIT Tree
2 ============================
3
4 These instructions are meant for developers wanting to compile SILC
5 directly from the GIT tree.
6
7 To prepare the source tree for making official releases, read the
8 README.DIST instead.
9
10 To be able to prepare the GIT tree for configuration and compilation
11 Autodist must be installed into the system.  You can download the latest
12 version of Autodist from: 
13
14         http://autodist.silc.fi
15
16
17 Preparing SILC Client
18 =====================
19
20 To prepare SILC Client distribution for compilation give the following
21 command:
22
23         autodist client
24         ./configure
25         make
26
27
28 Preparing SILC Server
29 =====================
30
31 To prepare SILC Server distribution for compilation give the following
32 command:
33
34         autodist server
35         ./configure
36         make
37
38
39 Preparing SILC Toolkit
40 ======================
41
42 To prepare SILC Toolkit distribution for compilation give the following
43 command:
44
45         autodist toolkit
46         ./configure
47         make
48
49
50 Preparing any distribution
51 ==========================
52
53 To compile so called INLINE version of the SILC sources give the following
54 command:
55
56         autodist
57         ./configure
58         make
59
60 The INLINE version is usually used when doing actual SILC development as
61 it makes all code available for compilation, testing and debugging, while
62 the other distributions limit the available code only to that used by the
63 distribution.
64
65
66 Running, Debugging and Developing
67 =================================
68
69 The autodist must be run every time you make some changes to configuration 
70 scripts.
71
72 As a developer you should read the ./configure script's help by
73 giving ./configure --help and study all of its different options.  Also,
74 you should configure the script with --enable-debug option as it
75 compiles SILC with -g (debugging) option and it enables the 
76 SILC_LOG_DEBUG* scripts.  Warning is due here:  The debugging produced
77 by both cilent and server is very heavy, thus it is common to test
78 the programs as follows:
79
80         ./silc -d "*" -f configfile 2>log
81         ./silcd -d "*" -f configfile 2>log
82
83 The -d option enables the debug printing.  The argument for the -d option
84 is a string that is used to match the output debug.  The example "*" will
85 match for everything, and all debugs will be printed.  If you want to
86 limit the debugs you want to printout you can give for example a string
87 like "*server*,*rng*" to match all functions, and filenames that has
88 "server" or "rng" string in them.  Others will not be printed out.  You   
89 can freely define regural expressions as debug string.
90
91
92 Makefiles and configuration files
93 =================================
94
95 Developers should never directly write a Makefile.  All Makefiles are 
96 always automatically generated by autodist and later by ./configure 
97 scripts.  Instead, developers must write Makefile.ad files or Makefile.am 
98 files.  If the Makefile needs to include any distdefs (SILC_DIST_XXX), 
99 then Makefile.ad (.ad stands for autodist) must be written.  If the 
100 Makefile is generic (common to all distributions) then Makefile.am may be 
101 written.  Note that distdefs MUST NOT be used in Makefile.am files, as the 
102 autodist will modify them.  See the source tree for examples.  If you 
103 change Makefile.ad files, the autodist must be rerun.
104
105 The autodist also creates the configure.ac script from which the autoconf 
106 then creates the ./configure script.  All changes to configure must 
107 always be done into the configure.ad scripts.  All changes made to 
108 configure.ac will be lost.  The autodist distdefs may also be used in 
109 configure.ad files.  It is also possible to write more than one 
110 configure.ad in the source tree.  All configure.ad fragments will be 
111 collected from the source tree by autodist and combined into one 
112 configure.ac scripts.  After making changes to configure.ad files the 
113 autodist must be rerun.
114
115 The distdefs are defined in the corresponding distributions.  All 
116 distributions live in distdir/ directory.  The distdefs can be used in any 
117 file in the source tree, but mainly they are used in Makefile.ad, 
118 configure.ad and source and headers files.  See autodist documentation for 
119 more information how to use distdefs.
120
121
122 What SILC Source Tree Includes
123 ==============================
124
125 SILC Source tree includes a lot more stuff that appears in public 
126 distribution.  The source tree includes, for example, internal scripts, 
127 configuration files, etc.  These never appear on a public distribution.
128
129 Following directories currently exist in SILC source tree.
130
131   apps/
132
133         All applications.
134
135   doc/
136
137         Includes all the SILC documentation.  Some of the documentation
138         are generated when distribution is generated.  The automatically
139         generated files must never be commited to CVS.
140
141   includes/
142
143         Includes SILC include files.
144
145   apps/irssi/
146
147         Includes the Irssi SILC Client.
148
149   lib/
150
151         Includes SILC libraries.  There maybe libraries on the CVS that
152         does not appear on public distribution.
153
154   lib/contrib/
155
156         Contrib directory for routines that some of the platforms might
157         not have.  In that case these routines are provided by the SILC.
158
159   lib/silcclient/
160
161         The SILC Client library. Implementation of the SILC Client without
162         the user interface.  The library provides an interface for user
163         interface designers.
164
165   lib/silccore/
166
167         The SILC Protocol Core library.  Implementation of all the core
168         components of the SILC Protocol.  This is used by all the SILC
169         applications.
170
171   lib/silccrypt/
172
173         The SILC Crypto library. Provides all cryptographic algorithms
174         used in the SILC.  Provides also the Cryptographically strong
175         random number generator.
176
177   lib/silcmath/
178
179         The SILC Math library. Provides the Math and MP routines for
180         SILC applications.  The MP library is actually the GMP.
181
182   lib/silsim/
183
184         The SILC Modules library.  Provides the dynamically loadable
185         modules.
186
187   lib/silcske/
188
189         The SILC Key Exchange (SKE) library.  Implementation of the
190         SKE protocol.  This is used by all SILC applications.
191
192   lib/silcutil/
193
194         The SILC Utility library.  Provides various utility functions
195         for the applications.
196
197   lib/silcutil/unix/
198
199         The SILC Utility library.  Provides various Unix specific utility
200         functions for the applications.
201
202   lib/silcutil/win32/
203
204         The SILC Utility library.  Provides various WIN32 specific utility
205         functions for the applications.
206
207   public_html/
208
209         Includes the official SILC web pages and everything that relates
210         to them.  This directory never appears on public distribution.
211
212   apps/silc/
213
214         Includes an example implementation of ncurses based SILC client.
215         It won't compile with current Toolkit since it is not being 
216         updated.  It is still good example for Toolkit programmer to 
217         figure out how to use SILC Toolkit.
218
219   apps/silcer/
220
221         Includes an example implementation of GUI (Gnome) base SILC
222         client.  Please read silcer/README for more information.
223
224   apps/silcd/
225
226         Includes SILC server.  There can be some extra files that will
227         never appear in public distribution, such as, configuration files.
228
229   win32/
230
231         Includes win32 Toolkit specific files.  It includes MSVC++
232         Workspace files.  The win32/tests includes example code for
233         use of SILC Toolkit and SILC Client Library on Win32 GUI 
234         application.