mirror of
https://github.com/void-linux/void-packages.git
synced 2025-08-01 10:22:56 +02:00
kwin: build for platform that don't have atomic_int64
I can make it built but I can't test it :(
This commit is contained in:
parent
bfbe58d1af
commit
aec36a4bc9
2 changed files with 36 additions and 4 deletions
36
srcpkgs/kwin/patches/atomic-type.patch
Normal file
36
srcpkgs/kwin/patches/atomic-type.patch
Normal file
|
@ -0,0 +1,36 @@
|
||||||
|
--- src/ftrace.h
|
||||||
|
+++ src/ftrace.h
|
||||||
|
@@ -11,6 +11,7 @@
|
||||||
|
|
||||||
|
#include <kwinglobals.h>
|
||||||
|
|
||||||
|
+#include <type_traits>
|
||||||
|
#include <QFile>
|
||||||
|
#include <QMutex>
|
||||||
|
#include <QMutexLocker>
|
||||||
|
@@ -70,10 +71,15 @@ private:
|
||||||
|
|
||||||
|
class KWIN_EXPORT FTraceDuration
|
||||||
|
{
|
||||||
|
+ using ftrace_context_t = std::conditional<
|
||||||
|
+ QAtomicOpsSupport<sizeof(qulonglong)>::IsSupported,
|
||||||
|
+ qulonglong,
|
||||||
|
+ ulong>::type;
|
||||||
|
+
|
||||||
|
public:
|
||||||
|
template<typename... Args> FTraceDuration(Args... args)
|
||||||
|
{
|
||||||
|
- static QAtomicInteger<qulonglong> s_context = 0;
|
||||||
|
+ static QAtomicInteger<ftrace_context_t> s_context = 0;
|
||||||
|
QTextStream stream(&m_message);
|
||||||
|
(stream << ... << args);
|
||||||
|
stream.flush();
|
||||||
|
@@ -85,7 +91,7 @@ public:
|
||||||
|
|
||||||
|
private:
|
||||||
|
QByteArray m_message;
|
||||||
|
- qulonglong m_context;
|
||||||
|
+ ftrace_context_t m_context;
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace KWin
|
|
@ -30,10 +30,6 @@ if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
|
||||||
makedepends+=" libatomic-devel"
|
makedepends+=" libatomic-devel"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
|
|
||||||
broken="Q_STATIC_ASSERT_X(QAtomicOpsSupport<sizeof(T)>::IsSupported"
|
|
||||||
fi
|
|
||||||
|
|
||||||
post_extract() {
|
post_extract() {
|
||||||
_qt5_dep_ver="${depends#*>=}"
|
_qt5_dep_ver="${depends#*>=}"
|
||||||
_qt5_dep_ver="${_qt5_dep_ver%<*}"
|
_qt5_dep_ver="${_qt5_dep_ver%<*}"
|
||||||
|
|
Loading…
Add table
Reference in a new issue