changeset 683:aad2dedb8b6a libavcodec

* Remove -finline-limit=8000 (not supported by gcc 2.95) * Hack to force correct gcc arch flags for motion_est_alpha.c
author mellum
date Thu, 19 Sep 2002 16:06:25 +0000
parents 8be211ca9db9
children 581678112a5d
files Makefile
diffstat 1 files changed, 12 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/Makefile	Thu Sep 19 10:26:49 2002 +0000
+++ b/Makefile	Thu Sep 19 16:06:25 2002 +0000
@@ -69,7 +69,7 @@
 ifeq ($(TARGET_ARCH_ALPHA),yes)
 OBJS += alpha/dsputil_alpha.o alpha/mpegvideo_alpha.o alpha/motion_est_alpha.o
 ASM_OBJS += alpha/dsputil_alpha_asm.o
-CFLAGS += -Wa,-mpca56 -finline-limit=8000 -fforce-addr -freduce-all-givs
+CFLAGS += -fforce-addr -freduce-all-givs
 endif
 
 ifeq ($(TARGET_ARCH_POWERPC),yes)
@@ -110,6 +110,17 @@
 %.o: %.S
 	$(CC) $(CFLAGS) -c -o $@ $<
 
+# motion_est_alpha uses the MVI extension, which is not available with
+# -mcpu=ev4 (default) or ev5/ev56. Thus, force -mcpu=pca56 in those
+# cases.
+ifeq ($(TARGET_ARCH_ALPHA),yes)
+alpha/motion_est_alpha.o: alpha/motion_est_alpha.c
+	cpu=`echo "$(CFLAGS)" | sed -n 's,.*-mcpu=\([a-zA-Z0-9]*\).*,\1,p'`; \
+	case x"$$cpu" in x|xev[45]*) newcpu=pca56;; *) newcpu=$$cpu;; esac; \
+	echo $(CC) $(CFLAGS) -mcpu=$$newcpu -c -o $@ $<;\
+	$(CC) $(CFLAGS) -mcpu=$$newcpu -c -o $@ $<
+endif
+
 # depend only used by mplayer now
 dep:	depend