On Thu, Jul 17, 2008 at 12:03 AM, Alex Bolgarov <[EMAIL PROTECTED]> wrote:
> Hi, > > How do you load a mod_axis2.so module into the Apache when you copy > the Axis2/C libraries to some directory Apache load mod_axis2 using the path in Axis2/c Loadmodule directives.( LoadModule axis2_module MOD_AXIS2_SO_PATH) - for example, when you are > using the binary Axis2/C distribution, or just build Axis2/C from > source on one machine (and installed itto some directory) and then > copy Axis2/C module and libraries to some directory on some othar > machine with Apache server? So in the second machine, in which where you runs Apache you need to configure the It's you compile the source in a once machine, and then execute the binary in once machine. Some times some issues can be occurred if the two architectures are different from each other. > > > Well, here is a longer description of the problem: > > Say I'm using a source distribution. I download the .tar.gz source > tarball, untar, configure it with some install directory (--prefix) > and build/install it, now I have this install directory with the build > by me Axis2/C. > > I have Apache server running in this machine, so I copy mod_axis2.so > into the Apache installation, I update the Apache config to load the > module, I define the Axis2/C repository, I develop a web service and > run tests against it. All is fine up to this point. > > Now I want to use the Axis2/C with the Apache server that is running > on another machine. > > I copy everything from the install directory from the build machine > into some directory on this other machine with Apache (let's call this > directory "/home/alex/axis2c-dist"). Add LoadModule axis2_module path_of_mod_axis2 Axis2RepoPath /home/alex/axis2c-dist > > > I rename libmod_axis2.so.0.4.0 to mod_axis2.so and copy it into the > Apache's modules directory. > > Now I change the Apache config file so that it contains the line > > LoadModule axis2_module modules/mod_axis2.so > > I try to start Apache: > > $ apachectl start > > and see following error: > > Cannot load /home/alex/httpd/modules/mod_axis2.so into server: > libaxis2_engine.so.0: cannot open shared object file: No such file or > directory > > Now, I happen to know about the LoadFile Apache directive :) > > I add the LoadFile directive for the libaxis2_engine.so so that Apache > loads it from the /home/alex/axis2c-dist directory, now the Apache > config looks like this: You need to add the Axis2Repo path in httpd.conf. Did you have a look at here ? http://ws.apache.org/axis2/c/docs/axis2c_manual.html#mod_axis2 -Rajika > > > LoadFile /home/alex/axis2c-dist/lib/libaxis2_engine.so.0.4.0 > LoadModule axis2_module modules/mod_axis2.so > > I try to start Apache again: > > $ apachectl start > > and now see: > > Cannot load /home/alex/axis2c-dist/lib/libaxis2_engine.so.0.4.0 into > server: libneethi.so.0: cannot open shared object file: No such file > or directory > > OK, I add LoadFile directives for the libneethi.so, and so on, when I > finally arrive to the following config: > > LoadFile /home/alex/axis2c-dist/lib/libaxutil.so.0.4.0 > LoadFile /home/alex/axis2c-dist/lib/libguththila.so.0.4.0 > LoadFile /home/alex/axis2c-dist/lib/libaxis2_parser.so.0.4.0 > LoadFile /home/alex/axis2c-dist/lib/libaxis2_axiom.so.0.4.0 > LoadFile /home/alex/axis2c-dist/lib/libneethi.so.0.4.0 > LoadFile /home/alex/axis2c-dist/lib/libaxis2_http_common.so.0.4.0 > LoadFile /home/alex/axis2c-dist/lib/libaxis2_engine.so.0.4.0 > > LoadModule axis2_module modules/mod_axis2.so > > But now, after I try to start Apache, I see new error: > > Cannot load /home/alex/axis2c-dist/lib/libaxis2_http_common.so.0.4.0 > into server: /home/alex/axis2c-dist/lib/libaxis2_http_common.so.0.4.0: > undefined symbol: axis2_handler_invoke > > Which means that the libaxis2_engine.so depends on the > libaxis2_http_common.so, and requires it to be loaded by Apache first, > but the libaxis2_http_common.so contains a reference to undefined > symbol "axis2_handler_invoke", that is defined by the > libaxis2_engine.so. (Yes, I used 'nm libaxis2_engine.so | grep > axis2_handler_invoke" to check that this symbol is indeed defined in > this library.) > > Circular dependency? > > How do I break it? > > (note that the same thing happens if I download the binary > distribution, untar it into some directory and copy the mod_axis2 into > the Apache moddules directory. Up to the same point I can use LoadFile > to load Axis2/C libraries, but then again I see this circular > dependency) > > > Thank you, > > alex. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- comp.lang.c - http://groups.google.com/group/comp.lang.c/topics
