Next Previous Contents

4.2 Compiling Tircproxy

(If you have a binary distribution of Tircproxy you can skip this section. Installation of .rpm and .src.rpm packages is not covered by this manual, consult the rpm documentation instead. You should be aware though, that binary distributions may not have all features enabled - the only way to be sure everything is enabled is to compile it yourself!)

Compiling Tircproxy should be relatively straightforward on most systems. You should follow these steps:

  1. Tircproxy has few prerequisites, it should detect the features offered by your system automatically and configure itself accordingly. But if you want to be sure a feature will be available, you should check this list, and install the things you need before continuing:

  2. Download the most recent "tircproxy-X.Y.Z.tar.gz" file from http://bre.klaki.net/programs/tircproxy/.

  3. Extract the tar file, and enter the created source diretory:

    gzip -dc tircprozy-X.Y.Z.tar.gz | tar xvf -
    cd tircproxy-X.Y
    

  4. Edit the file tircproxy.h if you wish to disable specific features, customize the compiled-in messages, the DCC blacklist or modify file locations.

  5. Execute the following commands to build the program:

    ./configure
    make
    

    The 'make' command will build the proxy, and print out warnings to tell you what features are being compiled in. Pay attention to these messages - some features are not available on all systems, and reading this might save you some head-scratching later on.

  6. If all goes well, and you are the system administrator, give the following command:

    su -c "make install"
    

    If you aren't the system administrator, simply copy the executable file tircproxy to some conveniant location.

  7. Finally, to clean up, give the command:

    make clean
    

On a Linux system, the build sequence should look something like this:

[bre@discordia tircproxy-0.4]$ ./configure
creating cache ./config.cache
checking host system type... i486-pc-linux-gnu
checking target system type... i486-pc-linux-gnu
checking build system type... i486-pc-linux-gnu
checking for gcc... gcc
checking whether the C compiler (gcc  ) works... yes
checking whether the C compiler (gcc  ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking whether gcc accepts -g... yes
checking for a BSD compatible install... /usr/bin/install -c
checking for main in -lwrap... yes
checking for main in -lnsl... yes
checking for main in -lsocket... no
checking for main in -lcrypt... yes
checking for strip... /usr/bin/strip
checking for OS quirks... goody - it's Linux!
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/wait.h that is POSIX.1 compatible... yes
checking for fcntl.h... yes
checking for sys/ioctl.h... yes
checking for sys/time.h... yes
checking for crypt.h... yes
checking for syslog.h... yes
checking for unistd.h... yes
checking for netinet/ip_nat.h... no
checking for working const... yes
checking for uid_t in sys/types.h... yes
checking whether gcc needs -traditional... no
checking whether setpgrp takes no argument... yes
checking return type of signal handlers... void
checking for select... yes
checking for socket... yes
checking for strerror... yes
checking for strstr... yes
checking for vsnprintf... yes
checking for vprintf... yes
updating cache ./config.cache
creating ./config.status
creating Makefile
creating config.h
[bre@discordia tircproxy-0.4]$ make
gcc -c  -I. -I. -g -O2 tircproxy.c
tircproxy.c:69: warning: #warning MIRC DCC kludge active
tircproxy.c:72: warning: #warning Nickname logging active
tircproxy.c:96: warning: #warning Configuration via /etc/hosts.* available
tircproxy.c:119: warning: #warning IPF support not available
tircproxy.c:133: warning: #warning Linux transparent proxying available
tircproxy.c:139: warning: #warning Quiz mode available
gcc  tircproxy.o -o tircproxy -lcrypt -lnsl -lwrap
[bre@discordia tircproxy-0.4]$ su -c "make install"
Password:
/usr/bin/install -c -o bin -g bin -m 555 tircproxy /usr/local/sbin/tircproxy
[bre@discordia tircproxy-0.4]$ make clean
rm -f tircproxy.o tircproxy *~ *.bak
[bre@discordia tircproxy-0.4]$


Next Previous Contents