From:  Anton Bobrov <Anton.Bobrov@Sun.COM>
Date:  27 Dec 2005 17:38:17 Hong Kong Time

Re: Developers: Proposed configure & Makefile changes


Rich, nspr/nss switches sounds like a good idea tho i'm not
sure what nspr-config is. re rpms we include some examples
and sample conf files in our dev rpm like this :


tools go in /opt/sun/private/bin and libs go in /opt/sun/private/lib
and includes are under /opt/sun/private/include/ldap so there is no
clash nowhere. take care and happy new year!


Rich Megginson wrote:
> I'm going to be doing some work in the following areas, and I would like 
>  to get some input from ldapsdk developers, and especially the mozilla 
> and thunderbird developers to see how they build ldapsdk as part of 
> those products:
> 1) auto detection of nspr and nss, something like this
> if --without-nspr then
>     no nspr
> if --with-nspr=path OR (--with-nspr-inc=path AND --with-nspr-lib=path)
>     use the explicit paths provided by the user
> else if --with-system-nspr then
>     get nspr from OS
>     look for nspr-config using --with-nspr-prefix and 
> --with-nspr-exec-prefix
>     if that fails, look for nspr-config in PATH
>     if nspr-config is found, get cflags and ldflags from it
>     if that fails, look for pkg-config
>         see if pkg-config nspr is available
>         else use pkg-config mozilla-nspr
>         get cflags and ldflags from pkg-config
>     if both nspr-config and pkg-config fail, punt
> else
>     in-tree - look for nspr in ../../dist/*.OBJ - look for 
> include/nspr.h and lib/
>     if not in-tree, fall back to --with-system-nspr decision tree
> The detection of nss will be almost identical
> There are a few places in the Makefiles that need to change in order to 
> be able to pass in the CFLAGS and LDFLAGS.
> 2) Packaging of NSPR and NSS libs
> I don't think we need to do this anymore - I'd like to remove the 
> packaging of NSPR and NSS libs
> 3) RPM packaging
> We're planning to make the ldap sdk part of the base OS.  I'm proposing 
> to name the package "mozldap".  There will be 3 packages total:
> mozldap - contains just the shared libs (and any other run-time only files)
> mozldap-devel - contains the include files and mozldap-config and .pc file
> mozldap-tools - contains the command line tools
> The shared libs will go into /usr/lib, the tools into /usr/lib/mozldap 
> (so as not to conflict with the openldap versions), and the include 
> files into /usr/include/mozldap (ditto)
> Here is a .spec file excerpt:
> %files
> %defattr(-,root,root)
> %{_libdir}/
> %{_libdir}/
> %{_libdir}/
> %files tools
> %defattr(-,root,root)
> %{_libdir}/mozldap/ldapsearch
> %{_libdir}/mozldap/ldapmodify
> %{_libdir}/mozldap/ldapdelete
> %{_libdir}/mozldap/ldapcmp
> %{_libdir}/mozldap/ldapcompare
> %files devel
> %defattr(-,root,root)
> %{_libdir}/pkgconfig/mozldap.pc
> %{_bindir}/mozldap-config
> %dir %{_includedir}/mozldap
> %{_includedir}/mozldap/disptmpl.h
> %{_includedir}/mozldap/lber.h
> %{_includedir}/mozldap/ldap.h
> %{_includedir}/mozldap/ldap-standard.h
> %{_includedir}/mozldap/ldap-platform.h
> %{_includedir}/mozldap/ldap-extension.h
> %{_includedir}/mozldap/ldap-deprecated.h
> %{_includedir}/mozldap/ldap-to-be-deprecated.h
> %{_includedir}/mozldap/ldap_ssl.h
> %{_includedir}/mozldap/ldappr.h
> %{_includedir}/mozldap/srchpref.h
> _______________________________________________
> mozilla-directory mailing list