This guide will help you to start with Axis C++. I'll explain the minimum steps needed to build and run Axis C++, and warn you about the common pitfalls.
      RedHat 9 (2.4.20-8)
      expat-1.95.7 (source)
      xerces-c-src2_2_0 (I build xerces from source)
      httpd-2.0.48 (source)
      apache_1.3.27 (source)
Note: If you are using provided configure and Makefile.in's you don't need to run autogen.sh script to generate them for your platform. In any case if you need to run it then following versions are recommended to be installed in your environment.
autoconf 2.57
automake 1.6.3
libtool 1.4.3
gcc 3.2.2
You can download the Axis C++ source or binary from one of the apache mirror sites
http://ws.apache.org/axis/cpp/download.html
You can get expat from the uri http://sourceforge.net/projects/expat/
You can get xercesc from the uri http://xml.apache.org/xerces-c/download.cgi
Unzip and untar the tgz ball.
You must define some environment variables in order to build.
AXISCPP_HOME is where you checkout Axis C++
AXISCPP_HOME="/usr/local/axiscpp"
AXISCPP_DEPLOY="/usr/local/axiscpp_deploy"
LD_LIBRARY_PATH="$AXISCPP_DEPLOY/lib:<path to parser library you use>"
export AXISCPP_HOME AXISCPP_DEPLOY LD_LIBRARY_PATH
AXISCPP_HOME is where you extracted the source distribution.
AXISCPP_DEPLOY is where Axis C++ will be deployed
Axis C++ core is independant of the parser layer and transport layer.
You can write your own transport or parser library according to the APIs provided. Currently Axis C++ provides API implementations for Xerces-c and Expat. It also provides it's own client side transport library implementation. In the server side deployment, Axis C++ provides two modules that can be loaded into apache1.3 and apache 2 as shared libraries.
So this sums upto two possibilities.
You can deploy Axis C++ server
    On Apache2 with xercesc parser or expat parser(Only one parser at a time)
    On Apache1.3 with xercesc parser or expat parser
When you build Axis C++ you can give options
1) Build for Apache2
With Expat parser support only
With Xerces parser support only
With both parser support
2) Build for Apache1.3
With Expat parser support only
With Xerces parser support only
With both parser support
You can choose these selections when you configure
The build process
cd $AXISCPP_HOME
Following step is optional. If you need to generate configure and Makefile.in's instead
of the provided one's you need to run autogen.sh
sh autogen.sh
./configure --prefix=<Where you need to deploy axis c++> \
--with-apache2=<path to apache2> \
--with-expat=/usr/local/expat1957
make
make install
This will deploy Axis C++ into your folder of choice.
Following are some of the options available with configure
--with-apache2 : To use apache2 as server transport library
--with-apache : To use apache as server transport library
--with-expat : To build expat parser library
--with-xercesc :To build xercesc parser library
--enable-samples : Whether you need to build samples(server and client)
        By default samples are built. If you don't want to build
the samples then you need to specifically say no
--enable-testcases : Whether you need to build testcases
        By default test cases are built. If you don't want to build the test cases then you need to specifically say no
--enable-log : Whether to enable log facility. By default this is enabled. If you don't need it say no to this
--enable-libwww : By default libwww client transport library is built. If you don't need it say no to this.
You may rename and edit build.sh_sample for one step configuring and building.
Once you have finished , have a look at $AXISCPP_HOME/build_errors. Most probably you will see many warnings. Just ignore them. But if you see any errors it means that build was not successful and check whether you have followed the instructions carefully.
You can see the folder $AXISCPP_DEPLOY/lib to see what are created
libaxiscpp_mod.so is apache module which is loaded when apache loads
libaxiscpp_mod2.so is apache2 module which is loaded when apache2 loads
libserver_engine.so is the Axis C++ server engine which is loaded by libaxis_mod(2).so module
libaxiscpp_client.so is Axis C++ client library
libaxis_transport.so is the Axis C++ client transport library
libaxis_expat.so is the expat parser library implementation for Axis C++
libaxis_xercesc.so is the xercesc parser library implmentation for Axis C++
Also $AXISCPP_HOME/samples/server samples are built and installed in $AXISCPP_DEPLOY/lib
$AXISCPP_HOME/samples/client samples are built and executables are in $AXISCPP_DEPLOY/bin
Now you need to add to $<apache install directory>/conf/httpd.conf
$ vi <apache install directory>/conf/httpd.conf
At the bottom of the file you have to include following lines and save it.
LoadModule axis_module modules/libaxiscpp_mod2.so (in apache1.3 replace modules with libexec and libaxiscpp_mod2.so with libaxiscpp_mod.so)
<Location /axis>
SetHandler axis
</Location>
Now you need the deployment descripter (server.wsdd) to deploy server samples you built.
By default there is a deployment descripter in $AXISCPP_DEPLOY/conf to deploy samples
In $AXISCPP_DEPLOY/etc/axiscpp.conf file you can give paths to your log files, configuration files, libraries etc.
# The comment character is '#'
#Available directives are as follows
#(Some of these directives may not be implemented yet)
#
#WSDDFilePath:The path to the server wsdd
#LogPath:The path to the axis log
#ClientLogPath:The path to the axis client log
#ClientWSDDFilePath:The path to the client wsdd
#Transport_http:The HTTP transport library
#Transport_smtp:The SMTP transport library
#XMLParser:The xml parser library
LogPath:/usr/local/axiscpp_deploy/log/AxisLog
WSDDFilePath:/usr/local/axiscpp_deploy/etc/server.wsdd
ClientLogPath:/usr/local/axiscpp_deploy/log/AxisClientLog
XMLParser:/usr/local/axiscpp_deploy/lib/libaxis_xmlparser.so
Transport_http:/usr/local/axiscpp_deploy/lib/libaxis_transport.so
Now we need to copy apache module(libaxiscpp_mod2.so for apache2 and libaxiscpp_mod.so for apache)
to the correct places and start apache.
To do that you can find scripts written in $AXISCPP_DEPLOY/bin.
cd $AXISCPP_DEPLOY/bin
To deploy on apache2
sh deploy_apache2.sh
To deploy on apache
sh deploy_apache.sh
When you run the above script,
libaxiscpp_mod2.so is copied to <your apache home>/modules folder.
libaxis_expat.so is renamed to libaxis_xmlparser.so. Also apache is started and libaxiscpp_mod2.so is loaded into apache.
libaxiscpp_mod2.so is the apache module for Axis C++. This will in term load Axis C++ server engine
(libserver_engine.so).
Note that libaxis_xmlparser.so is loaded by the engine dynamically as parsing is required from the engine.
Note that somewhere in the script above, it changes the name libaxis_expat.so to libaxis_xmlparser.so.
If we use xerces we need to change libaxis_xercesc.so to libaxis_xmlparser.so.
If you have done installation successfully it will display the Axis C++ welcome page when you point to URI http://localhost/axis
Note: In the axis welcome page all the services in $AXISCPP_DEPLOY/conf/server.wsdd are listed. This does not mean
that the libraries corresponding to these services are deployed yet. It merely list whatever in the server.wsdd.
To run interop samples
cd $AXISCPP_DEPLOY/bin
./base localhost 80 etc.
(Check whether there is a script run_interoptests.sh in that folder which can be used to run all the interop tests)
If you don't get it right check with the following list
Check whether AXISCPP_HOME is set where you build axis c++ by
echo $AXISCPP_HOME
Check whether AXISCPP_DEPLOY and LD_LIBRARY_PATH is set where you start apache
Build axis c++ and run clients by
echo $AXISCPP_DEPLOY
echo $LD_LIBRARY_PATH
Check whether you have necessary permissions to create the deploy folder which you give in configure option prefix.
eg: configure --prefix=/usr/local/axiscpp_deploy you need permission to write in /usr/local/ . Otherwise if you type make install you will get permission problems
Check whether paths in server.wsdd are pointing correctly to service or handler libraries
Check whether axiscpp.conf is containing correct entries
Check whether Axis C++ can write to log folder($AXISCPP_DEPLOY/log)
Unzip and untar the tgz ball.
You must define some environment variables first.
AXISCPP_DEPLOY="/usr/local/axiscpp_deploy"
LD_LIBRARY_PATH="$AXISCPP_DEPLOY/lib:<path to parser library you use>"
export AXISCPP_DEPLOY LD_LIBRARY_PATH
AXISCPP_DEPLOY is where you extracted the binary distribution
Have a look at the folder $AXISCPP_DEPLOY/lib to see what is there
libaxiscpp_mod.so is apache module which is loaded when apache loads
libaxiscpp_mod2.so is apache2 module which is loaded when apache2 loads
libserver_engine.so is the Axis C++ server engine which is loaded by libaxis_mod(2).so module
libaxiscpp_client.so is Axis C++ client library
libaxis_transport.so is the Axis C++ client transport library
libaxis_expat.so is the expat parser library implementation for Axis C++
libaxis_xercesc.so is the xercesc parser library implmentation for Axis C++
Also server samples are in
$AXISCPP_DEPLOY/lib
Client samples are in $AXISCPP_DEPLOY/bin
Axis C++ core is independant of the parser layer and transport layer.
You can write your own transport or parser library according to the APIs provided. Currently Axis C++
provides API implementations for Xerces-c and Expat. It also provides it's own client side transport
library implementation. In the server side deployment, Axis C++ provides two modules that can be loaded
into apache1.3 and apache 2 as shared libraries.
So this sums upto two posibilities.
You can deploy Axis C++ server
   On Apache2 with xercesc parser or expat parser(Only one parser at a time)
   On Apache1.3 with xercesc parser or expat parser
This binary comes with libraries built for apache1.3 and apache2 support and parser libraries both for expat and xercesc
It also comes with all the sample libraries and sample executables and prebuilt tests. But If you need to build the samples and tests for yourself from the sample and test source do the following
Sample and Test build process
cd $AXISCPP_DEPLOY
Following step is optional. If you need to generate configure and Makefile.in's instead
of the provided one's you need to run autogen.sh
sh autogen.sh
./configure --prefix=$AXISCPP_DEPLOY
make
make install
This will put sample libraries into $AXISCPP_DEPLOY/lib and
sample executables into $AXISCPP_DEPLOY/bin
Now you need to add to $<apache install directory>/conf/httpd.conf
$ vi >apache install directory</conf/httpd.conf
At the bottom of the file you have to include following lines and save it.
LoadModule axis_module modules/libaxiscpp_mod2.so (in apache1.3 replace modules with libexec and libaxiscpp_mod2.so with libaxiscpp_mod.so)
<Location /axis>
SetHandler axis
</Location>
Now you need the deployment descripter(server.wsdd) to deploy server samples you built.
By default there is a deployment descripter in $AXISCPP_DEPLOY/conf to deploy samples
In $AXISCPP_DEPLOY/etc/axiscpp.conf file you can give paths to your log files, configuration files, libraries etc.
# The comment character is '#'
#Available directives are as follows
#(Some of these directives may not be implemented yet)
#
#WSDDFilePath:The path to the server wsdd
#LogPath:The path to the axis log
#ClientLogPath:The path to the axis client log
#ClientWSDDFilePath:The path to the client wsdd
#Transport_http:The HTTP transport library
#Transport_smtp:The SMTP transport library
#XMLParser:The xml parser library
LogPath:/usr/local/axiscpp_deploy/log/AxisLog
WSDDFilePath:/usr/local/axiscpp_deploy/etc/server.wsdd
ClientLogPath:/usr/local/axiscpp_deploy/log/AxisClientLog
XMLParser:/usr/local/axiscpp_deploy/lib/libaxis_xmlparser.so
Transport_http:/usr/local/axiscpp_deploy/lib/libaxis_transport.so
Now we need to copy apache module(libaxiscpp_mod2.so for apache2 and libaxiscpp_mod.so for apache)
to the correct places and start apache.
To do that you can find scripts written in $AXISCPP_DEPLOY/bin.
cd $AXISCPP_DEPLOY/bin
To deploy on apache2
sh deploy_apache2.sh
To deploy on apache
sh deploy_apache.sh
When you run the above script,
libaxiscpp_mod2.so is copied to <your apache home>/modules folder.
libaxis_expat.so is renamed to libaxis_xmlparser.so. Also apache is started and libaxiscpp_mod2.
libaxiscpp_mod2.so is the apache module for Axis C++. This will in term load Axis C++ server engine
(libserver_engine.so).
Note that libaxis_xmlparser.so is loaded by the engine dynamically as parsing is required from the
engine.
Note that somewhere in the script above it changes the name libaxis_expat.so to libaxis_xmlparser.so.
If we use xerces we need to change libaxis_xercesc.so to libaxis_xmlparser.so.
If you have done installation successfully it will display the Axis C++ welcome page when you point to URI http://localhost/axis
Note: In the axis welcome page all the services in $AXISCPP_DEPLOY/conf/server.wsdd are listed. This does not mean
that the libraries corresponding to these services are deployed yet. It merely list whatever in the server.wsdd.
To run interop samples
cd $AXISCPP_DEPLOY/bin
./base localhost 80 etc.
(Check whether there is a script run_interoptests.sh in that folder which can be used to run all the interop tests)
If you don't get it right check with the following list
Check whether AXISCPP_DEPLOY and LD_LIBRARY_PATH is set where you start apache
Build axis c++ and run clients by
echo $AXISCPP_DEPLOY
echo $LD_LIBRARY_PATH
Check whether you have necessary permissions to create the deploy folder which you give in configure option prefix.
eg: configure --prefix=/usr/local/axiscpp_deploy you need permission to write in /usr/local/. Otherwise if you type make install you will get permission problems
Check whether paths in server.wsdd are pointing correctly to service or handler libraries
Check whether axiscpp.conf is containing correct entries
Check whether Axis C++ can write to log folder($AXISCPP_DEPLOY/log)