[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: OT: $SVN envvars Re: svn 1.8 debugging-compilation-serf-configure problem because of 1.6 Ubuntu install

From: Gabriela Gibson <gabriela.gibson_at_gmail.com>
Date: Mon, 04 Mar 2013 22:33:23 +0000

On 04/03/13 19:44, Daniel Shahaf wrote:

> Do you use the system's apr (e.g., /usr/lib/libapr-1.so) or compile your
> own? If the former you should install the "apr-dev" (or similar)
> package, if the latter it appears you need to pass --with-apr to
> serf/serfmake (or serf/configure if you use that).

I guess I should tell you how my setup looks. I'm possibly repeating
stuff from earlier emails, because I'm trying to put all the info in
one place.

I started with an installed package of svn for Ubuntu 12.04 Desktop
on a clean operating system install:

   g_at_musashi:~$ dpkg -l | grep subversion
   ii subversion 1.6.17dfsg-3ubuntu3 Advanced version control system

Beyond this, I've been working with a trunk and the dependencies as
downloaded by get-deps.sh - pretty much the classic minimal dev env.
I chose to do this, because I thought one way to assist the project
was to look through the eyes of someone coming new to Subversion dev
as much as possible.

This weekend, in order to tackle the compilation of Serf, I did "sudo
make install" in the apr and apr-util directories, and compiled Serf
with the following commands:
   ## Serf compile command
   ./configure
   make
   sudo make install

OTOH, when I tried to use your suggestion with ./serfmake, I get a
failure

<quote>
   g_at_musashi:~/trunk3/serf$ sudo ./serfmake --prefix=/usr/local/serf \
               build check install
ERROR: exception:
ERROR: A configuration script was not found: apr-1-config

serfmake [cmd] [options]
Commands:
         build Builds (default)
         check Runs test cases
         install Installs serf into PREFIX
         clean Cleans
Options:
         --with-apr=PATH prefix for installed APR and APR-util
                                 (needs apr-1-config and apu-1-config;
will look in PATH)
         --with-gssapi=PATH build serf with GSSAPI support
                                 (needs krb5-config; will look in PATH/bin)
         --prefix=PATH install serf into PATH (default:
/usr/local)
Quick guide:
         serfmake --prefix=/usr/local/serf --with-apr=/usr/local/apr install
g_at_musashi:~/trunk3/serf$
</quote>

Providing --with-apr:
   g_at_musashi:~/trunk3/serf$ sudo ./serfmake --prefix=/usr/local/serf \
           --with-apr=/usr/local/apr build check install
works.

So that's the behaviour of the serf compile. Sorry for the
wordy-ness, but I'm trying to get everything into one place!

What I've also found during my experiments at the weekend is that
apr-related entries in LD_FLAGS are edited while configure runs. So:

   LD_FLAGS="-L/usr/local/serf/lib -L/usr/local/apr/lib" ./configure \
           --enable-maintainer-mode --with-serf=/usr/local/serf

failed. Examining config.log showed that the failure appeared to occur
in the link test, and that the entry for "-L/usr/local/apr/lib" has been
removed.

The only way I could make the serf link test pass (and also add that
"-L/usr/local/apr/lib" flag) was to supply "--with-apr --with-apr-util" and
that was what my patch documented.

Whether this is "undocumented behaviour", "a bug in the build system",
"there is a need to document a requirement for apr-dev", or "my
retarded/invalid build environment" I don't feel sufficiently
experienced to judge. I just thought - this isn't right, so submit a
patch.

It might not be the correct fix :)

Ben wrote
> In your case if you've installed serf in /usr/local/serf, I'd try
> building without any --with-serf option or --with-serf=yes. Failing
> that try the same build but with the following environment variable
> set:
> export PKG_CONFIG_PATH=/usr/local/serf/lib/pkgconfig

I'm not familiar with pkgconfig, so I need to educate myself.

I tried yesterday without any option, and serf isn't tested for.

I've also tried the --with-serf=yes suggestion:
   g_at_musashi:~/trunk3$ ./configure --with-serf=yes --enable-maintainer-mode
This failed (as in configure warned that serf hadn't been found).

I've further tried with the variable:
   export PKG_CONFIG_PATH=/usr/local/serf/lib/pkgconfig
   ./configure --with-serf=yes --enable-maintainer-mode
and this succeeds.

G
Received on 2013-03-04 23:33:44 CET

This is an archived mail posted to the Subversion Dev mailing list.