14.1 Compiling GnuGk from CVS
The following instructions are an example of how to compile GnuGk from source on an Ubuntu platform.
First make sure your system is up-to-date and install the tools needed for the compile
$ sudo apt-get update $ sudo apt-get install flex bison build-essential subversion cvs pkg-config automakeAlso make sure the "...-devel" packages for all databases you want to use are installed.
Get and compile PTLib from SourceForge:
$ cd ~ $ svn co http://opalvoip.svn.sourceforge.net/svnroot/opalvoip/ptlib/trunk ptlib $ cd ptlib $ export PTLIBDIR=~/ptlib $ ./configure $ make optnoshared
Get and compile H323Plus:
$ cd ~ $ cvs -d:pserver:anonymous@h323plus.cvs.sourceforge.net:/cvsroot/h323plus login (just press enter when prompted for password) $ cvs -z3 -d:pserver:anonymous@h323plus.cvs.sourceforge.net:/cvsroot/h323plus co -P h323plus $ cd h323plus $ export OPENH323DIR=~/h323plus $ ./configure $ make optnoshared
Get and compile GnuGk:
$ cd ~ $ cvs -d:pserver:anonymous@openh323gk.cvs.sourceforge.net:/cvsroot/openh323gk login (just press enter when prompted for password) $ cvs -z3 -d:pserver:anonymous@openh323gk.cvs.sourceforge.net:/cvsroot/openh323gk co -P openh323gk $ cd openh323gk $ ./configure --enable-h46018 $ make optnoshared
Once the compile is finished, the binary can be found in the obj_linux_x86_s subdirectory.
At this time, because all libraries and GnuGk are running CVS and SVNversions of the software, in order to stay up-to-date, run the following:
$ cd ~/ptlib $ svn update $ cd ~/h323plus $ cvs update $ cd ~/openh323gk $ cvs updateIf any of the source files are changed, you have to recompile.
14.2 Debugging GnuGk (on Linux)
In order to use gdb with GnuGk, the software and libraries must be compiled with debug support.
You may follow the instructions above in obtaining the software, but the compile in each subdirectory must be:
$ make debugnoshared
Allow unlimited core dumps:
ulimit -c unlimited
Run GnuGk:
~/openh323/obj_linux_x86_64_d_s/gnugk -c your.ini # wait for crash gdb obj_linux_x86_64_d/gnugk core bt
Once you've obtained a backtrace, post it to the mailing list.
Note: On some systems, the core dump is named "core.xxx" where xxxis the process number of the program that crashed.