[SCM] mplayer2/master: enable runtime-cpudetection only on architectures where it is supported

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Sun Jun 19 17:06:47 UTC 2011


The following commit has been merged in the master branch:
commit f0aac722eb9d618d7b721cfcbc9cb143a917e68d
Author: Reinhard Tartler <siretart at tauware.de>
Date:   Sun Jun 19 18:40:27 2011 +0200

    enable runtime-cpudetection only on architectures where it is supported

diff --git a/debian/rules b/debian/rules
index 39f818e..8445ca9 100755
--- a/debian/rules
+++ b/debian/rules
@@ -12,11 +12,25 @@ NUMJOBS := -j$(shell getconf _NPROCESSORS_ONLN 2>/dev/null || echo 1)
 endif
 endif
 
+confflags := --prefix=/usr --enable-translation --enable-debug=3
+
+# runtime cpu detection works on x86 and ppc only. These checks also work on kfreebsd!
+DEB_HOST_GNU_TYPE := $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
+ifeq ($(DEB_HOST_GNU_CPU),i486)
+	confflags += --enable-runtime-cpudetection
+endif
+ifeq ($(DEB_HOST_GNU_CPU),x86_64)
+	confflags += --enable-runtime-cpudetection
+endif
+ifeq ($(DEB_HOST_GNU_CPU),powerpc)
+	confflags += --enable-runtime-cpudetection
+endif
+
 %:
 	dh $@
 
 override_dh_auto_configure:
-	./configure --prefix=/usr --enable-translation --enable-runtime-cpudetection --enable-debug=3
+	./configure $(confflags)
 
 override_dh_auto_build:
 	make V=1 $(NUMJOBS)

-- 
mplayer2 packaging



More information about the pkg-multimedia-commits mailing list