This document contains step-by-step instructions for compiling kvirc on a MacOS X system.
I compiled several versions of kvirc (beginning with 3.0.0 up to recent CVS) on a Powerbook G4, 1.5GHz, 512 MB RAM and MacOS X 10.3.3-9.
All this has worked fine several times for me. I've been using KVirc on Mac since May 2004 without any crashes & faults. Only the sound interface does not work, but I have no use for it within an IRC client. However, I cannot guarantee that this instructions will work for you as they do for me and I'm not responsible for any problems or damage you may encounter after following them. You should always understand what you are doing!
IMPORTANT: These instructions refer to Qt/Mac. If you want Qt/X11 which is included in Fink you are on your own. There is no support for the latter and most probably you don't get a working build.
#########################
Compilation with QT-MAC
#########################
IMPORTANT: When compiled with QT-MAC, kvirc has to be run out of a bundle! Otherwise the application won't dispatch the keyboard events correctly and will be pretty unusable for you.
A bundle is "just" a special directory structure on Mac systems which contains the application binary, dependant libraries, plugins, modules and other resources. So all we have to do is to run configure with proper paths and relink the binary, libraries and modules with relative paths after the compilation.
For details look at http://doc.trolltech.com/qq/qq09-mac-deployment.html and the documentation on http://developer.apple.com, please.
Prerequisites:
1. Apple XCode
Get the latest version from Apple. I've been using only V1.5 for building with QT-MAC
2. QT-MAC
Get the latest V3.*-version from Trolltech.
3. GNU gettext
Get the latest sources from your favourite GNU mirror.
Prerequisites installation:
1) Install XCode
If not included on your Panther install media or if you want the latest version, you have to register at http://developer.apple.com (it's free), download XCode and follow the install instructions in the documentation.
2) Install QT-MAC
You have to compile QT yourself. As far as I know there are no compiled binaries avaiable. Download and unpack the sources and follow the documentation.
I used V3.3.4
Add the following two lines to your ~/.profile file, otherwise the compilation if Qt may fail.
(If you don't want to build with debug information, remove the "-debug" switch in te configure line. You may also want to change "QMAKE_CFLAGS_RELEASE = -Os" in the mkspec/macx-g++/qmake.conf file to -O2. If you want the tutorial and examples, run "make" instead of "make sub-tools")
3) Install GNU gettext
If you want non-english locales, you need GNU gettext.
If you already installed Fink, you already have gettext so you may skip this step.
I used V0.14.5
Open a terminal window
# cd /Developer
# tar -xzf <your_path_to_the_sources>/gettext-0.14.5.tar.gz
# cd gettext-0.14.5
# ./configure
# make
# make install
#########################
KVirc installation:
1) Get the KVirc sources:
IMOPRTANT: Only the CVS sources compile cleanly with QT-MAC for now!
You will be asked for a password: just hit return.
# cvs -z3 -d:pserver:anonymous@cvs.kvirc.net:/cvs co kvirccvs
Run autogen:
# cd kvirccvs/kvirc
# ./autogen.sh
2) Run configure
The application bundle will be built in the kvirc sources directory.
Feel free to remove --enable-debug if you don't want to have a debuggable build and use addictional options like --enable-optimisation=2 or --with-big-channels.
CAUTION!!! Because of a problem with libtool you have to remove or rename the file libtqt-mt.la (or libtqt.la if you compiled QT without threads). It is located in $TQTDIR/lib/. Otherwise the compilation will stop with a link error.
KVirc and its modules depend on libkvilib and libtqt which are not in the dynamic linker search path by default. The paths set during the compilation are absolute paths and have to be changed to be realtive to the executable path.
Now you have to decide whether you want to include libtqt within the bundle or not. This is useful if you consider to share your bundle with your friends and they don't want to compile QT themselves.