Working Around an Installed Copy of APR

The Apache httpd 2 build system expects to find a copy of the Apache Portable Runtime (APR) and its utility library (APR-Util) under srclib in the source tree. However, if an installed copy of APR is already present on the system, the build system will use that instead. As far as I can see, there currently is no way to force the httpd build system to use the bundled APR instead of the installed one. This is an insurmountable problem in situations where, for instance, the APR that came with your FreeBSD ports when you installed Subversion is too old to build httpd-trunk.

This is a problem that should be solved by that same build system: it needs to check more thorougly whether the installed APR fits the bill, and it should have an option (like –with-bundled-apr) that forces building against the included source tree regardless of what is already installed. However, I currently lack both auto-fu and round tuits to come up with a fix. Fortunately, all the httpd configure script checks for is the presence of the APR and APR-Util configuration scripts, so renaming /usr/local/bin/ap{r,u}-1-config to something inocuous makes the problem go away.

Be Sociable, Share!