You are viewing a plain text version of this content. The canonical link for it is here.
Posted to apreq-dev@httpd.apache.org by Jeffrey Horner <je...@vanderbilt.edu> on 2005/07/13 17:27:47 UTC

On distributing libapreq2

Okay, I'm to the part where I've identified the functionality of 
libapreq2 (proper, just the library without mod_apreq2) that I want to 
use in my apache2 module (mod_R, R is the statistical language). Now 
I've got to solve distribution of my module with libapreq2, and I'd like 
to get your input.

I could distribute the whole source package with mod_R, build it and 
install just libapreq2.os.*. This seems the simplest, but folks who 
already have libapreq2 installed AND in use will run into problems.

I could add the libapreq2 objects to my mod_R shared library upon 
install, but wouldn't folks who already have a version of libapreq2 
installed and in use still have problems, multiply defined symbols and 
whatnot?

Any other options? I sure hope the apache httpd project integrates 
libapreq2 soon so I won't have to worry about this...

Thanks,
-- 
Jeffrey Horner       Computer Systems Analyst         School of Medicine
615-322-8606         Department of Biostatistics   Vanderbilt University

Re: On distributing libapreq2

Posted by "Philip M. Gollucci" <pg...@p6m7g8.com>.
 >configure --with-apxs=/path/to/apxs --with-R=/path/to/R
 >
 >Now, if users want to just use the version of libapreq2 that I 
distribute, then configure will have to catch that and make appropriate 
 >decisions. But if I add --with-apreq2=/path/to/apreq2-config and the 
user chooses it, then configure will have to make appropriate >decisions 
based on apreq2-config.

I can probably get you an example to go with.... just not until 
tonight/tomorrow.

You might try reading the docs on GNU they are decent.  If all else 
fails look at apache's httpd or apr/apr-util -- hey do a lot.
http://www.gnu.org/



Re: On distributing libapreq2

Posted by Jeffrey Horner <je...@vanderbilt.edu>.
Joe Schaefer wrote:
> Jeffrey Horner <je...@vanderbilt.edu> writes:
[...]
>>I could distribute the whole source package with mod_R, build it and
>>install just libapreq2.os.*. This seems the simplest, but folks who
>>already have libapreq2 installed AND in use will run into problems.
> 
> I think this is the best route, even after httpd includes libapreq2.
> You could also include an --with-apreq2=/path/to/apreq2-config option 
> in mod_R's configure script, which would use the previously installed 
> version of libapreq2 and ignore the version you're actually shipping
> with mod_R.  Doing that would also help us improve our apreq2-config.in 
> script.
> 

Okay, I'll do it, but my knowledge of autoconf is low. Do you happen to 
have some pointers to docs or such?

Essentially this is what I have to configure my module:

configure --with-apxs=/path/to/apxs --with-R=/path/to/R

Now, if users want to just use the version of libapreq2 that I 
distribute, then configure will have to catch that and make appropriate 
decisions. But if I add --with-apreq2=/path/to/apreq2-config and the 
user chooses it, then configure will have to make appropriate decisions 
based on apreq2-config.

autoconf is a nightmare.

Also, what happens when an executable calls a shared library call? Does 
the entire shared library get loaded into memory, shared memory? If you 
have some pointers to docs on this, I'd be much obliged.

-- 
Jeffrey Horner       Computer Systems Analyst         School of Medicine
615-322-8606         Department of Biostatistics   Vanderbilt University

Re: On distributing libapreq2

Posted by Joe Schaefer <jo...@sunstarsys.com>.
Jeffrey Horner <je...@vanderbilt.edu> writes:

> Okay, I'm to the part where I've identified the functionality of libapreq2
> (proper, just the library without mod_apreq2) that I want to use in my
> apache2 module (mod_R, R is the statistical language). Now I've got to solve
> distribution of my module with libapreq2, and I'd like to get your input.
>
> I could distribute the whole source package with mod_R, build it and
> install just libapreq2.os.*. This seems the simplest, but folks who
> already have libapreq2 installed AND in use will run into problems.

I think this is the best route, even after httpd includes libapreq2.
You could also include an --with-apreq2=/path/to/apreq2-config option 
in mod_R's configure script, which would use the previously installed 
version of libapreq2 and ignore the version you're actually shipping
with mod_R.  Doing that would also help us improve our apreq2-config.in 
script.

> I could add the libapreq2 objects to my mod_R shared library upon
> install, but wouldn't folks who already have a version of libapreq2
> installed and in use still have problems, multiply defined symbols and
> whatnot? 

Right- not a good idea.

> Any other options? I sure hope the apache httpd project integrates
> libapreq2 soon so I won't have to worry about this...

I think we'll all have to worry about it even after they
include libapreq2, because we'll still need to make 
independent releases of libapreq2 for the foreseeable
future.  We just try to avoid major collisions in the
process.

-- 
Joe Schaefer