%global _hardened_build 1 ## NOTE: Lots of files in various subdirectories have the same name (such as ## "LICENSE") so this short macro allows us to distinguish them by using their ## directory names (from the source tree) as prefixes for the files. %global add_to_license_files() \ mkdir -p _license_files ; \ cp -p %1 _license_files/$(echo '%1' | sed -e 's!/!.!g') %define prerel 0 %define date 20130523 %define build_docs 0 %define rel 1.alpha2.7 %define qtmajor 5 %define qtminor 9 %define qtsubminor 4 %define major_private 1 %define qtversion %{qtmajor}.%{qtminor}.%{qtsubminor} %define libqt5webkitwidgets %mklibname qt5webkitwidgets %qtmajor %define libqt5webkitwidgets_d %mklibname qt%{qtmajor}webkitwidgets -d %define libqt5webkit %mklibname qt5webkit %qtmajor %define libqt5webkit_d %mklibname qt%{qtmajor}webkit -d %define qttarballdir qtwebkit-%version-alpha2 Name: qtwebkit5 Version: 5.212.0 Release: %mkrel %{rel} Summary: Qt WebKit component Group: Development/KDE and Qt License: LGPLv2 with exceptions or GPLv3 with exceptions and GFDL URL: http://www.qt.io Source0: http://download.qt.io/community_releases/%{qtmajor}.%{qtminor}/%{version}/%{qttarballdir}.tar.xz Patch1: pthread.patch # tweak linker flags to minimize memory usage on "small" platforms Source2: qtwebkit-opensource-src-5.2.0-save_memory.patch ## upstream patches Patch100: qtwebkit-5.212.0_fix_missing_sources.patch BuildRequires: qtbase5-devel BuildRequires: pkgconfig(sqlite3) BuildRequires: pkgconfig(gstreamer-1.0) BuildRequires: pkgconfig(gstreamer-app-1.0) BuildRequires: pkgconfig(gstreamer-base-1.0) BuildRequires: pkgconfig(gstreamer-pbutils-1.0) BuildRequires: pkgconfig(gstreamer-plugins-base-1.0) BuildRequires: pkgconfig(gstreamer-video-1.0) BuildRequires: pkgconfig(gstreamer-audio-1.0) BuildRequires: bison BuildRequires: flex BuildRequires: gperf BuildRequires: chrpath BuildRequires: pkgconfig(ruby) BuildRequires: pkgconfig(xrender) BuildRequires: pkgconfig(udev) BuildRequires: pkgconfig(Qt5Widgets) BuildRequires: pkgconfig(libjpeg) BuildRequires: pkgconfig(fontconfig) BuildRequires: pkgconfig(libwebp) BuildRequires: pkgconfig(xcomposite) BuildRequires: pkgconfig(libxslt) BuildRequires: pkgconfig(libxml-2.0) BuildRequires: pkgconfig(Qt5Quick) BuildRequires: pkgconfig(Qt5Gui) BuildRequires: pkgconfig(Qt5Quick) BuildRequires: pkgconfig(Qt5Qml) BuildRequires: cmake BuildRequires: hyphen-devel BuildRequires: cmake(Qt5QuickTest) BuildRequires: cmake(Qt5Positioning) BuildRequires: cmake(Qt5Sensors) BuildRequires: cmake(Qt5WebChannel) BuildRequires: cmake(Qt5Quick) # We're supposed to specify versions here, but these crap Google libs don't do # normal releases. Accordingly, they're not suitable to be system libs. Provides: bundled(angle) Provides: bundled(brotli) Provides: bundled(woff2) #Branch Patchs #Trunk Patchs #Patch from Mageia %description Qt WebKit library is an open source web browser engine. %files %{_qt5_prefix}/libexec/QtWebPluginProcess %{_qt5_prefix}/libexec/QtWebProcess %{_qt5_prefix}/libexec/QtWebDatabaseProcess %{_qt5_prefix}/libexec/QtWebNetworkProcess %{_qt5_qml}/QtWebKit #------------------------------------------------------------------------------ %if %{build_docs} %package doc Summary: QtWebKit%{qtmajor} APIs and tools docs Group: Documentation BuildArch: noarch BuildRequires: qttools5 # This one is required to build QCH-format documentation # for APIs and tools in this package set BuildRequires: qttools5-assistant Recommends: qttools5-assistant %description doc Documentation for APIs and tools in QtWebKit5 package for use with Qt Assistant. %files doc %{_qt5_docdir}/qtwebkit.qch %{_qt5_docdir}/qtwebkit/ %endif #------------------------------------------------------------------------------ %package -n %{libqt5webkitwidgets} Summary: Qt%{qtmajor} Lib Group: System/Libraries %description -n %{libqt5webkitwidgets} Qt%{qtmajor} Lib. %files -n %{libqt5webkitwidgets} %{_qt5_libdir}/libQt5WebKitWidgets.so.%{qtmajor}* #------------------------------------------------------------------------------ %package -n %{libqt5webkitwidgets_d} Summary: Devel files needed to build apps based on QtWebKitWidgets Group: Development/KDE and Qt Requires: %{libqt5webkitwidgets} = %version Requires: qtbase5-common-devel Provides: libqt5webkitwidgets-devel = %version Provides: qt5webkitwidgets-devel = %version Provides: libqtwebkitwidgets5-devel = %version Provides: qtwebkitwidgets5-devel = %version Provides: libqt5webkitwidgets-private-devel = %version Provides: qt5webkitwidgets-private-devel = %version Provides: libqtwebkitwidgets5-private-devel = %version Provides: qtwebkitwidgets5-private-devel = %version %description -n %{libqt5webkitwidgets_d} Devel files needed to build apps based on QtWebKitWidgets. %files -n %{libqt5webkitwidgets_d} %{_qt5_libdir}/libQt5WebKitWidgets.so %{_qt5_libdir}/pkgconfig/Qt5WebKitWidgets.pc %{_qt5_includedir}/QtWebKitWidgets %{_qt5_datadir}/mkspecs/modules/qt_lib_webkitwidgets.pri %{_qt5_libdir}/cmake/Qt5WebKitWidgets #------------------------------------------------------------------------------ %package -n %{libqt5webkit} Summary: Qt%{qtmajor} Lib Group: System/Libraries %description -n %{libqt5webkit} Qt%{qtmajor} Lib. %files -n %{libqt5webkit} %{_qt5_libdir}/libQt5WebKit.so.%{qtmajor}* #------------------------------------------------------------------------------ %package -n %{libqt5webkit_d} Summary: Devel files needed to build apps based on QtWebKitWidgets Group: Development/KDE and Qt Requires: %{libqt5webkit} = %version Provides: libqt5webkit-devel = %version Provides: qt5webkit-devel = %version Provides: libqtwebkit5-devel = %version Provides: qtwebkit5-devel = %version Provides: libqt5webkit-private-devel = %version Provides: qt5webkit-private-devel = %version Provides: libqtwebkit5-private-devel = %version Provides: qtwebkit5-private-devel = %version %description -n %{libqt5webkit_d} Devel files needed to build apps based on QtWebKitWidgets. %files -n %{libqt5webkit_d} %{_qt5_libdir}/libQt5WebKit.so %{_qt5_libdir}/pkgconfig/Qt5WebKit.pc %{_qt5_includedir}/QtWebKit %{_qt5_datadir}/mkspecs/modules/qt_lib_webkit.pri %{_qt5_libdir}/cmake/Qt5WebKit #------------------------------------------------------------------------------ %prep %setup -q -n %qttarballdir %patch100 -p1 %build # The following changes of optflags ietc. are adapted from webkitgtk4 package, which # is mostly similar to this one... # # Increase the DIE limit so our debuginfo packages could be size optimized. # Decreases the size for x86_64 from ~5G to ~1.1G. # https://bugzilla.redhat.com/show_bug.cgi?id=1456261 %global _dwz_max_die_limit 250000000 # Decrease debuginfo even on ix86 because of: # https://bugs.webkit.org/show_bug.cgi?id=140176 %ifarch s390 s390x %{arm} %{ix86} ppc %{power64} %{mips} # Decrease debuginfo verbosity to reduce memory consumption even more %global optflags %(echo %{optflags} | sed 's/-g /-g1 /') %endif %ifarch ppc # Use linker flag -relax to get WebKit build under ppc(32) with JIT disabled %global optflags %{optflags} -Wl,-relax %endif CFLAGS="${CFLAGS:-%optflags}" ; export CFLAGS ; CXXFLAGS="${CXXFLAGS:-%optflags}" ; export CXXFLAGS ; # We cannot use default cmake macro here as it overwrites some settings queried # by qtwebkit cmake from qmake cmake -DPORT=Qt \ -DCMAKE_BUILD_TYPE=Release \ -DENABLE_TOOLS=OFF \ -DCMAKE_C_FLAGS_RELEASE:STRING="-DNDEBUG" \ -DCMAKE_CXX_FLAGS_RELEASE:STRING="-DNDEBUG" \ -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \ %ifarch s390 s390x ppc %{power64} -DENABLE_JIT=OFF \ %endif %ifarch s390 s390x ppc %{power64} -DUSE_SYSTEM_MALLOC=ON \ %endif %if 0%{?docs} -DGENERATE_DOCUMENTATION=ON \ %endif . %make_build %if %{build_docs} %__make docs %endif %install %make_install INSTALL_ROOT=%{buildroot} %if %{build_docs} %make_install install_docs INSTALL_ROOT=%{buildroot} %endif # .la and .a files, die, die, die. find %{buildroot} -name '*.a' -delete find %{buildroot} -name '*.la' -exec rm -f {} ';' # fix pkgconfig files sed -i '/Name/a Description: Qt5 WebKit module' %{buildroot}%{_libdir}/pkgconfig/Qt5WebKit.pc sed -i "s,Cflags: -I%{_qt5_includedir}/Qt5WebKit,Cflags: -I%{_qt5_includedir}/QtWebKit,g" %{buildroot}%{_libdir}/pkgconfig/Qt5WebKit.pc sed -i "s,Libs: -L%{_qt5_libdir}/qt5/../ -lQt5WebKit,Libs: -L%{_qt5_libdir} -lQt5WebKit ,g" %{buildroot}%{_libdir}/pkgconfig/Qt5WebKit.pc sed -i '/Name/a Description: Qt5 WebKitWidgets module' %{buildroot}%{_libdir}/pkgconfig/Qt5WebKitWidgets.pc sed -i "s,Cflags: -I%{_qt5_includedir}/Qt5WebKitWidgets,Cflags: -I%{_qt5_includedir}/QtWebKitWidgets,g" %{buildroot}%{_libdir}/pkgconfig/Qt5WebKitWidgets.pc sed -i "s,Libs: -L%{_qt5_libdir}/qt5/../ -lQt5WebKitWidgets,Libs: -L%{_qt5_libdir} -lQt5WebKitWidgets ,g" %{buildroot}%{_libdir}/pkgconfig/Qt5WebKitWidgets.pc # Finally, copy over and rename various files for %%license inclusion %add_to_license_files Source/JavaScriptCore/COPYING.LIB %add_to_license_files Source/JavaScriptCore/icu/LICENSE %add_to_license_files Source/ThirdParty/ANGLE/LICENSE %add_to_license_files Source/ThirdParty/ANGLE/src/third_party/compiler/LICENSE %add_to_license_files Source/ThirdParty/ANGLE/src/third_party/murmurhash/LICENSE %add_to_license_files Source/WebCore/icu/LICENSE %add_to_license_files Source/WebCore/LICENSE-APPLE %add_to_license_files Source/WebCore/LICENSE-LGPL-2 %add_to_license_files Source/WebCore/LICENSE-LGPL-2.1 %add_to_license_files Source/WebInspectorUI/UserInterface/External/CodeMirror/LICENSE %add_to_license_files Source/WebInspectorUI/UserInterface/External/Esprima/LICENSE %add_to_license_files Source/WTF/icu/LICENSE %add_to_license_files Source/WTF/wtf/dtoa/COPYING %add_to_license_files Source/WTF/wtf/dtoa/LICENSE %changelog * Mon Mar 05 2018 neoclust <neoclust> 5.212.0-1.alpha2.7.mga6 (not released yet) + Revision: 1206712 - Rebuild against qtwebkit5 - New version 5.212.0 - New version 5.6.3 * Mon Mar 20 2017 neoclust <neoclust> 5.6.2-2.mga6 + Revision: 1093714 - Rebuild against new icu * Fri Nov 04 2016 daviddavid <daviddavid> 5.6.2-1.mga6 + Revision: 1065264 - New version 5.6.2 - Remove merged upstream patches * Fri Sep 02 2016 daviddavid <daviddavid> 5.6.1-2.mga6 + Revision: 1049797 - build missing docs part (mga#9812) - add qtwebkit5-doc subpackage * Thu Jul 14 2016 daviddavid <daviddavid> 5.6.1-1.mga6 + Revision: 1042057 - new version: 5.6.1 - backport two upstream patches - update Source URL * Wed May 25 2016 pterjan <pterjan> 5.5.1-9.mga6 + Revision: 1018226 - Try fixing linking errors * Fri May 13 2016 shlomif <shlomif> 5.5.1-8.mga6 + Revision: 1014871 - Rebuild for new ICU * Fri Jan 01 2016 luigiwalser <luigiwalser> 5.5.1-7.mga6 + Revision: 917920 - rebuild for icu * Wed Dec 23 2015 neoclust <neoclust> 5.5.1-6.mga6 + Revision: 913849 - Fix require on qtbase * Wed Dec 23 2015 neoclust <neoclust> 5.5.1-5.mga6 + Revision: 913826 - Remove private-devel packages * Wed Dec 23 2015 neoclust <neoclust> 5.5.1-4.mga6 + Revision: 913824 - Sync with 5.6.0 branch - Rebuild against qt 5.6.0 beta * Wed Nov 11 2015 blino <blino> 5.5.1-3.mga6 + Revision: 902252 - on 32-bit systems (including ARMv5/v7)), reduce memory pressure at link with lighter debuginfo and the -Wl,--no-keep-memory linker option * Tue Nov 10 2015 neoclust <neoclust> 5.5.1-2.mga6 + Revision: 900361 - Rebuild against fixed qtbase5 * Fri Oct 23 2015 neoclust <neoclust> 5.5.1-1.mga6 + Revision: 894509 - New version * Sat Jul 25 2015 cjw <cjw> 5.5.0-2.mga6 + Revision: 857376 - rebuild for icu 55 * Sun Jul 12 2015 filipesaraiva <filipesaraiva> 5.5.0-1.mga6 + Revision: 853392 - Update to Qt 5.5.0 version; - Fix URL to new address qt.io; - Delete old sources; * Wed Jun 24 2015 neoclust <neoclust> 5.5.0-0.rc.1.mga6 + Revision: 841694 - New version 5.5 rc * Wed Apr 22 2015 luigiwalser <luigiwalser> 5.4.0-2.mga5 + Revision: 820553 - add patch from fedora to fix security issue (mga#15749, rhbz#1204795) * Sat Dec 13 2014 neoclust <neoclust> 5.4.0-1.mga5 + Revision: 802869 - New version 5.4.0 * Sun Dec 07 2014 neoclust <neoclust> 5.3.2-1.mga5 + Revision: 801817 - New version 5.3.2 * Wed Oct 15 2014 umeabot <umeabot> 5.3.1-3.mga5 + Revision: 743750 - Second Mageia 5 Mass Rebuild * Tue Sep 16 2014 umeabot <umeabot> 5.3.1-2.mga5 + Revision: 688566 - Mageia 5 Mass Rebuild * Thu Jun 26 2014 fwang <fwang> 5.3.1-1.mga5 + Revision: 639800 - 5.3.1 * Tue May 20 2014 fwang <fwang> 5.3.0-1.mga5 + Revision: 624045 - 5.3.0 final * Fri May 09 2014 fwang <fwang> 5.3.0-0.rc.1.mga5 + Revision: 621500 - 5.3.0 rc * Sun Apr 06 2014 fwang <fwang> 5.3.0-0.beta.1.mga5 + Revision: 612322 - 5.3.0beta * Sat Apr 05 2014 wally <wally> 5.3.0-0.alpha.2.mga5 + Revision: 611894 - rebuild for new icu * Mon Mar 03 2014 neoclust <neoclust> 5.3.0-0.alpha.1.mga5 + Revision: 598970 - New version 5.3.0 Alpha1 * Mon Feb 24 2014 neoclust <neoclust> 5.2.1-4.mga5 + Revision: 596165 - Rebuild against new libwebp * Sun Feb 09 2014 fwang <fwang> 5.2.1-3.mga5 + Revision: 586989 - hard force versioned requires * Thu Feb 06 2014 fwang <fwang> 5.2.1-2.mga5 + Revision: 584416 - use gstreamer 1.0 * Thu Feb 06 2014 fwang <fwang> 5.2.1-1.mga5 + Revision: 584201 - new version 5.2.1 * Sat Dec 14 2013 fwang <fwang> 5.2.0-2.mga4 + Revision: 556705 - 5.2.0 final * Sun Dec 01 2013 fwang <fwang> 5.2.0-1.rc1.1.mga4 + Revision: 554479 - update file list - 5.2.0 rc1 * Sat Oct 26 2013 fwang <fwang> 5.2.0-1.beta1.1.mga4 + Revision: 547134 - br udev - 5.2.0 beta1 * Mon Oct 21 2013 umeabot <umeabot> 5.2.0-1.alpha.2.mga4 + Revision: 538933 - Mageia 4 Mass Rebuild * Fri Oct 04 2013 fwang <fwang> 5.2.0-1.alpha.1.mga4 + Revision: 491104 - 5.2.0 alpha1 - rebuild for icu 52 + tmb <tmb> - rebuild for new icu * Sun Jun 02 2013 fwang <fwang> 5.2.0-0.0.20130523.3.mga4 + Revision: 434692 - rebuild for new libpng * Mon May 27 2013 neoclust <neoclust> 5.2.0-0.0.20130523.2.mga4 + Revision: 428827 - Rebuild against new qt5 libs location * Mon May 27 2013 neoclust <neoclust> 5.2.0-0.0.20130523.1.mga4 + Revision: 428730 - buildrequire qt5widgets-private-devel for private/qaccessiblewidget_p.h ( blino) - New QT 5.2 Snapshot * Thu Apr 18 2013 neoclust <neoclust> 5.0.2-1.mga3 + Revision: 410402 - New version 5.0.2 * Sat Feb 02 2013 fwang <fwang> 5.0.1-3.mga3 + Revision: 394061 - br qml - fix pkgconfig requries * Sat Feb 02 2013 neoclust <neoclust> 5.0.1-2.mga3 + Revision: 394014 - Split private headers in its own package + fwang <fwang> - 5.0.1 final * Sat Jan 26 2013 neoclust <neoclust> 5.0.1-0.rc1.4.mga3 + Revision: 392543 - Revert previous wrong commit * Sat Jan 26 2013 neoclust <neoclust> 5.0.1-0.rc1.3.mga3 + Revision: 392542 - Try using gstreamer 1.0 * Sat Jan 26 2013 neoclust <neoclust> 5.0.1-0.rc1.2.mga3 + Revision: 392530 - Add QtQuick support * Sat Jan 26 2013 neoclust <neoclust> 5.0.1-0.rc1.1.mga3 + Revision: 392377 - New version 5.0.1 rc1 * Sat Jan 26 2013 neoclust <neoclust> 5.0.0-1.mga3 + Revision: 392319 - SIELNT: Use _disable_ld_no_undefined for the moment - imported package qtwebkit5 + fwang <fwang> - add more br