[OpenSIPS-Users] error complie LDAP modules

Leon Li Leon.Li at aarnet.edu.au
Fri May 29 04:03:22 CEST 2009


Hi Bogdan,

I have upgrade libldap to 2.3. 

However, there are some other errors pop up. Hope you can help.

make[1]: Entering directory `/home/lli/opensips_1_5/modules/ldap'
make[1]: Leaving directory `/home/lli/opensips_1_5/modules/ldap'
make[1]: Entering directory `/home/lli/opensips_1_5/modules/ldap'
Compiling iniparser.c
gcc -fPIC -DPIC -g -O9 -funroll-loops -Wcast-align -Wall
-minline-all-stringops -falign-loops -ftree-vectorize -mtune=nocona
-Wold-style-definition -Wmissing-field-initializers -Wredundant-decls
-DMOD_NAME='"ldap"'    -DNAME='"opensips"' -DVERSION='"1.5.1-notls"'
-DARCH='"x86_64"' -DOS='"linux"' -DCOMPILER='"gcc 4.1.2"' -D__CPU_x86_64
-D__OS_linux -D__SMP_yes -DCFG_DIR='"/usr/local/etc/opensips/"'
-DPKG_MALLOC -DSHM_MEM  -DSHM_MMAP -DUSE_IPV6 -DUSE_MCAST -DUSE_TCP
-DDISABLE_NAGLE -DHAVE_RESOLV_RES -DSTATISTICS -DCHANGEABLE_DEBUG_LEVEL
-DF_MALLOC  -DSVNREVISION='"2:5632M"'  -DFAST_LOCK -DADAPTIVE_WAIT
-DADAPTIVE_WAIT_LOOPS=1024  -DHAVE_GETHOSTBYNAME2 -DHAVE_UNION_SEMUN
-DHAVE_SCHED_YIELD -DHAVE_MSG_NOSIGNAL -DHAVE_MSGHDR_MSG_CONTROL
-DHAVE_ALLOCA_H -DHAVE_TIMEGM -DHAVE_EPOLL -DHAVE_SIGIO_RT -DHAVE_SELECT
-c iniparser.c -o iniparser.o
Compiling ldap_api_fn.c
gcc -fPIC -DPIC -g -O9 -funroll-loops -Wcast-align -Wall
-minline-all-stringops -falign-loops -ftree-vectorize -mtune=nocona
-Wold-style-definition -Wmissing-field-initializers -Wredundant-decls
-DMOD_NAME='"ldap"'    -DNAME='"opensips"' -DVERSION='"1.5.1-notls"'
-DARCH='"x86_64"' -DOS='"linux"' -DCOMPILER='"gcc 4.1.2"' -D__CPU_x86_64
-D__OS_linux -D__SMP_yes -DCFG_DIR='"/usr/local/etc/opensips/"'
-DPKG_MALLOC -DSHM_MEM  -DSHM_MMAP -DUSE_IPV6 -DUSE_MCAST -DUSE_TCP
-DDISABLE_NAGLE -DHAVE_RESOLV_RES -DSTATISTICS -DCHANGEABLE_DEBUG_LEVEL
-DF_MALLOC  -DSVNREVISION='"2:5632M"'  -DFAST_LOCK -DADAPTIVE_WAIT
-DADAPTIVE_WAIT_LOOPS=1024  -DHAVE_GETHOSTBYNAME2 -DHAVE_UNION_SEMUN
-DHAVE_SCHED_YIELD -DHAVE_MSG_NOSIGNAL -DHAVE_MSGHDR_MSG_CONTROL
-DHAVE_ALLOCA_H -DHAVE_TIMEGM -DHAVE_EPOLL -DHAVE_SIGIO_RT -DHAVE_SELECT
-c ldap_api_fn.c -o ldap_api_fn.o
Compiling ldap_connect.c
gcc -fPIC -DPIC -g -O9 -funroll-loops -Wcast-align -Wall
-minline-all-stringops -falign-loops -ftree-vectorize -mtune=nocona
-Wold-style-definition -Wmissing-field-initializers -Wredundant-decls
-DMOD_NAME='"ldap"'    -DNAME='"opensips"' -DVERSION='"1.5.1-notls"'
-DARCH='"x86_64"' -DOS='"linux"' -DCOMPILER='"gcc 4.1.2"' -D__CPU_x86_64
-D__OS_linux -D__SMP_yes -DCFG_DIR='"/usr/local/etc/opensips/"'
-DPKG_MALLOC -DSHM_MEM  -DSHM_MMAP -DUSE_IPV6 -DUSE_MCAST -DUSE_TCP
-DDISABLE_NAGLE -DHAVE_RESOLV_RES -DSTATISTICS -DCHANGEABLE_DEBUG_LEVEL
-DF_MALLOC  -DSVNREVISION='"2:5632M"'  -DFAST_LOCK -DADAPTIVE_WAIT
-DADAPTIVE_WAIT_LOOPS=1024  -DHAVE_GETHOSTBYNAME2 -DHAVE_UNION_SEMUN
-DHAVE_SCHED_YIELD -DHAVE_MSG_NOSIGNAL -DHAVE_MSGHDR_MSG_CONTROL
-DHAVE_ALLOCA_H -DHAVE_TIMEGM -DHAVE_EPOLL -DHAVE_SIGIO_RT -DHAVE_SELECT
-c ldap_connect.c -o ldap_connect.o
Compiling ldap_escape.c
gcc -fPIC -DPIC -g -O9 -funroll-loops -Wcast-align -Wall
-minline-all-stringops -falign-loops -ftree-vectorize -mtune=nocona
-Wold-style-definition -Wmissing-field-initializers -Wredundant-decls
-DMOD_NAME='"ldap"'    -DNAME='"opensips"' -DVERSION='"1.5.1-notls"'
-DARCH='"x86_64"' -DOS='"linux"' -DCOMPILER='"gcc 4.1.2"' -D__CPU_x86_64
-D__OS_linux -D__SMP_yes -DCFG_DIR='"/usr/local/etc/opensips/"'
-DPKG_MALLOC -DSHM_MEM  -DSHM_MMAP -DUSE_IPV6 -DUSE_MCAST -DUSE_TCP
-DDISABLE_NAGLE -DHAVE_RESOLV_RES -DSTATISTICS -DCHANGEABLE_DEBUG_LEVEL
-DF_MALLOC  -DSVNREVISION='"2:5632M"'  -DFAST_LOCK -DADAPTIVE_WAIT
-DADAPTIVE_WAIT_LOOPS=1024  -DHAVE_GETHOSTBYNAME2 -DHAVE_UNION_SEMUN
-DHAVE_SCHED_YIELD -DHAVE_MSG_NOSIGNAL -DHAVE_MSGHDR_MSG_CONTROL
-DHAVE_ALLOCA_H -DHAVE_TIMEGM -DHAVE_EPOLL -DHAVE_SIGIO_RT -DHAVE_SELECT
-c ldap_escape.c -o ldap_escape.o
Compiling ldap_exp_fn.c
gcc -fPIC -DPIC -g -O9 -funroll-loops -Wcast-align -Wall
-minline-all-stringops -falign-loops -ftree-vectorize -mtune=nocona
-Wold-style-definition -Wmissing-field-initializers -Wredundant-decls
-DMOD_NAME='"ldap"'    -DNAME='"opensips"' -DVERSION='"1.5.1-notls"'
-DARCH='"x86_64"' -DOS='"linux"' -DCOMPILER='"gcc 4.1.2"' -D__CPU_x86_64
-D__OS_linux -D__SMP_yes -DCFG_DIR='"/usr/local/etc/opensips/"'
-DPKG_MALLOC -DSHM_MEM  -DSHM_MMAP -DUSE_IPV6 -DUSE_MCAST -DUSE_TCP
-DDISABLE_NAGLE -DHAVE_RESOLV_RES -DSTATISTICS -DCHANGEABLE_DEBUG_LEVEL
-DF_MALLOC  -DSVNREVISION='"2:5632M"'  -DFAST_LOCK -DADAPTIVE_WAIT
-DADAPTIVE_WAIT_LOOPS=1024  -DHAVE_GETHOSTBYNAME2 -DHAVE_UNION_SEMUN
-DHAVE_SCHED_YIELD -DHAVE_MSG_NOSIGNAL -DHAVE_MSGHDR_MSG_CONTROL
-DHAVE_ALLOCA_H -DHAVE_TIMEGM -DHAVE_EPOLL -DHAVE_SIGIO_RT -DHAVE_SELECT
-c ldap_exp_fn.c -o ldap_exp_fn.o
Compiling ldap_mod.c
gcc -fPIC -DPIC -g -O9 -funroll-loops -Wcast-align -Wall
-minline-all-stringops -falign-loops -ftree-vectorize -mtune=nocona
-Wold-style-definition -Wmissing-field-initializers -Wredundant-decls
-DMOD_NAME='"ldap"'    -DNAME='"opensips"' -DVERSION='"1.5.1-notls"'
-DARCH='"x86_64"' -DOS='"linux"' -DCOMPILER='"gcc 4.1.2"' -D__CPU_x86_64
-D__OS_linux -D__SMP_yes -DCFG_DIR='"/usr/local/etc/opensips/"'
-DPKG_MALLOC -DSHM_MEM  -DSHM_MMAP -DUSE_IPV6 -DUSE_MCAST -DUSE_TCP
-DDISABLE_NAGLE -DHAVE_RESOLV_RES -DSTATISTICS -DCHANGEABLE_DEBUG_LEVEL
-DF_MALLOC  -DSVNREVISION='"2:5632M"'  -DFAST_LOCK -DADAPTIVE_WAIT
-DADAPTIVE_WAIT_LOOPS=1024  -DHAVE_GETHOSTBYNAME2 -DHAVE_UNION_SEMUN
-DHAVE_SCHED_YIELD -DHAVE_MSG_NOSIGNAL -DHAVE_MSGHDR_MSG_CONTROL
-DHAVE_ALLOCA_H -DHAVE_TIMEGM -DHAVE_EPOLL -DHAVE_SIGIO_RT -DHAVE_SELECT
-c ldap_mod.c -o ldap_mod.o
Compiling ld_session.c
gcc -fPIC -DPIC -g -O9 -funroll-loops -Wcast-align -Wall
-minline-all-stringops -falign-loops -ftree-vectorize -mtune=nocona
-Wold-style-definition -Wmissing-field-initializers -Wredundant-decls
-DMOD_NAME='"ldap"'    -DNAME='"opensips"' -DVERSION='"1.5.1-notls"'
-DARCH='"x86_64"' -DOS='"linux"' -DCOMPILER='"gcc 4.1.2"' -D__CPU_x86_64
-D__OS_linux -D__SMP_yes -DCFG_DIR='"/usr/local/etc/opensips/"'
-DPKG_MALLOC -DSHM_MEM  -DSHM_MMAP -DUSE_IPV6 -DUSE_MCAST -DUSE_TCP
-DDISABLE_NAGLE -DHAVE_RESOLV_RES -DSTATISTICS -DCHANGEABLE_DEBUG_LEVEL
-DF_MALLOC  -DSVNREVISION='"2:5632M"'  -DFAST_LOCK -DADAPTIVE_WAIT
-DADAPTIVE_WAIT_LOOPS=1024  -DHAVE_GETHOSTBYNAME2 -DHAVE_UNION_SEMUN
-DHAVE_SCHED_YIELD -DHAVE_MSG_NOSIGNAL -DHAVE_MSGHDR_MSG_CONTROL
-DHAVE_ALLOCA_H -DHAVE_TIMEGM -DHAVE_EPOLL -DHAVE_SIGIO_RT -DHAVE_SELECT
-c ld_session.c -o ld_session.o
Linking ldap.so
gcc -shared  -Wl,-O2 -Wl,-E    iniparser.o ldap_api_fn.o ldap_connect.o
ldap_escape.o ldap_exp_fn.o ldap_mod.o ld_session.o  -lldap -o ldap.so
/usr/bin/ld: skipping incompatible /usr/lib/libldap.so when searching
for -lldap
/usr/bin/ld: skipping incompatible /usr/lib/libldap.a when searching for
-lldap
/usr/bin/ld: cannot find -lldap
collect2: ld returned 1 exit status
make[1]: *** [ldap.so] Error 1
make[1]: Leaving directory `/home/lli/opensips_1_5/modules/ldap'
make: *** [modules] Error 2

Thanks
Leon

-----Original Message-----
From: Bogdan-Andrei Iancu [mailto:bogdan at voice-system.ro] 
Sent: Thursday, 28 May 2009 1:42 AM
To: Leon Li
Cc: users at lists.opensips.org
Subject: Re: [OpenSIPS-Users] error complie LDAP modules

Hi Leon,

Found the problem - it seams that the older version of openldap-devel 
defines ldap_url_search() which overlaps with the the same function 
defined in the ldap module.

Can you try to install a newer version of openldap-devel (2.1 or higher)
?

Regards,
Bogdan


Leon Li wrote:
> Hi Bogdan,
>
> Please see the enclosed ldap.h file.
>
> Thanks
> Leon 
>
> -----Original Message-----
> From: Bogdan-Andrei Iancu [mailto:bogdan at voice-system.ro] 
> Sent: Wednesday, 27 May 2009 1:10 AM
> To: Leon Li
> Cc: users at lists.opensips.org
> Subject: Re: [OpenSIPS-Users] error complie LDAP modules
>
> Hi Leon,
>
> Could you send me your /usr/include/ldap.h  file ?
>
> Regards,
> Bogdan
>
>
> Leon Li wrote:
>   
>> Hi Bogdan,
>>
>> I think it is 2.0.27.
>>
>> Looking in Installed Packages:
>> Name   : openldap
>> Arch   : i386
>> Version: 2.0.27
>> Release: 23
>> Size   : 1.15 MB
>> Group  : System Environment/Daemons
>> Repo   : Locally Installed
>> Summary: The configuration files, libraries, and documentation for
>> OpenLDAP.
>>
>> Also, there is "/usr/include/ldap.h" in the system already.
>>
>> Thanks,
>> Leon 
>>
>>
>> -----Original Message-----
>> From: Bogdan-Andrei Iancu [mailto:bogdan at voice-system.ro] 
>> Sent: Monday, 25 May 2009 9:18 PM
>> To: Leon Li
>> Cc: users at lists.opensips.org
>> Subject: Re: [OpenSIPS-Users] error complie LDAP modules
>>
>> Hi Leon,
>>
>> what version of libldap2-dev do you have on your system ? Is the 
>> "/usr/include/ldap.h" file part of that package ?
>>
>> Regards,
>> Bogdan
>>
>> Leon Li wrote:
>>   
>>     
>>> Hi,
>>>
>>> I have error when run make all to compile OpenSIPs from a Redhat 
>>> machine. I include LDAP module which returns error.
>>>
>>> $ make all
>>>
>>> .....
>>>
>>> make[1]: Entering directory
>>>     
>>>       
>> `/home/lli/opensips-1.5.1-tls/modules/ldap'
>>   
>>     
>>> make[1]: Leaving directory
>>>       
> `/home/lli/opensips-1.5.1-tls/modules/ldap'
>   
>>> make[1]: Entering directory
>>>     
>>>       
>> `/home/lli/opensips-1.5.1-tls/modules/ldap'
>>   
>>     
>>> Compiling iniparser.c
>>>
>>> gcc -fPIC -DPIC -g -O9 -funroll-loops -Wcast-align -Wall 
>>> -minline-all-stringops -falign-loops -mcpu=pentium4 
>>> -DMOD_NAME='"ldap"' -DNAME='"opensips"' -DVERSION='"1.5.1-notls"' 
>>> -DARCH='"i386"' -DOS='"linux"' -DCOMPILER='"gcc 3.2.3"' -D__CPU_i386

>>> -D__OS_linux -D__SMP_yes -DCFG_DIR='"/usr/local/etc/opensips/"' 
>>> -DPKG_MALLOC -DSHM_MEM -DSHM_MMAP -DUSE_IPV6 -DUSE_MCAST -DUSE_TCP 
>>> -DDISABLE_NAGLE -DHAVE_RESOLV_RES -DSTATISTICS 
>>> -DCHANGEABLE_DEBUG_LEVEL -DF_MALLOC -DFAST_LOCK -DADAPTIVE_WAIT 
>>> -DADAPTIVE_WAIT_LOOPS=1024 -DHAVE_GETHOSTBYNAME2 -DHAVE_UNION_SEMUN 
>>> -DHAVE_SCHED_YIELD -DHAVE_MSG_NOSIGNAL -DHAVE_MSGHDR_MSG_CONTROL 
>>> -DHAVE_ALLOCA_H -DHAVE_TIMEGM -DHAVE_SIGIO_RT -DHAVE_SELECT -c 
>>> iniparser.c -o iniparser.o
>>>
>>> Compiling ldap_api_fn.c
>>>
>>> gcc -fPIC -DPIC -g -O9 -funroll-loops -Wcast-align -Wall 
>>> -minline-all-stringops -falign-loops -mcpu=pentium4 
>>> -DMOD_NAME='"ldap"' -DNAME='"opensips"' -DVERSION='"1.5.1-notls"' 
>>> -DARCH='"i386"' -DOS='"linux"' -DCOMPILER='"gcc 3.2.3"' -D__CPU_i386

>>> -D__OS_linux -D__SMP_yes -DCFG_DIR='"/usr/local/etc/opensips/"' 
>>> -DPKG_MALLOC -DSHM_MEM -DSHM_MMAP -DUSE_IPV6 -DUSE_MCAST -DUSE_TCP 
>>> -DDISABLE_NAGLE -DHAVE_RESOLV_RES -DSTATISTICS 
>>> -DCHANGEABLE_DEBUG_LEVEL -DF_MALLOC -DFAST_LOCK -DADAPTIVE_WAIT 
>>> -DADAPTIVE_WAIT_LOOPS=1024 -DHAVE_GETHOSTBYNAME2 -DHAVE_UNION_SEMUN 
>>> -DHAVE_SCHED_YIELD -DHAVE_MSG_NOSIGNAL -DHAVE_MSGHDR_MSG_CONTROL 
>>> -DHAVE_ALLOCA_H -DHAVE_TIMEGM -DHAVE_SIGIO_RT -DHAVE_SELECT -c 
>>> ldap_api_fn.c -o ldap_api_fn.o
>>>
>>> In file included from ldap_api_fn.c:40:
>>>
>>> ldap_api_fn.h:57: conflicting types for `ldap_url_search'
>>>
>>> /usr/include/ldap.h:1523: previous declaration of `ldap_url_search'
>>>
>>> make[1]: *** [ldap_api_fn.o] Error 1
>>>
>>> make[1]: Leaving directory
>>>       
> `/home/lli/opensips-1.5.1-tls/modules/ldap'
>   
>>> make: *** [modules] Error 2
>>>
>>> Anyone can help?
>>>
>>> Thanks
>>>
>>> Leon
>>>
>>>
>>>     
>>>       
>
------------------------------------------------------------------------
>   
>>   
>>     
>>> _______________________________________________
>>> Users mailing list
>>> Users at lists.opensips.org
>>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>>   
>>>     
>>>       
>>   
>>     
>
>   




More information about the Users mailing list