You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by je...@apache.org on 2002/03/09 20:26:13 UTC

cvs commit: apr CHANGES Makefile.in apr-config.in configure.in

jerenkrantz    02/03/09 11:26:13

  Modified:    .        CHANGES Makefile.in apr-config.in configure.in
  Log:
  Allow APR to install its own libtool into an installbuilddir.
  
  Add --with-installbuilddir to configure.
  Add --apr-libtool option to apr-config so that third-parties can figure
  out where this generated libtool is.
  
  (Previously, httpd-2.0 would copy libtool for APR which isn't very nice.)
  
  Revision  Changes    Path
  1.234     +5 -0      apr/CHANGES
  
  Index: CHANGES
  ===================================================================
  RCS file: /home/cvs/apr/CHANGES,v
  retrieving revision 1.233
  retrieving revision 1.234
  diff -u -r1.233 -r1.234
  --- CHANGES	6 Mar 2002 17:50:01 -0000	1.233
  +++ CHANGES	9 Mar 2002 19:26:13 -0000	1.234
  @@ -1,4 +1,9 @@
   Changes with APR b1
  +
  +  *) Allow APR to install its generated libtool(s) via the 
  +     --with-installbuilddir option (defaults to ${datadir}/build).
  +     [Justin Erenkrantz]
  +
     *) renames: apr_ansi_time_to_apr_time becomes apr_time_ansi_put
        ap_exploded_time_t becomes apr_time_exp_t
        [Thom May <th...@planetarytramp.net>]
  
  
  
  1.69      +15 -5     apr/Makefile.in
  
  Index: Makefile.in
  ===================================================================
  RCS file: /home/cvs/apr/Makefile.in,v
  retrieving revision 1.68
  retrieving revision 1.69
  diff -u -r1.68 -r1.69
  --- Makefile.in	14 Dec 2001 21:43:04 -0000	1.68
  +++ Makefile.in	9 Mar 2002 19:26:13 -0000	1.69
  @@ -40,6 +40,7 @@
   bindir=@bindir@
   libdir=@libdir@
   includedir=@includedir@
  +installbuilddir=@installbuilddir@
   srcdir=@srcdir@
   top_srcdir=@top_srcdir@
   top_blddir=@top_builddir@
  @@ -59,15 +60,24 @@
   install: $(TARGET_LIB)
   	if [ ! -d $(includedir) ]; then \
   	    $(top_srcdir)/build/mkdir.sh $(includedir); \
  -	fi; \
  -	cp $(top_srcdir)/include/*.h $(includedir); \
  -	cp $(top_blddir)/include/*.h $(includedir); \
  +	fi;
  +	cp $(top_srcdir)/include/*.h $(includedir);
  +	cp $(top_blddir)/include/*.h $(includedir);
   	if [ ! -d $(libdir) ]; then \
   	    $(top_srcdir)/build/mkdir.sh $(libdir); \
  -	fi; \
  +	fi;
   	$(LIBTOOL) --mode=install cp $(TARGET_LIB) $(libdir)
   	$(LIBTOOL) --mode=install cp APRVARS $(libdir)
   	$(LIBTOOL) --mode=install cp apr.exp $(libdir)
  +	if [ ! -d $(installbuilddir) ]; then \
  +	   	$(top_srcdir)/build/mkdir.sh $(installbuilddir); \
  +	fi; 
  +	if [ -f libtool ]; then \
  +		$(LIBTOOL) --mode=install cp libtool $(installbuilddir); \
  +	fi;
  +	if [ -f shlibtool ]; then \
  +		$(LIBTOOL) --mode=install cp shlibtool $(installbuilddir); \
  +	fi;
   	if [ ! -d $(bindir) ]; then \
   	    $(top_srcdir)/build/mkdir.sh $(bindir); \
   	fi;
  @@ -77,7 +87,7 @@
               for i in $(INSTALL_SUBDIRS); do \
   	        ( cd $$i ; $(MAKE) install ); \
   	    done \
  -        fi
  +	fi
   
   $(TARGET_LIB):
   	@for i in $(SUBDIRS); do objects="$$objects $$i/*.@so_ext@"; done ; \
  
  
  
  1.12      +11 -0     apr/apr-config.in
  
  Index: apr-config.in
  ===================================================================
  RCS file: /home/cvs/apr/apr-config.in,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- apr-config.in	15 Feb 2002 08:43:46 -0000	1.11
  +++ apr-config.in	9 Mar 2002 19:26:13 -0000	1.12
  @@ -59,6 +59,8 @@
   exec_prefix="@exec_prefix@"
   bindir="@bindir@"
   libdir="@libdir@"
  +datadir="@datadir@"
  +installbuilddir="@installbuilddir@"
   includedir="@includedir@"
   
   CC="@CC@"
  @@ -92,6 +94,7 @@
     --apr-la-file     print the path to the .la file, if available
     --apr-so-ext      print the extensions of shared objects on this platform
     --apr-lib-target  print the libtool target information
  +  --apr-libtool     print the path to APR's libtool
     --help            print this help
   
   When linking with libtool, an application should do something like:
  @@ -197,6 +200,14 @@
       ;;
       --apr-lib-target)
       echo "$APR_LIB_TARGET"
  +    exit 0
  +    ;;
  +    --apr-libtool)
  +    if test "$location" = "installed"; then
  +        echo "${SHELL} ${installbuilddir}/libtool"
  +    else
  +        echo "${SHELL} $thisdir/libtool"
  +    fi
       exit 0
       ;;
       --help)
  
  
  
  1.416     +4 -0      apr/configure.in
  
  Index: configure.in
  ===================================================================
  RCS file: /home/cvs/apr/configure.in,v
  retrieving revision 1.415
  retrieving revision 1.416
  diff -u -r1.415 -r1.416
  --- configure.in	25 Feb 2002 16:55:10 -0000	1.415
  +++ configure.in	9 Mar 2002 19:26:13 -0000	1.416
  @@ -121,6 +121,10 @@
       ;;
   esac
   
  +AC_ARG_WITH(installbuilddir, [  --with-installbuilddir=<path> location to store APR build files (defaults to '${datadir}/build')],
  +  [ installbuilddir=$withval ], [ installbuilddir="${datadir}/build" ] )
  +AC_SUBST(installbuilddir)
  +
   AC_ARG_WITH(libtool, [  --without-libtool       avoid using libtool to link the library],
     [ use_libtool=$withval ], [ use_libtool="yes" ] )
   
  
  
  

Re: cvs commit: apr CHANGES Makefile.in apr-config.in configure.in

Posted by Branko Čibej <br...@xbc.nu>.
Greg Stein wrote:

>On Sat, Mar 09, 2002 at 07:26:13PM -0000, jerenkrantz@apache.org wrote:
>
>>jerenkrantz    02/03/09 11:26:13
>>
>>  Modified:    .        CHANGES Makefile.in apr-config.in configure.in
>>  Log:
>>  Allow APR to install its own libtool into an installbuilddir.
>>  
>>  Add --with-installbuilddir to configure.
>>
>
>Why does it have the --with on there? Normally, --with means "use this
>package". Another comparison point is that all the other directory options
>to not have --with: --bindir, --libdir, --includedir, etc
>
>I'd recommend changing it to just --installbuilddir. But all of those are
>installation directories, so it is really just --builddir.
>
I think this would be an --enable- option in autoconf-speak.


-- 
Brane Čibej   <br...@xbc.nu>   http://www.xbc.nu/brane/




Re: cvs commit: apr CHANGES Makefile.in apr-config.in configure.in

Posted by Aaron Bannert <aa...@clove.org>.
On Sun, Mar 10, 2002 at 03:54:12PM -0800, Greg Stein wrote:
> On Sat, Mar 09, 2002 at 07:26:13PM -0000, jerenkrantz@apache.org wrote:
> > jerenkrantz    02/03/09 11:26:13
> > 
> >   Modified:    .        CHANGES Makefile.in apr-config.in configure.in
> >   Log:
> >   Allow APR to install its own libtool into an installbuilddir.
> >   
> >   Add --with-installbuilddir to configure.
> 
> Why does it have the --with on there? Normally, --with means "use this
> package". Another comparison point is that all the other directory options
> to not have --with: --bindir, --libdir, --includedir, etc
> 
> I'd recommend changing it to just --installbuilddir. But all of those are
> installation directories, so it is really just --builddir.

I don't think this can be done with a simple autoconf macro, but we do
have a nifty new APACHE_PARSE_ARGUMENTS macro that we can add all these
autoconf-like-but-not-really-autoconf path arguments to. Luckily we should
already be setting installbindir from the layout by default, so this
would just let us override it w/o having to edit the config.layout file.

-aaron

Re: cvs commit: apr CHANGES Makefile.in apr-config.in configure.in

Posted by Justin Erenkrantz <je...@ebuilt.com>.
On Sun, Mar 10, 2002 at 03:54:12PM -0800, Greg Stein wrote:
> On Sat, Mar 09, 2002 at 07:26:13PM -0000, jerenkrantz@apache.org wrote:
> > jerenkrantz    02/03/09 11:26:13
> > 
> >   Modified:    .        CHANGES Makefile.in apr-config.in configure.in
> >   Log:
> >   Allow APR to install its own libtool into an installbuilddir.
> >   
> >   Add --with-installbuilddir to configure.
> 
> Why does it have the --with on there? Normally, --with means "use this
> package". Another comparison point is that all the other directory options
> to not have --with: --bindir, --libdir, --includedir, etc
> 
> I'd recommend changing it to just --installbuilddir. But all of those are
> installation directories, so it is really just --builddir.

As Aaron pointed out, I think there is no standard way of telling
autoconf to use a macro that doesn't have --with or --enable.  I
called it installbuilddir to match what httpd-2.0 calls the argument
with the same meaning.

If you know of a way to do that, feel free to add this.  Since
APR does not have access to any of the new parsing m4 code and
that code doesn't handle this argument anyway, this seemed the
best way.  Feel free to hack at it.  

I was able to fix my problem, but I won't have any time to do
anything much (besides lurk) for a few weeks.  -- justin


Re: cvs commit: apr CHANGES Makefile.in apr-config.in configure.in

Posted by Greg Stein <gs...@lyra.org>.
On Sat, Mar 09, 2002 at 07:26:13PM -0000, jerenkrantz@apache.org wrote:
> jerenkrantz    02/03/09 11:26:13
> 
>   Modified:    .        CHANGES Makefile.in apr-config.in configure.in
>   Log:
>   Allow APR to install its own libtool into an installbuilddir.
>   
>   Add --with-installbuilddir to configure.

Why does it have the --with on there? Normally, --with means "use this
package". Another comparison point is that all the other directory options
to not have --with: --bindir, --libdir, --includedir, etc

I'd recommend changing it to just --installbuilddir. But all of those are
installation directories, so it is really just --builddir.

Cheers,
-g

-- 
Greg Stein, http://www.lyra.org/

Re: cvs commit: apr CHANGES Makefile.in apr-config.in configure.in

Posted by Justin Erenkrantz <je...@apache.org>.
On Wed, Mar 27, 2002 at 09:14:34PM +0000, Thom May wrote:
> This should probably just be --installbuilddir - it seems that the autoconf
> code that handles --with-* is somewhat different to the code that handles
> --prefix&friends; you can't use
> --with-installbuilddir=${prefix}/etc/apache2/build ; this ends up in the
> Makefile as just /etc/apache2/build. 

I don't disagree with you, but it seems that there is no *automated*
way to get an --installbuilddir option via autoconf.

Our only options seem to be --with-* or --enable-*.  

Patches welcomed.  =)  -- justin

Re: cvs commit: apr CHANGES Makefile.in apr-config.in configure.in

Posted by Thom May <th...@planetarytramp.net>.
* jerenkrantz@apache.org (jerenkrantz@apache.org) wrote :
> jerenkrantz    02/03/09 11:26:13
> 
>   Modified:    .        CHANGES Makefile.in apr-config.in configure.in
>   Log:
>   Allow APR to install its own libtool into an installbuilddir.
>   
>   Add --with-installbuilddir to configure.
>   Add --apr-libtool option to apr-config so that third-parties can figure
>   out where this generated libtool is.
>   
This should probably just be --installbuilddir - it seems that the autoconf
code that handles --with-* is somewhat different to the code that handles
--prefix&friends; you can't use
--with-installbuilddir=${prefix}/etc/apache2/build ; this ends up in the
Makefile as just /etc/apache2/build. 

Cheers,
-Thom