fix build failure on big endian platform (ppc64,s390x)
This commit is contained in:
parent
6d05645249
commit
aa9b8ac825
@ -38,7 +38,7 @@
|
||||
Summary: Qt5 - QtBase components
|
||||
Name: qt5-qtbase
|
||||
Version: 5.5.0
|
||||
Release: 1%{?dist}
|
||||
Release: 2%{?dist}
|
||||
|
||||
# See LGPL_EXCEPTIONS.txt, for exception details
|
||||
License: LGPLv2 with exceptions or GPLv3 with exceptions
|
||||
@ -72,6 +72,9 @@ Patch4: qtbase-opensource-src-5.3.2-QTBUG-35459.patch
|
||||
# unconditionally enable freetype lcdfilter support
|
||||
Patch12: qtbase-opensource-src-5.2.0-enable_ft_lcdfilter.patch
|
||||
|
||||
# fix issue on big endian platform
|
||||
Patch13: qtbase-opensource-src-5.5.x-big-endian.patch
|
||||
|
||||
# upstreamable patches
|
||||
# support poll
|
||||
# https://bugreports.qt-project.org/browse/QTBUG-27195
|
||||
@ -329,6 +332,7 @@ rm -fv mkspecs/linux-g++*/qmake.conf.multilib-optflags
|
||||
|
||||
%patch4 -p1 -b .QTBUG-35459
|
||||
%patch12 -p1 -b .enable_ft_lcdfilter
|
||||
%patch13 -p1 -b .big-endian
|
||||
|
||||
#patch50 -p1 -b .poll
|
||||
|
||||
@ -871,6 +875,9 @@ fi
|
||||
|
||||
|
||||
%changelog
|
||||
* Thu Jul 09 2015 Than Ngo <than@redhat.com> - 5.5.0-2
|
||||
- fix build failure on big endian platform (ppc64,s390x)
|
||||
|
||||
* Mon Jun 29 2015 Helio Chissini de Castro <helio@kde.org> - 5.5.0-0.5.rc
|
||||
- Second round of builds now with bootstrap enabled due new qttools
|
||||
|
||||
|
42
qtbase-opensource-src-5.5.x-big-endian.patch
Normal file
42
qtbase-opensource-src-5.5.x-big-endian.patch
Normal file
@ -0,0 +1,42 @@
|
||||
diff -up qtbase-opensource-src-5.5.0/src/gui/image/qimage_conversions.cpp.than qtbase-opensource-src-5.5.0/src/gui/image/qimage_conversions.cpp
|
||||
--- qtbase-opensource-src-5.5.0/src/gui/image/qimage_conversions.cpp.than 2015-07-09 17:01:29.605707305 +0200
|
||||
+++ qtbase-opensource-src-5.5.0/src/gui/image/qimage_conversions.cpp 2015-07-09 17:57:43.590576263 +0200
|
||||
@@ -1085,11 +1085,15 @@ static void mask_alpha_converter_RGBx(QI
|
||||
#endif
|
||||
}
|
||||
|
||||
+#if Q_BYTE_ORDER == Q_LITTLE_ENDIAN
|
||||
static bool mask_alpha_converter_rgbx_inplace(QImageData *data, Qt::ImageConversionFlags flags)
|
||||
{
|
||||
-#if Q_BYTE_ORDER == Q_LITTLE_ENDIAN
|
||||
return mask_alpha_converter_inplace<QImage::Format_RGBX8888>(data, flags);
|
||||
+}
|
||||
#else
|
||||
+template<QImage::Format DestFormat>
|
||||
+static bool mask_alpha_converter_rgbx_inplace(QImageData *data, Qt::ImageConversionFlags flags)
|
||||
+{
|
||||
Q_UNUSED(flags);
|
||||
|
||||
const int pad = (data->bytes_per_line >> 2) - data->width;
|
||||
@@ -1105,8 +1109,8 @@ static bool mask_alpha_converter_rgbx_in
|
||||
}
|
||||
data->format = DestFormat;
|
||||
return true;
|
||||
-#endif
|
||||
}
|
||||
+#endif
|
||||
|
||||
static QVector<QRgb> fix_color_table(const QVector<QRgb> &ctbl, QImage::Format format)
|
||||
{
|
||||
@@ -2704,7 +2708,11 @@ InPlace_Image_Converter qimage_inplace_c
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
+#if Q_BYTE_ORDER == Q_LITTLE_ENDIAN
|
||||
mask_alpha_converter_rgbx_inplace,
|
||||
+#else
|
||||
+ mask_alpha_converter_rgbx_inplace<QImage::Format_RGB32>,
|
||||
+#endif
|
||||
#if Q_BYTE_ORDER == Q_LITTLE_ENDIAN && __SSE2__
|
||||
0,
|
||||
convert_ARGB_to_ARGB_PM_inplace_sse2,
|
Loading…
Reference in New Issue
Block a user