mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-28 22:57:37 +00:00
69 lines
2.2 KiB
Diff
69 lines
2.2 KiB
Diff
--- qt-x11-free-3.3.8b/src/tools/qglobal.h
|
|
+++ qt-x11-free-3.3.8b/src/tools/qglobal.h
|
|
@@ -323,6 +323,13 @@
|
|
# if __GNUC__ == 3 && __GNUC_MINOR__ >= 4
|
|
# define Q_NO_PACKED_REFERENCE
|
|
# endif
|
|
+# if __GNUC__ == 4 && __GNUC_MINOR__ >= 0
|
|
+# if __GNUC__ == 4 && __GNUC_MINOR__ >= 7
|
|
+# define Q_NO_PACKED_ACCESS
|
|
+# else
|
|
+# define Q_NO_PACKED_POINTERS
|
|
+# endif
|
|
+# endif
|
|
# endif
|
|
# if !defined(__EXCEPTIONS)
|
|
# define Q_NO_EXCEPTIONS
|
|
--- qt-x11-free-3.3.8b/src/tools/qlocale.cpp
|
|
+++ qt-x11-free-3.3.8b/src/tools/qlocale.cpp
|
|
@@ -3293,7 +3293,11 @@ QString QLocalePrivate::doubleToString(double d,
|
|
|
|
if (zero().unicode() != '0') {
|
|
for (uint i = 0; i < digits.length(); ++i)
|
|
+#ifdef Q_NO_PACKED_ACCESS
|
|
+ *digits.ref(i).unicodep() += zero().unicode() - '0';
|
|
+#else
|
|
digits.ref(i).unicode() += zero().unicode() - '0';
|
|
+#endif
|
|
}
|
|
|
|
bool always_show_decpt = flags & Alternate;
|
|
--- qt-x11-free-3.3.8b/src/tools/qstring.cpp
|
|
+++ qt-x11-free-3.3.8b/src/tools/qstring.cpp
|
|
@@ -1933,7 +1933,11 @@ static QString replaceArgEscapes(const QString &s, const ArgEscapeData &d, int f
|
|
|
|
if (field_width > 0) { // left padded
|
|
for (uint i = 0; i < pad_chars; ++i)
|
|
+#ifdef Q_NO_PACKED_ACCESS
|
|
+ *(rc++)->unicodep() = ' ';
|
|
+#else
|
|
(rc++)->unicode() = ' ';
|
|
+#endif
|
|
}
|
|
|
|
if (locale_arg) {
|
|
@@ -1947,7 +1951,11 @@ static QString replaceArgEscapes(const QString &s, const ArgEscapeData &d, int f
|
|
|
|
if (field_width < 0) { // right padded
|
|
for (uint i = 0; i < pad_chars; ++i)
|
|
+#ifdef Q_NO_PACKED_ACCESS
|
|
+ *(rc++)->unicodep() = ' ';
|
|
+#else
|
|
(rc++)->unicode() = ' ';
|
|
+#endif
|
|
}
|
|
|
|
if (++repl_cnt == d.occurrences) {
|
|
--- qt-x11-free-3.3.8b/src/tools/qstring.h
|
|
+++ qt-x11-free-3.3.8b/src/tools/qstring.h
|
|
@@ -199,6 +199,10 @@ public:
|
|
ushort unicode() const { return ucs; }
|
|
#ifdef Q_NO_PACKED_REFERENCE
|
|
ushort &unicode() { return *(&ucs); }
|
|
+#elif defined Q_NO_PACKED_POINTERS
|
|
+ ushort &unicode() { ushort& tmp = ucs; return tmp; }
|
|
+#elif defined Q_NO_PACKED_ACCESS
|
|
+ ushort *unicodep() { return &ucs; }
|
|
#else
|
|
ushort &unicode() { return ucs; }
|
|
#endif
|