-   Linux - Software (
-   -   mplayer - wrong gcc flags (

crashmeister 11-19-2002 04:01 AM

mplayer - wrong gcc flags
Just a quick one - how do I get mplayer to compile with the gcc flags I want? In my case it uses athlon for my duron CPU.I need to use athlon-tbird.

MasterC 11-19-2002 05:53 AM

As quoted from the LFS Optimization hint:

There are a few ways to change the default compiler options. One way is to edit
every Makefile file you can find in a package, look for the CFLAGS and CXXFLAGS
variables (a well designed package uses the CFLAGS variable to define gcc
compiler options and CXXFLAGS to define g++ compiler options) and change their
values. Packages like binutils, gcc, glibc and others have a lot of Makefile
files in a lot of subdirectories so this would take a lot of time to do.
Instead there's an easier way to do things: create the CFLAGS and CXXFLAGS
environment variables. Most configure scripts read the CFLAGS and CXXFLAGS
variables and use them in the Makefile files. A few packages don't follow this
convention and those package require manual editing.

To set those variables you can do the following commands in bash (or in your
.bashrc if you want them to be there all the time):

export CFLAGS="-O3 -march=<architecture>" &&
To read the full hint, you'll need to download it from a mirror:

Since the main site is down for now.


crashmeister 11-19-2002 06:25 AM

Thanks - I'll try that.Damned gcc 3.2 is driving me crazy.

All times are GMT -5. The time now is 10:14 AM.