[OPEN-ILS-DEV] SPAM: autoconf support for openSRF (resubmission)

Bill Erickson erickson at esilibrary.com
Fri May 16 11:09:24 EDT 2008


On Wednesday 14 May 2008 1:40 Kevin Beswick wrote:
> This is an initial patch supporting the effort of porting OpenSRF to
> the GNU autotools.
>
> The goal of this patch is to enable someone to generate a configure
> script using autoconf, allow someone to choose various install options
> through the generated configure script, and to remove the need for the
> install.conf file.
>
> The configure script makes various checks based on the dependencies of
> openSRF, allows users to customize the install directories, and select
> various install options (whether or not to install python modules,
> java libraries, legacy json headers). It outputs the results of these
> custom checks/settings at the end of the default configure script
> output.
>
> The automake Makefile.am's are not included as of yet, instead only
> Makefile.in's are included so that configure can generate appropriate
> Makefiles based on the already existing ones.
>
> To test:
> automake -a
> autoconf
> ./configure [--option]
> make
> make install


Some comments:

When I invoke 'automake -a', I get some warnings:

configure.ac: no proper invocation of AM_INIT_AUTOMAKE was found.
configure.ac: You should verify that configure.ac invokes AM_INIT_AUTOMAKE,
configure.ac: that aclocal.m4 is present in the top-level directory,
configure.ac: and that aclocal.m4 was recently regenerated (using aclocal).
configure.ac: installing `./install-sh'
configure.ac: installing `./missing'
automake: no `Makefile.am' found for any configure output

Should I fear these?

------------------

It's also important to note that if you run ./configure as a non-root user, it 
may die with:

checking for ejabberd... no
configure: error: *** ejabberd not found, aborting

/usr/sbin, where ejabberd lives on my test system (Debian Lenny), is not in my 
path.

This works fine:

PATH=$PATH:/usr/sbin/ ./configure

------------

I ran configure with the defaults and later realized that I needed to update 
my tmp_dir, since it was already in use by another user on this system.  I 
ran:

PATH=$PATH:/usr/sbin/ ./configure --with-tmp_dir=/tmp/osrftmp

The configure output reports:

Tmp dir location:         /tmp/osrftmp

However, Makefile[.in] still shows TMP=/tmp/ilstemp, which causes my 'make' 
attempts to fail.

Should re-running configure update that?  It's likely my own autoconf 
ignorance is coming into play here...

-----------------

Minor nit:  Can we make the default TMP directory /tmp/osrftmp (or similar)?

---------------

To prevent filling up the file, can we wrap the mod_placeholder insertion 
(in 'make install') in a check to see if it's needed?  For example:

if [ ! $$(grep mod_placeholder /etc/apache2/httpd.conf) ]; then \
    echo "#LoadModule 
mod_placeholder /usr/lib/apache2/modules/mod_placeholder.so" \
        >> /etc/apache2/httpd.conf; \
    fi; \
make -s -C src install

----------------------

Kevin, this is looking /very/ good.  I didn't realize you had gotten this far 
until I went for it.  Kudos.

-bill


-- 
Bill Erickson
| VP, Software Development & Integration
| Equinox Software, Inc. / The Evergreen Experts
| phone: 877-OPEN-ILS (673-6457)
| email: erickson at esilibrary.com
| web: http://esilibrary.com


More information about the Open-ils-dev mailing list