Hi Rainer,
I downloaded apr 1.4.2 and apr-util 1.3.10
For apr 1.4.2, I did "configure --prefix=/www/apache2/apr-httpd/"
For apr util 1.3.10, I did "configure --prefix=/www/apache2/apr-util-httpd/ 
--with-apr=/www/apache2/apr-httpd/ --with-ldap"

For httpd-2.2.17                                                     
configure \
"--prefix=/www/apache2" \
"--with-apr=/www/apache2/apr-httpd/" \
"--with-apr-util=/www/apache2/apr-util-httpd/" \
"--enable-so" \
"--enable-proxy" \
"--enable-ssl" \
"--enable-deflate" \
"--enable-rewrite" \
"--enable-headers" \
"--enable-cgid" \
"--enable-ldap" \
"--enable-authnz-ldap" \
"$@"

All compiled and installed fine.

But I got error when I started http,
# bin/apachectl start
Syntax error on line 115 of /www/apache2/conf/sites-enabled/www.lynden.com.conf:
Invalid command 'LDAP_Server', perhaps misspelled or defined by a module not 
included in the server configuration

I had line like "LDAP_Server 128.1.10.243" in config file.

I checked "util_ldap.c" is in the httpd -l listing
# /www/apache2/bin/httpd -l
Compiled in modules:
  core.c
  mod_authn_file.c
  mod_authn_default.c
  mod_authz_host.c
  mod_authz_groupfile.c
  mod_authz_user.c
  mod_authnz_ldap.c
  mod_authz_default.c
  mod_auth_basic.c
  mod_include.c
  mod_filter.c
  mod_deflate.c
  util_ldap.c
  mod_log_config.c
  mod_env.c
  mod_headers.c
  mod_setenvif.c
  mod_version.c
  mod_proxy.c
  mod_proxy_connect.c
  mod_proxy_ftp.c
  mod_proxy_http.c
  mod_proxy_scgi.c
  mod_proxy_ajp.c
  mod_proxy_balancer.c
  mod_ssl.c
  prefork.c
  http_core.c
  mod_mime.c
  mod_status.c
  mod_autoindex.c
  mod_asis.c
  mod_cgi.c
  mod_cgid.c
  mod_negotiation.c
  mod_dir.c
  mod_actions.c
  mod_userdir.c
  mod_alias.c
  mod_rewrite.c
  mod_so.c

But there is no mod_ldap.so module in apache libexec or modules directories

# ls /www/apache2/libexec
httpd.exp             mod_dir.so            mod_proxy.so
mod_access.so         mod_disk_cache.so     mod_proxy_connect.so
mod_actions.so        mod_env.so            mod_proxy_ftp.so
mod_alias.so          mod_expires.so        mod_proxy_http.so
mod_asis.so           mod_ext_filter.so     mod_rewrite.so
mod_auth.so           mod_file_cache.so     mod_setenvif.so
mod_auth_anon.so      mod_headers.so        mod_speling.so
mod_auth_dbm.so       mod_imap.so           mod_ssl.so
mod_auth_digest.so    mod_include.so        mod_status.so
mod_auth_gss.so       mod_info.so           mod_suexec.so
mod_autoindex.so      mod_log_config.so     mod_unique_id.so
mod_cache.so          mod_log_forensic.so   mod_userdir.so
mod_cern_meta.so      mod_mem_cache.so      mod_usertrack.so
mod_cgi.so            mod_mime.so           mod_version.so
mod_dav.so            mod_mime_magic.so     mod_vhost_alias.so
mod_dav_fs.so         mod_negotiation.so
mod_deflate.so        mod_perl.so

Can you or someone tell me what is missing?

Thanks
David Long
-----Original Message-----
From: Rainer Jung [mailto:rainer.j...@kippdata.de] 
Sent: Monday, December 27, 2010 2:14 PM
To: users@httpd.apache.org
Subject: Re: FW: [us...@httpd] help on compile 2.2.17 with ldap support

Hi David,

On 27.12.2010 22:32, David Long wrote:

Please keep the discussion on list.

> Thanks for your help to point me to apr and apr-util.
>
> Do you know the config switch for ldap support in apr-util?
>
> On Apache websie, it says.
> # Build and install apr 1.2
> cd srclib/apr
> ./configure --prefix=/usr/local/apr-httpd/
> make
> make install
>
> # Build and install apr-util 1.2
> cd ../apr-util
> ./configure --prefix=/usr/local/apr-util-httpd/ 
> --with-apr=/usr/local/apr-httpd/
> make
> make install

Latest APR ist 1.4.2, latest APR-UTIl ist 1.3.10, see 
http://apr.apache.org/.

To learn about possible configure flags it always is a good idea to run

./configure --help

If you do that for apr-util, you would see e.g.

...
Optional Packages:
   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
...
   --with-lber=library     lber library to use
   --with-ldap-include=path  path to ldap include files with trailing slash
   --with-ldap-lib=path    path to ldap lib file
   --with-ldap=library     ldap library to use
...

Yes, the help output could be a bit more explicit, but to build apr-util 
with ldap support based on the OS provided ldap libraries, you would 
simply add "--with-ldap" to the apr-util confugure flags.

> # Configure httpd
> cd ../../
> ./configure --with-apr=/usr/local/apr-httpd/ 
> --with-apr-util=/usr/local/apr-util-httpd/

Here you have to choose the apr and apr-util paths where you instaled 
the new apr resp. apr-util.

> It doesn't tell me how to build for ldap support.
>
> Is it just "--enable-ldap --enable-authnz-ldap"?

Yes.

> Also in httpd configure, Will I still need --prefix=/www/apache2? Or 
> /usr/local/apr-httpd is my apache home directory.

You don't need it, but you might want it. It tells the build process, 
into which directory you want to install the result. Same when calling 
configure for apr and apr-util.

Regards,

Rainer

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
   "   from the digest: users-digest-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
   "   from the digest: users-digest-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org

Reply via email to