php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #81538 --with-ldap=[DIR] appears to be getting ignored
Submitted: 2021-10-18 17:32 UTC Modified: 2021-10-20 09:03 UTC
From: fred5 at originsystems dot co dot za Assigned:
Status: Open Package: Compile Failure
PHP Version: 8.0.11 OS: CentOS 7.9
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please — but make sure to vote on the bug!
Your email address:
MUST BE VALID
Solve the problem:
25 + 14 = ?
Subscribe to this entry?

 
 [2021-10-18 17:32 UTC] fred5 at originsystems dot co dot za
Description:
------------
My PHP configure continues to fail on IMAP.

-------------------------------------------------------------------------------------------
PKG_CONFIG_PATH=/DevRoot/temp/osWEB/build/Python-3.9.1/lib/pkgconfig:/DevRoot/temp/osWEB/build/libxml2-2.9.9/lib64/pkgconfig:/DevRoot/temp/osWEB/build/libxslt-1.1.33/lib/pkgconfig:/DevRoot/temp/osWEB/build/nghttp2-1.44.0/lib/pkgconfig:/DevRoot/temp/osWEB/build/openssl-3.0.0/lib64/pkgconfig:/DevRoot/temp/osWEB/build/curl-7.79.1/lib64/pkgconfig:/DevRoot/temp/osWEB/build/libzip/lib64/pkgconfig:/DevRoot/temp/osWEB/build/icu4c-66_1/lib64/pkgconfig:/DevRoot/temp/osWEB/build/freetype-2.11.0/lib64/pkgconfig:/DevRoot/temp/osWEB/build/libwebp-1.2.0/lib64/pkgconfig:/DevRoot/temp/osWEB/build/oniguruma-6.9.7.1/lib64/pkgconfig:/DevRoot/temp/osWEB/build/apr-1.7.0/lib64/pkgconfig:/DevRoot/temp/osWEB/build/apr-util-1.6.1/lib64/pkgconfig:/DevRoot/temp/osWEB/build/pcre-8.45/lib64/pkgconfig:/DevRoot/temp/osWEB/build/pcre2-10.37/lib64/pkgconfig:/DevRoot/temp/osWEB/build/libssh2-1.10.0/lib64/pkgconfig:/DevRoot/temp/osWEB/build/openldap-2.5.8/lib64/pkgconfig

./configure  --disable-all --prefix=/RootFolder/webserver/resources/php --bindir=/RootFolder/webserver/resources/php/bin --sbindir=/RootFolder/webserver/resources/php/sbin --with-config-file-path=/RootFolder/webserver/resources/php/lib/osDo-not-modify-this-php_ini --with-config-file-scan-dir=/RootFolder/webserver/configuration/php/ini --disable-debug --enable-opcache=shared --enable-huge-code-pages --enable-intl=shared --enable-ftp=shared --enable-session=shared --enable-xml=shared --with-apxs2=/RootFolder/webserver/resources/apache2/bin/apxs --with-layout=GNU --enable-filter=shared --with-zlib=shared --enable-simplexml=shared --enable-dom=shared --with-openssl=shared --with-readline=shared --with-iconv=shared --enable-phar=shared --enable-xmlwriter=shared --enable-xmlreader=shared --enable-bcmath=shared --with-bz2=shared --enable-calendar=shared --enable-ctype=shared --with-curl --enable-exif=shared --enable-fileinfo=shared --enable-ftp=shared --enable-gd --with-jpeg --with-webp --with-freetype --with-mysqli=shared --disable-phpdbg --disable-phpdbg-webhelper --enable-fpm=shared --with-fpm-systemd --with-fpm-acl --with-gettext=shared --with-libxml --with-imap-ssl=/DevRoot/temp/osWEB/build/openssl-3.0.0 --with-imap=/DevRoot/temp/osWEB/build/imap-2007f --with-ldap=/DevRoot/temp/osWEB/build/openldap-2.5.8 --with-ldap-sasl=/DevRoot/temp/osWEB/build/openldap-2.5.8 --with-kerberos --enable-posix=shared --enable-soap=shared --enable-sockets=shared --with-tidy=shared,/DevRoot/temp/osWEB/build/libtidy --enable-tokenizer=shared --with-xsl=shared --enable-mbstring=shared --with-zip --with-external-pcre
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for a sed that does not truncate output... /bin/sed
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
....

There is no further output containing the text "ldap"

and the configure fails with this message:
-------------------------------------------
checking whether build with IMAP works... configure: error: build test failed. Please check the config.log for details.


When I check the config.log the first reference I see to "ldap" is the following error:
---------------------------------------------------------------------------------------
/RootFolder/webserver/resources/library/libc-client.a(osdep.o): In function `ssl_onceonlyinit':
/DevRoot/temp/osWEB/source/imap-2007f/c-client/osdep.c:337: warning: the use of `tmpnam' is dangerous, better use `mkstemp'
/bin/ld: warning: libssl.so.10, needed by //usr/lib64/libldap-2.4.so.2, may conflict with libssl.so.3
/bin/ld: /RootFolder/webserver/resources/library/libc-client.a(osdep.o): undefined reference to symbol 'SSL_library_init@@libssl.so.10'
//usr/lib64/libssl.so.10: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status


It appears that even  though I have the following switch pointing at my compiled version of ldap
---------------------------------------------------------------------
--with-ldap=/DevRoot/temp/osWEB/build/openldap-2.5.8


It is being ignored and the default old OS version is being referenced as follows
----------------------------------------------------------------------------------
/bin/ld: warning: libssl.so.10, needed by //usr/lib64/libldap-2.4.so.2, may conflict with libssl.so.3


I have looked inside the configure file and tried to debug the issue but it doesn't seem to even be reaching the location which looks relevant to me - shown here (I've tried to echo to a file after the first line but it never seems to get hit at all) 
-----------------------------------------------------------------------------------

php_with_ldap=no

{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDAP support" >&5
$as_echo_n "checking for LDAP support... " >&6; }


# Check whether --with-ldap was given.
if test "${with_ldap+set}" = set; then :
  withval=$with_ldap; PHP_LDAP=$withval
else

  PHP_LDAP=no
  test "$PHP_ENABLE_ALL" && PHP_LDAP=$PHP_ENABLE_ALL

fi

I'm really struggling with this and would appreciate any help I can get - thanks!
 


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2021-10-18 21:26 UTC] fred5 at originsystems dot co dot za
or should I be leaving imap out of the equation and replacing the functionality via curl?

(I ask this as imap2007f is super old and what I'm reading shows that people seem generally to feel it's dodo material)
 [2021-10-19 17:42 UTC] fred5 at originsystems dot co dot za
The reason openldap was never reached is I believe because imap was being processed first and failing.

I have disabled imap and the build is now working fine.

I would however really like to know how imap fits in to the PHP roadmap if at all.
 [2021-10-20 09:03 UTC] cmb@php.net
> I would however really like to know how imap fits in to the PHP
> roadmap if at all.

See bug #78572 for some discussion on this topic.  For me, the
biggest blocker of unbundling the imap extension is that Windows
mail() tests using SMTP still require the imap extension to check
whether the mails have been properly received.  These could
probably be rewritten to use a fake SMTP server as part of the
test suite.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 18 16:01:29 2024 UTC