Mercurial > mplayer.hg
comparison configure @ 9184:67474c57719e
some typos and rewordings
author | diego |
---|---|
date | Fri, 31 Jan 2003 01:47:55 +0000 |
parents | d49d15271b99 |
children | 7c12f4501ed6 |
comparison
equal
deleted
inserted
replaced
9183:7bf676137c4d | 9184:67474c57719e |
---|---|
526 fi | 526 fi |
527 | 527 |
528 # Try to find the available options for the current CPU | 528 # Try to find the available options for the current CPU |
529 if x86 || ppc; then | 529 if x86 || ppc; then |
530 if test -r /proc/cpuinfo ; then | 530 if test -r /proc/cpuinfo ; then |
531 # linux with /proc mounted, extract cpu information from it | 531 # Linux with /proc mounted, extract CPU information from it |
532 _cpuinfo="cat /proc/cpuinfo" | 532 _cpuinfo="cat /proc/cpuinfo" |
533 elif test -r /compat/linux/proc/cpuinfo ; then | 533 elif test -r /compat/linux/proc/cpuinfo ; then |
534 # FreeBSD with linux emulation /proc mounted, | 534 # FreeBSD with Linux emulation /proc mounted, |
535 # extract cpu information from it | 535 # extract CPU information from it |
536 _cpuinfo="cat /compat/linux/proc/cpuinfo" | 536 _cpuinfo="cat /compat/linux/proc/cpuinfo" |
537 elif x86; then | 537 elif x86; then |
538 # all other OS try to extract cpu information from a small helper | 538 # all other OSes try to extract CPU information from a small helper |
539 # program TOOLS/cpuinfo instead | 539 # program TOOLS/cpuinfo instead |
540 $_cc -o TOOLS/cpuinfo TOOLS/cpuinfo.c | 540 $_cc -o TOOLS/cpuinfo TOOLS/cpuinfo.c |
541 _cpuinfo="TOOLS/cpuinfo" | 541 _cpuinfo="TOOLS/cpuinfo" |
542 fi | 542 fi |
543 | 543 |
578 echores "$pvendor ($pfamily:$pmodel:$pstepping)" | 578 echores "$pvendor ($pfamily:$pmodel:$pstepping)" |
579 | 579 |
580 echocheck "CPU type" | 580 echocheck "CPU type" |
581 echores "$pname" | 581 echores "$pname" |
582 | 582 |
583 # just leaving this here becouse the non-x86 optims | 583 # leaving this here because of the non-x86 optimizations |
584 if test "$_runtime_cpudetection" = yes ; then | 584 if test "$_runtime_cpudetection" = yes ; then |
585 if x86; then | 585 if x86; then |
586 _mmx=yes | 586 _mmx=yes |
587 _3dnow=yes | 587 _3dnow=yes |
588 _3dnowex=yes | 588 _3dnowex=yes |
649 6) iproc=686 | 649 6) iproc=686 |
650 if test "$pmodel" -ge 7; then | 650 if test "$pmodel" -ge 7; then |
651 proc=athlon-4 | 651 proc=athlon-4 |
652 elif test "$pmodel" -ge 6; then | 652 elif test "$pmodel" -ge 6; then |
653 # only Athlon XP supports ssem MP, Duron etc not | 653 # only Athlon XP supports ssem MP, Duron etc not |
654 # but most of them are cpuid 666, so check if sse detected | 654 # but most of them are CPUID 666, so check if sse detected |
655 # btw. there is also athlon-mp opt, but we need extended | 655 # btw. there is also athlon-mp opt, but we need extended |
656 # cpuid to detect if cpu is SMP capable -> athlon-mp ::atmos | 656 # CPUID to detect if CPU is SMP capable -> athlon-mp ::atmos |
657 if test "$_sse" = yes && test "$pstepping" -ge 2; then | 657 if test "$_sse" = yes && test "$pstepping" -ge 2; then |
658 proc=athlon-xp | 658 proc=athlon-xp |
659 else | 659 else |
660 proc=athlon-4 | 660 proc=athlon-4 |
661 fi | 661 fi |
702 ;; | 702 ;; |
703 *) | 703 *) |
704 proc=i586 iproc=586 ;; | 704 proc=i586 iproc=586 ;; |
705 esac | 705 esac |
706 | 706 |
707 # check that gcc supports our cpu, if not, fallback to earlier ones | 707 # check that gcc supports our CPU, if not, fall back to earlier ones |
708 # LGB: check -mcpu and -march swithing step by step with enabling | 708 # LGB: check -mcpu and -march swithing step by step with enabling |
709 # to fall back till 386. | 709 # to fall back till 386. |
710 | 710 |
711 echocheck "GCC & CPU optimization abilities" | 711 echocheck "GCC & CPU optimization abilities" |
712 cat > $TMPC << EOF | 712 cat > $TMPC << EOF |
742 fi | 742 fi |
743 if test "$proc" = "i386" ; then | 743 if test "$proc" = "i386" ; then |
744 cc_check -march=$proc -mcpu=$proc || proc=error | 744 cc_check -march=$proc -mcpu=$proc || proc=error |
745 fi | 745 fi |
746 if test "$proc" = "error" ; then | 746 if test "$proc" = "error" ; then |
747 echores "Your $_cc does not support even \"i386\" for '-march' and '-mcpu'." | 747 echores "Your $_cc does not even support \"i386\" for '-march' and '-mcpu'." |
748 _mcpu="" | 748 _mcpu="" |
749 _march="" | 749 _march="" |
750 _optimizing="" | 750 _optimizing="" |
751 elif test "$proc" = "i586-i686"; then | 751 elif test "$proc" = "i586-i686"; then |
752 _march="-march=i586" | 752 _march="-march=i586" |
756 _march="-march=$proc" | 756 _march="-march=$proc" |
757 _mcpu="-mcpu=$proc" | 757 _mcpu="-mcpu=$proc" |
758 _optimizing="$proc" | 758 _optimizing="$proc" |
759 fi | 759 fi |
760 else | 760 else |
761 # i686 is probably the most common cpu - optimize to it | 761 # i686 is probably the most common CPU - optimize for it |
762 _mcpu="-mcpu=i686" | 762 _mcpu="-mcpu=i686" |
763 # at least i486 required, for bswap instruction | 763 # at least i486 required, for bswap instruction |
764 _march="-march=i486" | 764 _march="-march=i486" |
765 cc_check $_mcpu || _mcpu="" | 765 cc_check $_mcpu || _mcpu="" |
766 cc_check $_march $_mcpu || _march="" | 766 cc_check $_march $_mcpu || _march="" |
767 fi | 767 fi |
768 | 768 |
769 ## Gabucino : --target takes effect here (hopefully...) by overwriting | 769 ## Gabucino : --target takes effect here (hopefully...) by overwriting |
770 ## autodetected mcpu/march parameters | 770 ## autodetected mcpu/march parameters |
771 if test "$_target" ; then | 771 if test "$_target" ; then |
772 # TODO: it may be a good idea to check GCC and fallback in all cases | 772 # TODO: it may be a good idea to check GCC and fall back in all cases |
773 if test "$host_arch" = "i586-i686"; then | 773 if test "$host_arch" = "i586-i686"; then |
774 _march="-march=i586" | 774 _march="-march=i586" |
775 _mcpu="-mcpu=i686" | 775 _mcpu="-mcpu=i686" |
776 else | 776 else |
777 _march="-march=$host_arch" | 777 _march="-march=$host_arch" |
1324 --enable-3dnowex) _3dnow=yes _3dnowex=yes ;; | 1324 --enable-3dnowex) _3dnow=yes _3dnowex=yes ;; |
1325 --disable-3dnowex) _3dnowex=no ;; | 1325 --disable-3dnowex) _3dnowex=no ;; |
1326 --enable-altivec) _altivec=yes ;; | 1326 --enable-altivec) _altivec=yes ;; |
1327 --disable-altivec) _altivec=no ;; | 1327 --disable-altivec) _altivec=no ;; |
1328 --enable-mmx) _mmx=yes ;; | 1328 --enable-mmx) _mmx=yes ;; |
1329 --disable-mmx) # without mmx 3Dnow! and stuff is also not possible | 1329 --disable-mmx) # 3Dnow! and MMX2 require MMX |
1330 _3dnow=no _3dnowex=no _mmx=no _mmx2=no ;; | 1330 _3dnow=no _3dnowex=no _mmx=no _mmx2=no ;; |
1331 | 1331 |
1332 --enable-win32) _win32=yes ;; | 1332 --enable-win32) _win32=yes ;; |
1333 --disable-win32) _win32=no _dshow=no ;; | 1333 --disable-win32) _win32=no _dshow=no ;; |
1334 --enable-dshow) _win32=yes _dshow=yes ;; | 1334 --enable-dshow) _win32=yes _dshow=yes ;; |
1482 echo "WARNING! If you want to run MPlayer on this system, get prepared for problems!" | 1482 echo "WARNING! If you want to run MPlayer on this system, get prepared for problems!" |
1483 echo "2.2.x has limited SSE support. Upgrade the kernel or use --disable-sse if you" | 1483 echo "2.2.x has limited SSE support. Upgrade the kernel or use --disable-sse if you" |
1484 echo "experience crashes. MPlayer tries to autodetect if your kernel correctly" | 1484 echo "experience crashes. MPlayer tries to autodetect if your kernel correctly" |
1485 echo "supports SSE, but you have been warned! If you are using a kernel older than" | 1485 echo "supports SSE, but you have been warned! If you are using a kernel older than" |
1486 echo "2.2.x you must upgrade it to get SSE support!" | 1486 echo "2.2.x you must upgrade it to get SSE support!" |
1487 # die "old kernel for this cpu" # works fine on some 2.2.x so don't die (later check will test) | 1487 # die "Your kernel is too old for this CPU." # works fine on some 2.2.x so don't die (later check will test) |
1488 else | 1488 else |
1489 echores "$kernel_version, ok" | 1489 echores "$kernel_version, ok" |
1490 fi | 1490 fi |
1491 fi | 1491 fi |
1492 | 1492 |
1493 if test "$_vidix" = auto ; then | 1493 if test "$_vidix" = auto ; then |
1494 _vidix=no | 1494 _vidix=no |
1495 # should check for x86 systems supporting vidix (does qnx have vidix?) | 1495 # should check for x86 systems supporting VIDIX (does QNX have VIDIX?) |
1496 x86 && _vidix=yes | 1496 x86 && _vidix=yes |
1497 cygwin && _vidix=no | 1497 cygwin && _vidix=no |
1498 qnx && _vidix=no | 1498 qnx && _vidix=no |
1499 sunos && _vidix=no | 1499 sunos && _vidix=no |
1500 fi | 1500 fi |
1967 int main(void) { return 0; } | 1967 int main(void) { return 0; } |
1968 EOF | 1968 EOF |
1969 _soundcard=no | 1969 _soundcard=no |
1970 cc_check && _soundcard=yes | 1970 cc_check && _soundcard=yes |
1971 if linux || test "$_ossaudio" != no ; then | 1971 if linux || test "$_ossaudio" != no ; then |
1972 # use soundcard.h on linux, or when OSS support is enabled | 1972 # use soundcard.h on Linux, or when OSS support is enabled |
1973 echores "$_soundcard" | 1973 echores "$_soundcard" |
1974 else | 1974 else |
1975 # we don't want to use soundcard.h on non-linux if no OSS support enabled! | 1975 # we don't want to use soundcard.h on non-Linux if OSS support not enabled! |
1976 echores "$_soundcard, but ignored!" | 1976 echores "$_soundcard, but ignored!" |
1977 _soundcard=no | 1977 _soundcard=no |
1978 fi | 1978 fi |
1979 if test "$_soundcard" = yes ; then | 1979 if test "$_soundcard" = yes ; then |
1980 _def_soundcard='#define HAVE_SOUNDCARD_H 1' | 1980 _def_soundcard='#define HAVE_SOUNDCARD_H 1' |
4706 test "$_debug" != "" && _def_debug='#define MP_DEBUG 1' | 4706 test "$_debug" != "" && _def_debug='#define MP_DEBUG 1' |
4707 | 4707 |
4708 _def_linux='#undef TARGET_LINUX' | 4708 _def_linux='#undef TARGET_LINUX' |
4709 linux && _def_linux='#define TARGET_LINUX 1' | 4709 linux && _def_linux='#define TARGET_LINUX 1' |
4710 | 4710 |
4711 # TODO cleanup the vidix stuff here | 4711 # TODO cleanup the VIDIX stuff here |
4712 _def_vidix='#define CONFIG_VIDIX 1' | 4712 _def_vidix='#define CONFIG_VIDIX 1' |
4713 test "$_vidix" = no && _def_vidix='#undef CONFIG_VIDIX' | 4713 test "$_vidix" = no && _def_vidix='#undef CONFIG_VIDIX' |
4714 if test "$_vidix" = yes && test "$_x11" = yes; then | 4714 if test "$_vidix" = yes && test "$_x11" = yes; then |
4715 _vosrc="$_vosrc vo_xvidix.c" | 4715 _vosrc="$_vosrc vo_xvidix.c" |
4716 _vomodules="xvidix $_vomodules" | 4716 _vomodules="xvidix $_vomodules" |
5260 $_def_use_aton | 5260 $_def_use_aton |
5261 | 5261 |
5262 /* enables / disables cdparanoia support */ | 5262 /* enables / disables cdparanoia support */ |
5263 $_def_cdparanoia | 5263 $_def_cdparanoia |
5264 | 5264 |
5265 /* enables / disables vidix usage */ | 5265 /* enables / disables VIDIX usage */ |
5266 $_def_vidix | 5266 $_def_vidix |
5267 | 5267 |
5268 /* enables / disables new input joystick support */ | 5268 /* enables / disables new input joystick support */ |
5269 $_def_joystick | 5269 $_def_joystick |
5270 | 5270 |