INSTALL
======

It is recommended to unpack all source code packages needed for AGENT++
wihtin the same directory. 
Assuming that you have downloaded the source code packages for libDES, 
SNMP++v3.x, and AGENT++ from http://www.agentpp.com and stored the
files in a directory named "myproj" the following commands will setup your
build environment:

gtar xzvf libdes-l-4.01.tar.gz
gtar xzvf snmp++v3.2.tar.gz
gtar xzvf agent++v3.5.4.tar.gz

cd libdes
make cc
cd ..

cd snmp++/src
make -f Makefile.<platform>
cd ../..

cd agent++/src
make -f Makefile.<platform>
cd ../..

Please note: 
1. You need a GNU make (gmake) to build AGENT++.
2. The Makefiles of AGENT++ and AgentX++ build static and shared 
libaries by default. You will have to remove the shared libs by

rm agentX++/lib/libagentx++.so
rm agent++/lib/libagent++.so

in order to build a statically linked executable. Otherwise, you will
have to set the environment variable LD_LIBRARY_PATH (Linux, Solaris) 
or SHLIB_PATH (HPUX 11) accordingly. 

To build one of the example agents:

cd agent++/examples/<example_dir>/src
make -f Makefile.<platform>


To setup your own build environment for an AgentGen Pro generated (simulation)
agent:

1. Copy AgentGen templates to your own project directory
cd agent++/agentgen
cp -rp agent myagent
(instead of "agent" in the above you may also use "simagent" if you want to 
build a simulation agent and if you have set the "simulation" property
to "yes" in the AgenPro project)

2. Now generate the source files into the myagent/src directory and the header
files into the myagent/include directory using AgenPro. 

3. Build the agent
cd agent++/myagent/src
make -f Makefile.<platform>


To enable persistent storage for an agent, create an empty folder
 "config" in the "src" directory of your agent, for example:

mkdir agent++/myagent/src/config



