Ashwani Saxena wrote:
Rich,
Please find the comments below.
On Mon, Feb 22, 2010 at 9:54 PM, Rich Megginson <[email protected]> wrote:
Ashwani Saxena wrote:
Rich,
Thanks a lot for your quick response.
BTW I was able to build c-sdk on both SOLARIS (sparc) 9 and 10 finally :)
After a long research i found that It requires libatomic.so to be
available in order to build c-sdk on SOLARIS.
As claimed on WEB
link?
[ASH] http://www.mozilla.org/projects/nspr/release-notes/nspr35.html
wow - those instructions are dated 1999.
that libatomic.so file is part of NSPR but i dont
see such file after i compiler NSS as NSPR. Fortunetely I had iplanet
server installed in the same machine and they provide this file. I
placed the same file in required location and was able to build c-LDAP
sdk.
Do you know which package provides libatomic.so? I believe you can use
the
pkgchk command.
[ASH] I ran pkgchk but it didnt give any information about this file. I have
copied this file from installation directory of iplant server.
How do I find out if package pkgname is installed?
pkginfo pkgname
or
pkginfo | grep pkgname
How do I list all of the files/directories provided by a package?
pkgchk -v pkgname e.g.
pkgchk -v SUNWfoo
How do I find out which package provides a file/directory?
pkgchk -l -p /path/to/fileordirectory e.g.
pkgchk -l -p /usr/lib/sparcv9/libfoo.so
I am using GUN GCC 3.4, Make 3.81 as per the prerequisite mentioned in
http://www.mozilla.org/directory/csdk.html, not the one provided by
Solaris.
That page has moved to https://wiki.mozilla.org/LDAP_C_SDK
[ASH] even in this page under "Obtaining Build Tools and Setting Up Your
Environment" section for SOLARIS it says using GCC (instead of the Sun/Forte
compiler).....
I guess it's not very clear that the section is "Solaris using GCC
(instead of the Sun/Forte compiler) "
I guess it should say "You are strongly encouraged to download and use
the free Forte compilers from Sun - however, if you are truly committed
to using GCC, you can if you are willing to jump through several hoops"
GNU make is definitely a pre-requisite. GNU GCC is not. I'm glad you got
it to work, but I'm curious as to where and how libatomic.so is used, and
where it comes from.
[ASH] This library was required to build c-SDK->ldap->libraries (e.g
libldif, libssldap, etc....).
Once i ran command "CC=gcc CCC=g++ ./configure --with-nss" from c-sdk, it
created autoconf.mk file under config folder and other required Makefile.
After that i ran "make" command from c-sdk folder to create c-SDK library
files.
Initilally it failed with following error:
ERROR:
/export/home/users/ashwani/mozldap-6.0.3/mozilla/directory/c-sdk/ldap/libraries/libldif
gcc -shared -Wl,-soname -Wl,libldif60.so -f libatomic.so -o libldif60.so
./line64.o
ld: warning: option -o appears more than once, first setting taken
ld: fatal: file libldif60.so: unknown file type
ld: fatal: File processing errors. No output written to libldif60.so
In order to fix this problem i made the following changes in c-sdk->config->
autoconf.mk file.
Change From :
DSO_LDOPTS = -shared -Wl,-soname -Wl,$(notdir $@) -f
$(ULTRASPARC_FILTER_LIBRARY)
Change To:
DSO_LDOPTS = -shared -Wl,-soname -Wl,-L$(notdir $@) -f
/usr/local/lib/$(ULTRASPARC_FILTER_LIBRARY)
Where "ULTRASPARC_FILTER_LIBRARY" set to "libatomic.so" by default. I added
"-L" before "$(notdir $@) " to avoid other errors. (Not sure whether thats
correct or not.)
BUT atfer making all these changes i was able to build c-SDK libraries.
NOW while testing LDAP connections i am able to test NON SSL connections
successfully whereas while testing SSL connections, i get core dump created.
There is no issue in codebase.
While debugging using GDB, i got the
CORE DUMP ERROR:
Program terminated with signal 11, Segmentation fault.
[New process 90516 ]
#0 0xff24278c in ?? () from ./libssldap60.so
(gdb)
Ok. Did you compile with with -g and not -O2? This stack trace is not
very helpful.
And it may be a lost cause. Even though you have been successful in
compiling everything with gcc, there may still be runtime problems such
as this and others which can be avoided by using the Sun Forte compilers.
Build Instruction for Solaris also same with minor config changes
required to consider libatomic.so file. If every dependency is in its
place then build instructions as same.
BUILD_ INSTRUCTIONS:
----------------------------
cd mozilla/security/nss
make nss_build_all
This (make nss_build_all) will also build nspr and other dependent
modules.
cd mozilla/directory/c-sdk
./configure --with-nss [--enable-64bit]
make
Regards,
Ashwani Saxena
On Mon, Feb 22, 2010 at 9:17 PM, Rich Megginson
<[email protected]> wrote:
ashwani saxena wrote:
Hi Rich,
This is with reference to :
http://www.mail-archive.com/[email protected]/msg00325.html
I am trying building Mozilla LDAP c-sdk (6.0.3) on Solaris 9.
I got the source code from following FTP locations.
NSPR - 4.7.0.0:
ftp://ftp.mozilla.org/pub/mozilla.org/nspr/releases/v4.7/src/nspr-4.7.tar.gz
NSS – 3.12.0.0:
ftp://ftp.mozilla.org/pub/mozilla.org/security/nss/releases/NSS_3_12_RTM/src/nss
-3.12.tar.gz
C-SDK – 6.0.3:
ftp://ftp.mozilla.org/pub/mozilla.org/directory/c-sdk/releases/v6.0.3/src/mozlda
p-6.0.3.tar.gz
While building LDAP c-sdk, Initially I got the error (ld: fatal:
Symbol referencing errors. No output written to libldif60.so) that I
was able to resolve.
Now I got the following error: (gcc: libatomic.so: No such file or
directory)
I goggled and found out the this library is part of NSPR but even
though I was able to build NSPR, NSS successfully but I didn’t find
this file.
Please let me know how to resolve this issue.
Please use the latest released versions of nspr, nss, and mozldap.
You are using gcc? What version of gcc? What build instructions are
you
following to build nspr and nss? I don't know how to build on Solaris
using
gcc. Ever since Sun released their compilers for free, I haven't even
tried
using gcc.
Regards,
Ashwani Saxena
_______________________________________________
dev-tech-ldap mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-tech-ldap