IMPORTANT If you want to use targets and inputs that uses libpcap or any other feature that requires some special dependency, make sure that you install them before running the ./configure script. On some distributions (e.g. Debian, Ubuntu) you will need to install the -dev package that contains the include files. For example on Debian you would execute “apt-get install libpcap-dev”. The package pkg-config is also very important for the configure script. Make sure you have it installed on your system.
You can obtain the source from the subversion repository by running the following command :
svn checkout https://svn.tuxicoman.be/svn/packet-o-matic/trunk packet-o-matic
You need at least autoconf-2.61. Once you have checked out the repository, you need to run autoreconf to create the configure script.
autoreconf -f -i
When this is done, proceed as explained below.
For Gentoo users, a ebuild is available here : http://www.packet-o-matic.org/downloads/packet-o-matic-svn-1.ebuild
You can obtain a snapshot of the source here : http://www.packet-o-matic.org/downloads/
First extract the tarball :
tar -xzvf packet-o-matic-svn-XXXXXXXX.tar.gz
Then run the following commands :
cd packet-o-matic ./configure make make install
If you did make install, you are fine. The program will be able to find the libraries using automatic resolving or hardcoded library path.
If you did not run make install, you have to set the variable LD_LIBRARY_PATH to the correct path. By default, libtool creates the libs into the src/.libs directory.
Also if you didn't ran make install, you may want to create a symbolic link for the share directory that points to your current packet-o-matic folder. This will help for the web interface and target_http.
cd /usr/local/share/ ln -s /folder/of/packet-o-matic/
Some modules such as input_pcap requires root privileges in order to perform their operation.
If after running make install, you have the following error :
packet-o-matic: error while loading shared libraries: libpom.so.0: cannot open shared object file: No such file or directory
It means that your system doesn't search at the correct place for libpom.so. To solve this problem add “/usr/local/lib/” in /etc/ld.so.conf. The following command will do it :
echo "/usr/local/lib" >> /etc/ld.so.conf; ldconfig