diff --git a/srcpkgs/darktable/patches/mmsetflush-gcc473-mtune-generic.patch b/srcpkgs/darktable/patches/mmsetflush-gcc473-mtune-generic.patch new file mode 100644 index 0000000000..47a86a9e09 --- /dev/null +++ b/srcpkgs/darktable/patches/mmsetflush-gcc473-mtune-generic.patch @@ -0,0 +1,16 @@ +Comment _MM_SET_FLUSH_ZERO_MODE for now. + +gcc-4.7.3 with -mtune=generic uses STMXCSR/VSTMXCSR instructions which are +only available in Sandy Bridge CPUs, thus causes a SIGILL on AMD CPUs. + +--- src/common/darktable.c.orig 2014-05-08 11:42:15.844554271 +0200 ++++ src/common/darktable.c 2014-05-08 11:43:00.724288778 +0200 +@@ -363,7 +363,7 @@ int dt_init(int argc, char *argv[], cons + #endif + + // make everything go a lot faster. +- _MM_SET_FLUSH_ZERO_MODE(_MM_FLUSH_ZERO_ON); ++ //_MM_SET_FLUSH_ZERO_MODE(_MM_FLUSH_ZERO_ON); + #if !defined __APPLE__ && !defined __WIN32__ + _dt_sigsegv_old_handler = signal(SIGSEGV,&_dt_sigsegv_handler); + #endif diff --git a/srcpkgs/darktable/template b/srcpkgs/darktable/template index 33fbdee76d..8fd0a6999d 100644 --- a/srcpkgs/darktable/template +++ b/srcpkgs/darktable/template @@ -1,7 +1,7 @@ # Template file for 'darktable' pkgname=darktable version=1.4.2 -revision=4 +revision=5 build_style=cmake maintainer="Carlo Dormeletti " homepage="http://www.darktable.org/" @@ -17,12 +17,6 @@ makedepends="gtk+-devel glib-devel exiv2-devel lcms2-devel distfiles="${SOURCEFORGE_SITE}/${pkgname}/1.4/${pkgname}-${version}.tar.xz" checksum="c1311a6e336007b85d21647652ebec3e26840248a968eab04ab5f0a56c2e0709" -# This needs to be built with SSE, otherwise some CPUs might crash with -# an ilegal instruction (vstmxcsr). Notably most AMD CPUs with -mtune=generic. -# -# Let's assume this has been fixed in recent gcc versions and just force SSE. -CFLAGS="-msse" - post_install() { mv ${DESTDIR}/usr/lib/darktable/libdarktable.so ${DESTDIR}/usr/lib/ }