Mercurial > mplayer.hg
comparison configure @ 4217:2b141fcd69dd
Patch by Falk Hueffner <falk.hueffner@student.uni-tuebingen.de>:
- detect the Alpha CPU type: default ("ev56") won't work with older Alphas,
and gcc can take advantage of newer ones that way.
author | pl |
---|---|
date | Thu, 17 Jan 2002 09:32:22 +0000 |
parents | 2c1ca684ff04 |
children | 5d744e4f5b62 |
comparison
equal
deleted
inserted
replaced
4216:ffb8428f39e2 | 4217:2b141fcd69dd |
---|---|
468 echores "$pname" | 468 echores "$pname" |
469 | 469 |
470 fi | 470 fi |
471 | 471 |
472 | 472 |
473 if [ "$host_arch" = alpha ]; then | |
474 echocheck "CPU type" | |
475 cat > $TMPC << EOF | |
476 int main() { | |
477 unsigned long ver, mask; | |
478 asm ("implver %0" : "=r" (ver)); | |
479 asm ("amask %1, %0" : "=r" (mask) : "r" (-1)); | |
480 printf("%ld-%x\n", ver, ~mask); | |
481 return 0; | |
482 } | |
483 EOF | |
484 $_cc -o "$TMPO" "$TMPC" | |
485 case `"$TMPO"` in | |
486 0-0) proc="ev4" ;; | |
487 1-0) proc="ev5" ;; | |
488 1-1) proc="ev56" ;; | |
489 1-101) proc="pca56" ;; | |
490 2-303) proc="ev6" ;; | |
491 2-307) proc="ev67" ;; | |
492 2-1307) proc="ev68" ;; | |
493 esac | |
494 echores "$proc" | |
495 fi | |
496 | |
473 | 497 |
474 case "$host_arch" in | 498 case "$host_arch" in |
475 i[3-9]86|x86*) | 499 i[3-9]86|x86*) |
476 _def_arch="#define ARCH_X86 1" | 500 _def_arch="#define ARCH_X86 1" |
477 _target_arch="TARGET_ARCH_X86 = yes" | 501 _target_arch="TARGET_ARCH_X86 = yes" |
597 alpha) | 621 alpha) |
598 _def_arch='#define ARCH_ALPHA 1' | 622 _def_arch='#define ARCH_ALPHA 1' |
599 _target_arch='TARGET_ARCH_ALPHA = yes' | 623 _target_arch='TARGET_ARCH_ALPHA = yes' |
600 _def_words_endian='#undef WORDS_BIGENDIAN' | 624 _def_words_endian='#undef WORDS_BIGENDIAN' |
601 iproc='alpha' | 625 iproc='alpha' |
602 proc='' | |
603 _march='' | 626 _march='' |
604 _mcpu='-mcpu=ev56' | 627 echocheck "GCC & CPU optimization abilities" |
628 if test "$proc" = "ev68" ; then | |
629 cc_check -mcpu=$proc || proc=ev67 | |
630 fi | |
631 if test "$proc" = "ev67" ; then | |
632 cc_check -mcpu=$proc || proc=ev6 | |
633 fi | |
634 _mcpu="-mcpu=$proc" | |
635 echores "$proc" | |
605 ;; | 636 ;; |
606 | 637 |
607 mips) | 638 mips) |
608 _def_arch="#define ARCH_SGI_MIPS 1" | 639 _def_arch="#define ARCH_SGI_MIPS 1" |
609 _target_arch="TARGET_ARCH_SGI_MIPS = yes" | 640 _target_arch="TARGET_ARCH_SGI_MIPS = yes" |