summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--community/carla/PKGBUILD27
-rw-r--r--community/carla/carla-git-no-sse.patch62
-rw-r--r--community/carla/carla-git-no-sse2.patch62
3 files changed, 151 insertions, 0 deletions
diff --git a/community/carla/PKGBUILD b/community/carla/PKGBUILD
new file mode 100644
index 00000000..8211b9f1
--- /dev/null
+++ b/community/carla/PKGBUILD
@@ -0,0 +1,27 @@
+# disable SSE, SSE2 according to platform
+
+if [ "${CARCH}" = "i686" ]; then
+ source+=('carla-git-no-sse2.patch')
+ sha512sums+=('74fa0bf6afd032f68333680ae5bb7398c613bd74e9639e76ccd0bc5c3a9b67475d618ad9a1f178f924a0c5847228085971e9b7eb685ec6cfd36ee1329b7fff63')
+ b2sums+=('72e34c424289b84fe656a86c8ba29a7315350299114e2f1cf75892e219e79f9cf32b8c19d1aa0912a7668a2d9e741012e5c6372dcee9aaf45fb45833559fd376')
+ eval "$(
+ declare -f build | \
+ sed '
+ /make features/ i \
+ patch -Np1 -i "$srcdir/carla-git-no-sse2.patch"
+ '
+ )"
+fi
+
+if [ "${CARCH}" = "i486" ]; then
+ source+=('carla-git-no-sse.patch')
+ sha512sums+=('f4953da920ba508259eb7da42a8135662c9e2421dfd8488889d7b4ac5a8cf86da97bd4a22eea06da86e1c4ce728ff79e90b368ad761765fb988baa029e5b04cd')
+ b2sums+=('461512fc763f5b88c8ef5d2d4c7e63d7d959d4cfea3581de122abc76651c32e7cd64cee249cd791103d6dc906b2c341b11591724525e95d0df71aab10dc8c5de')
+ eval "$(
+ declare -f build | \
+ sed '
+ /make features/ i \
+ patch -Np1 -i "$srcdir/carla-git-no-sse.patch"
+ '
+ )"
+fi
diff --git a/community/carla/carla-git-no-sse.patch b/community/carla/carla-git-no-sse.patch
new file mode 100644
index 00000000..2c44f839
--- /dev/null
+++ b/community/carla/carla-git-no-sse.patch
@@ -0,0 +1,62 @@
+diff -rauN carla-git/data/linux/build-deps.sh carla-git-no-sse/data/linux/build-deps.sh
+--- carla-git/data/linux/build-deps.sh 2021-09-23 08:50:25.065006050 +0200
++++ carla-git-no-sse/data/linux/build-deps.sh 2021-09-23 09:04:11.823846586 +0200
+@@ -52,7 +52,7 @@
+ export PATH=${PREFIX}/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin
+ export PKG_CONFIG_PATH=${PREFIX}/lib/pkgconfig
+
+-export CFLAGS="-O3 -mtune=generic -msse -msse2 -mfpmath=sse -fvisibility=hidden -fdata-sections -ffunction-sections"
++export CFLAGS="-O3 -mtune=generic -fvisibility=hidden -fdata-sections -ffunction-sections"
+ export CFLAGS="${CFLAGS} -fPIC -DPIC -DNDEBUG -I${PREFIX}/include -m${ARCH}"
+ export CXXFLAGS="${CFLAGS} -fvisibility-inlines-hidden"
+
+@@ -115,7 +115,7 @@
+ cd qtbase-opensource-src-${QT5_VERSION}
+ if [ ! -f configured ]; then
+ ./configure -release -strip -silent \
+- -sse2 \
++ -no-sse -no-sse2 \
+ -no-sse3 -no-ssse3 -no-sse4.1 -no-sse4.2 \
+ -no-avx -no-avx2 -no-avx512 \
+ -prefix ${PREFIX} \
+@@ -347,14 +347,14 @@
+ export CXXFLAGS="${CXXFLAGS} -ffast-math"
+ cd fftw-${FFTW3_VERSION}
+ ./configure --enable-static --disable-shared --prefix=${PREFIX} \
+- --enable-sse2 \
++ --disable=sse --disable-sse2 \
+ --disable-debug --disable-alloca --disable-fortran \
+ --with-our-malloc
+ make
+ make install
+ make clean
+ ./configure --enable-static --disable-shared --prefix=${PREFIX} \
+- --enable-sse2 --enable-sse --enable-single \
++ --disable-sse2 --disable-sse --enable-single \
+ --disable-debug --disable-alloca --disable-fortran \
+ --with-our-malloc
+ make
+diff -rauN carla-git/data/linux/build-pyqt.sh carla-git-no-sse/data/linux/build-pyqt.sh
+--- carla-git/data/linux/build-pyqt.sh 2021-09-23 08:50:25.065006050 +0200
++++ carla-git-no-sse/data/linux/build-pyqt.sh 2021-09-23 09:03:34.840418148 +0200
+@@ -45,7 +45,7 @@
+ export PATH=${PREFIX}/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin
+ export PKG_CONFIG_PATH=${PREFIX}/lib/pkgconfig
+
+-export CFLAGS="-O3 -mtune=generic -msse -msse2 -mfpmath=sse -fPIC -DPIC -DNDEBUG -m${ARCH}"
++export CFLAGS="-O3 -mtune=generic -fPIC -DPIC -DNDEBUG -m${ARCH}"
+ export CXXFLAGS="${CFLAGS}"
+ export LDFLAGS="-m${ARCH} -Wl,-O1"
+
+diff -rauN carla-git/source/tests.old/Makefile carla-git-no-sse/source/tests.old/Makefile
+--- carla-git/source/tests.old/Makefile 2021-09-23 08:50:25.275006380 +0200
++++ carla-git-no-sse/source/tests.old/Makefile 2021-09-23 09:03:18.023708117 +0200
+@@ -33,7 +33,7 @@
+ ifeq ($(DEBUG),true)
+ BASE_FLAGS += -DDEBUG -O0 -g
+ else
+-BASE_FLAGS += -O3 -ffast-math -mtune=generic -msse -msse2 -mfpmath=sse -fdata-sections -ffunction-sections
++BASE_FLAGS += -O3 -ffast-math -mtune=generic -fdata-sections -ffunction-sections
+ LINK_FLAGS += -fdata-sections -ffunction-sections -Wl,--gc-sections -Wl,-O1 -Wl,--as-needed -Wl,--strip-all
+ endif
+
diff --git a/community/carla/carla-git-no-sse2.patch b/community/carla/carla-git-no-sse2.patch
new file mode 100644
index 00000000..7f13eeeb
--- /dev/null
+++ b/community/carla/carla-git-no-sse2.patch
@@ -0,0 +1,62 @@
+diff -rauN carla-git/data/linux/build-deps.sh carla-git-no-sse2/data/linux/build-deps.sh
+--- carla-git/data/linux/build-deps.sh 2021-09-23 08:50:25.065006050 +0200
++++ carla-git-no-sse2/data/linux/build-deps.sh 2021-09-23 08:52:22.391955977 +0200
+@@ -52,7 +52,7 @@
+ export PATH=${PREFIX}/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin
+ export PKG_CONFIG_PATH=${PREFIX}/lib/pkgconfig
+
+-export CFLAGS="-O3 -mtune=generic -msse -msse2 -mfpmath=sse -fvisibility=hidden -fdata-sections -ffunction-sections"
++export CFLAGS="-O3 -mtune=generic -msse -mfpmath=sse -fvisibility=hidden -fdata-sections -ffunction-sections"
+ export CFLAGS="${CFLAGS} -fPIC -DPIC -DNDEBUG -I${PREFIX}/include -m${ARCH}"
+ export CXXFLAGS="${CFLAGS} -fvisibility-inlines-hidden"
+
+@@ -115,7 +115,7 @@
+ cd qtbase-opensource-src-${QT5_VERSION}
+ if [ ! -f configured ]; then
+ ./configure -release -strip -silent \
+- -sse2 \
++ -no-sse2 \
+ -no-sse3 -no-ssse3 -no-sse4.1 -no-sse4.2 \
+ -no-avx -no-avx2 -no-avx512 \
+ -prefix ${PREFIX} \
+@@ -347,14 +347,14 @@
+ export CXXFLAGS="${CXXFLAGS} -ffast-math"
+ cd fftw-${FFTW3_VERSION}
+ ./configure --enable-static --disable-shared --prefix=${PREFIX} \
+- --enable-sse2 \
++ --disable-sse2 \
+ --disable-debug --disable-alloca --disable-fortran \
+ --with-our-malloc
+ make
+ make install
+ make clean
+ ./configure --enable-static --disable-shared --prefix=${PREFIX} \
+- --enable-sse2 --enable-sse --enable-single \
++ --disable-sse2 --enable-sse --enable-single \
+ --disable-debug --disable-alloca --disable-fortran \
+ --with-our-malloc
+ make
+diff -rauN carla-git/data/linux/build-pyqt.sh carla-git-no-sse2/data/linux/build-pyqt.sh
+--- carla-git/data/linux/build-pyqt.sh 2021-09-23 08:50:25.065006050 +0200
++++ carla-git-no-sse2/data/linux/build-pyqt.sh 2021-09-23 08:51:36.735162561 +0200
+@@ -45,7 +45,7 @@
+ export PATH=${PREFIX}/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin
+ export PKG_CONFIG_PATH=${PREFIX}/lib/pkgconfig
+
+-export CFLAGS="-O3 -mtune=generic -msse -msse2 -mfpmath=sse -fPIC -DPIC -DNDEBUG -m${ARCH}"
++export CFLAGS="-O3 -mtune=generic -msse -mfpmath=sse -fPIC -DPIC -DNDEBUG -m${ARCH}"
+ export CXXFLAGS="${CFLAGS}"
+ export LDFLAGS="-m${ARCH} -Wl,-O1"
+
+diff -rauN carla-git/source/tests.old/Makefile carla-git-no-sse2/source/tests.old/Makefile
+--- carla-git/source/tests.old/Makefile 2021-09-23 08:50:25.275006380 +0200
++++ carla-git-no-sse2/source/tests.old/Makefile 2021-09-23 08:51:13.868432167 +0200
+@@ -33,7 +33,7 @@
+ ifeq ($(DEBUG),true)
+ BASE_FLAGS += -DDEBUG -O0 -g
+ else
+-BASE_FLAGS += -O3 -ffast-math -mtune=generic -msse -msse2 -mfpmath=sse -fdata-sections -ffunction-sections
++BASE_FLAGS += -O3 -ffast-math -mtune=generic -msse -mfpmath=sse -fdata-sections -ffunction-sections
+ LINK_FLAGS += -fdata-sections -ffunction-sections -Wl,--gc-sections -Wl,-O1 -Wl,--as-needed -Wl,--strip-all
+ endif
+