[MPlayer-users] Here Comes Help for Updating from gcc 3.2 (e.g. SuSE 8.1)

wmuydyf02 at sneakemail.com wmuydyf02 at sneakemail.com
Thu Sep 4 11:10:49 CEST 2003

Hi all,

since there have already been several messages on this list
complainig about problems compiling recent versions of MPlayer
with gcc 3.2 (try gcc -v if you don't know your version), I
thought I'd write a few notes on it. I'm by no means an expert,
but maybe I can help others who are struggling with similar
problems as I did.

You may already have read that it's all about updating to a
newer version of gcc, since current versions of MPlayer won't
compile e.g. with the gcc 3.2 that is shipped with SuSE 8.1
(though there might be workarounds, I don't know about that). So
how to do that, without breaking something else on the system?
Here's how:

1. Get an appropriate version of gcc from one of the mirrors
at http://gcc.gnu.org/mirrors.html. I think that the current gcc
3.3.1 might be a good choice. Note that it is *not*
sufficient to download the gcc-core-* package, because then the
"make"ing of MPlayer will abort complainig that c++ is not
installed. Therefore I chose the complete gcc-3.3.1.tar.bz2,
though something less might do as well.

Make sure you have enough disk space. From my experience I'd say
that during install you should have no less than 1.2GB free,
though there are methods for reducing the need of disk space
(see http://gcc.gnu.org/install/build.html; once you've finished
it will take much less). Also keep in mind that you should never
use more than 90% of the available disk space in linux.

2. To extract e.g. the gcc-3.3.1.tar.bz2, do
tar -jxf gcc-3.3.1.tar.bz2
(modify appropriately for other archives, e.g. 'z' instead of 'j'
for .tar.gz)

3. Decide where you want to install the new gcc. Make sure you
do not overwrite any previously installed version of gcc, I
guess otherwise you might really mess up your system. I think
that something below /opt might be a reasonable choice, so I
created a new directory /opt/gcc-3.3.1/

4. You must create an extra directory for building gcc. In the
same directory where you have extracted the archive (not inside
the extracted archive itself!) do:
mkdir gcc-build

5. Enter the new directory and configure gcc, telling it where it
should go:
cd gcc-build
../gcc-3.3.1/configure --prefix=/opt/gcc-3.3.1
Again, modify according to your situation. ../gcc-3.3.1/ refers
to the extracted archive, /opt/gcc-3.3.1 is where we want to
install gcc.

6. Compile:
make bootstrap
Depending on your computer, this will take long. 

7. Become root and install:
make install

Now you should have a working installation of the new gcc,
alongside with any previously installed version. You only need
to make sure that MPlayer's configure finds your new gcc. One
possibility is to tell configure explicitly by appending the
option --cc=/opt/gcc-3.3.1/bin/gcc (or whatever is appropriate
in your case). One more thing: If you want to use the live.com
libraries, make sure they are also compiled with your new gcc,
otherwise the "make"ing of MPlayer will fail.

Hope this helps.

Thanks once more to all the MPlayer developers for such a great
programme as MPlayer is!

Protect yourself from spam, 
use http://sneakemail.com

More information about the MPlayer-users mailing list