Mozilla seems to need a c++ lib member.

after installing mozilla and running it I get
----------
[root@c447997-a package]# ../mozilla
.//run-mozilla.sh .../mozilla-bin
MOZILLA_FIVE_HOME=/usr/local/mozilla/package
  LD_LIBRARY_PATH=/usr/local/mozilla/package
       SHLIB_PATH=/usr/local/mozilla/package
          LIBPATH=/usr/local/mozilla/package
      MOZ_PROGRAM=./mozilla-bin
      MOZ_TOOLKIT=
        moz_debug=0
     moz_debugger=
./mozilla-bin: error in loading shared libraries
libstdc++-libc6.1-1.so.2: cannot open shared object file: No such file
or directory
-----------------

1) Am I right in my assumption that Mozilla is looking  for
libstdc++-libc6.1-1.so.2

2) I did a find for this lib member and it is not on my TL.  "g++
--version"  results in egcs-2.91.60  so aparently I have a c++ compiler.
Why would TL have give me the compiler and not the standard run
libraries? I don't get it?

3) I did a find for *libc6* and nothing was found.

Find on libstdc++* resulted in
/usr/lib/libstdc++.so.2.7.2
/usr/lib/libstdc++.so.27
/usr/lib/libstdc++.a
/usr/lib/libstdc++.so.2.9
/usr/lib/g++-2723/libstdc++.a

So, do I need to install something to get mozilla to run? Just the one
library member? An entire library of c++ members?

A search on google results in .......

 RPM resource libstdc++-libc6.1-1.so.2
...RPM resource libstdc++-libc6.1-1.so.2...
...shared libraries SuSE 6.2 i386 libstdc++-2.95.2-2mdk.i586 GNU c++...
rpmfind.net/linux/RPM/libstdc++-libc6.1-1.so.2.html - Cached - 7k -
GoogleScout

OH GREAT!! Now I am even more confused. Is this a Red Hat module? or
maybe it is a module that just happens to be knows to RPM.

I am in desperate need of some education here!

I start out wanting to play with XML, so I need mozilla and that takes
me to c++ and that takes me  RPM.  :-(    argh

If you really take the time to educate me (or work with me) on this one I will jack up the points to 400 or more.

Mike

LVL 3
mmooreAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

mmooreAuthor Commented:
Adjusted points to 300
0
freesourceCommented:
The answer to your first question is yes.  You can also
go up to the mozilla executable and do a "ldd mozilla"
to see all the shared libraries required by mozilla.

Basically what's happening is that libstdc++-libc6.1-1.so.2 is a symlink to libstdc++-2-libc6.1-1-2.9.0.so (on my system) which belongs to the GNU stdc++ library from the egcs sources version 1.1.2.  Notice I said sources. You could grab the sources:

For instance:

ftp://rpmfind.net/linux/rawhide/1.0/SRPMS/SRPMS/egcs-1.1.2-26.src.rpm

And compile everything and install.

or grab something already compiled:

ftp://rpmfind.net/linux/redhat/redhat-6.1/i386/RedHat/RPMS/egcs-c++-1.1.2-24.i386.rpm

I don't use Redhat, but on my Debian system the files you need belong to a package called libstdc++2.9-glibc2.1-2.91.66-1.
I noticed there are RedHat packages called:

ftp://rpmfind.net/linux/openlinux/2.3/install-tree/col/install/RPMS/egcs-c++-2.91.66-5.i386.rpm

and

ftp://rpmfind.net/linux/openlinux/2.3/install-tree/col/install/RPMS/egcs-2.91.66-5.i386.rpm

One of these rpm packages should do the trick if you have RedHat (but I didn't verify that this was true), or the Debian package if you have Debian, or you could get a similiar sounding package if you have a different distribution.

If you don't have libc6 (>= 2.1) installed, you will have to install this too, in order to install the libstdc++2.9 libraries.  It doesn't matter what version of compiler you have, but it does matter what version of libc6 you have, since this determines which shared libraries you can install.  I suspect you may have an older version of libc6 installed on your system.  

In order to run this compilation of mozilla, you need the shared libraries which are greater or equal to the version of the compiler used.
0
freesourceCommented:
I just wanted to add, since you will have to install a newer version of libc6 (that's what it appears like from the "find" you ran), under Redhat you will need to grab one of the glibc-2.1* (* = wildcard) packages.
0
The Ultimate Tool Kit for Technolgy Solution Provi

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy for valuable how-to assets including sample agreements, checklists, flowcharts, and more!

mmooreAuthor Commented:
Thanks for your answer, I will look at it in detail this weekend.
0
freesourceCommented:
Stay in contact, if you tell me exactly what version of mozilla you are installing I can be more specific on which packages you need.  It is possible you need to get this package to have the shared libraries (I couldn't find any rpms with shared libraries for 2.91.66, but later shared libraries should work if you have the glibc I was talking about):

ftp://rpmfind.net/linux/rhcn/RPMS/i386/gcc-ss-libstdc++-2.95-0.19990712.1.i386.rpm

Note:  In fact, you can verify for yourself which packages you need by doing this.

rpm -qpilv ftp://rpmfind.net/linux/rhcn/RPMS/i386/gcc-ss-libstdc++-2.95-0.19990712.1.i386.rpm

... and indeed this is one package which provides the shared libraries ... whereas the packages I told you about above provide header files and static libraries, so this is what you need, especially if you have a new mozilla.

This would correlate to the requirements for the Debian mozilla_M12:

Depends: libc6 (>= 2.1), libglib1.2 (>= 1.2.0), libgtk1.2 (>= 1.2.6-1), libjpeg62, liborbit0 (>= 0.4.3-1), libpng2(>=1.0.3), libstdc++2.10, xlib6g (>= 3.3.5-1), zlib1g (>= 1:1.1.3), libnspr3
0
mmooreAuthor Commented:
I am running the TurboLinux 4.0 distribution.

sorry, I still don't understand, I spend the better part of sunday trying to read inbetween the lines but there is just too much background material that I don't understand. For example, I don't know what libc6 is. Is this a compile time library for C compiler to validate argument lists? Is it a run-time library? I can't seem to find a basic explanation of the C programming environment.

As I understand it, the C++ compiler generates C source code and passes it off to the C compiler.  Is this right?
(even though technically with egcs, the pre compiler and compiler are parts of a single program that is just called the "GNU Compiler Collection". Right?

From www.mozilla.org under nightly builds I select linux i386. the file that downloads is
mozilla-i686-pc-linux-gnu.tar.gz .

What is this i386 and i686 business?
They sound like CPU's.  Why, when I am selecting the aforementioned link that says i386 do I get a file that says i686?

How do I find out what version of libc6 I have installed?

 c++ -v   results in ...

Reading specs from /usr/lib/gcc-lib/i486-pc-linux-gnu/egcs-2.91.60/specs
gcc version egcs-2.91.60 19981201 (egcs-1.1.1 release)  
-------------------------
 ldd mozilla-bin
results in ........
        libraptorgfx.so => not found
        libmozjs.so => not found
        libxpcom.so => not found
        libjsj.so => not found
        libplds3.so => not found
        libplc3.so => not found
        libnspr3.so => not found
        libpthread.so.0 => /lib/libpthread.so.0 (0x2aac6000)
        libnsl.so.1 => /lib/libnsl.so.1 (0x2aad7000)
        libutil.so.1 => /lib/libutil.so.1 (0x2aaed000)
        libresolv.so.2 => /lib/libresolv.so.2 (0x2aaf0000)
        libdl.so.2 => /lib/libdl.so.2 (0x2aaff000)
        libstdc++-libc6.1-1.so.2 => not found
        libm.so.6 => /lib/libm.so.6 (0x2ab03000)
        libc.so.6 => /lib/libc.so.6 (0x2ab1f000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x2aaab000)

Okay, enough for now.

0
freesourceCommented:
The shared libraries which came with mozilla aren't in a location where they can be found, so the script called run-mozilla.sh is provided to allow mozilla to find these paths which can also be exported from the command line or put into your $HOME/.bash_profile:

export MOZILLA_FIVE_HOME=/usr/local/mozilla/package
export LD_LIBRARY_PATH=/usr/local/mozilla/package:/usr/local/mozilla/package
export SHLIB_PATH=/usr/local/mozilla/package
export LIBPATH=/usr/local/mozilla/package
export MOZ_PROGRAM=mozilla-bin

Mozilla was compiled with the GNU c++ compiler, which means that in order for it to run it needs the shared libraries necessary to run C++ applications.  The rpm package gcc-ss-libstdc++-2.95-0.19990712.1.i386.rpm provides these libraries and can be installed if glibc is also already installed.

Glibc provides the shared libraries that are used by nearly all programs.

Originally, I gave you a link to a package which wasn't needed  since it proveds the c++ compilier with static standard C++ library and C++ header files.  But, you don't need a compiler to run an already compiled program.  Later, when I got time I verified that it wasn't the package you needed.

You can't find what version of glibc you have by checking the version of compiler you have.  But, you could do something like this "rpm -qf /lib/libc.so.6" to find what version you have or even better "rpm -qi glibc".  So, I hope it is clear now what the difference is between shared libraries required by already compiled program, and libraries required by the compiler to help in compiling source code.

You were asking what the i686 for mozilla-i686-pc-linux-gnu.tar.gz meant.  This is just a compiler optimization for machines with 686 cpus.  There is controversy on whether or not optimized binaries have a real advantage, but it makes sense to do.  This question and your first question about how the c++ compiler works can best be asnswered by checking out "info gcc" which goes into great detail about the GNU compiler.

0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
mmooreAuthor Commented:
Adjusted points to 650
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Linux

From novice to tech pro — start learning today.