diff --git a/_constraints b/_constraints
index 2e7d479..cc06c52 100644
--- a/_constraints
+++ b/_constraints
@@ -4,4 +4,15 @@
4
+
+
+ ppc64
+ ppc64le
+
+
+
+ 4
+
+
+
diff --git a/krita.changes b/krita.changes
index 67abe68..59b5247 100644
--- a/krita.changes
+++ b/krita.changes
@@ -1,3 +1,10 @@
+-------------------------------------------------------------------
+Sat Jun 20 10:13:51 UTC 2020 - Wolfgang Bauer
+
+- Set minimum disk size for ppc64/ppc64le in _constraints to
+ prevent "no space left on device" errors during build
+- Fix build on ARM
+
-------------------------------------------------------------------
Thu Jun 18 10:04:10 UTC 2020 - Wolfgang Bauer
diff --git a/krita.spec b/krita.spec
index c1df1e4..5f6b0d1 100644
--- a/krita.spec
+++ b/krita.spec
@@ -31,7 +31,10 @@ License: GPL-2.0-or-later AND LGPL-2.0-or-later AND LGPL-2.1-or-later AND
Group: Productivity/Graphics/Bitmap Editors
URL: https://www.krita.org/
Source0: https://download.kde.org/stable/krita/%{version}/krita-%{version}.tar.xz
+%ifnarch %{arm} aarch64
+# causes build failure on ARM currently
BuildRequires: OpenColorIO-devel
+%endif
BuildRequires: OpenEXR-devel
BuildRequires: extra-cmake-modules
BuildRequires: fftw3-devel
@@ -108,6 +111,10 @@ Development headers and libraries for Krita.
%setup -q
%build
+%ifarch %{arm} aarch64
+# workaround to avoid build failure on ARM, see https://bugs.kde.org/show_bug.cgi?id=421136
+export CXXFLAGS="%{optflags} -DHAS_ONLY_OPENGL_ES"
+%endif
# install translations to %%{_kf5_localedir} so they don't clash with the krita translations in calligra-l10n (KDE4 based)
# can probably be changed back to the standard location when calligra is KF5 based...
%cmake_kf5 -d build -- -DCMAKE_INSTALL_LOCALEDIR=%{_kf5_localedir}