qt5-qtwebengine-vl.spec 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809
  1. %global qt_module qtwebengine
  2. %global _hardened_build 1
  3. %if 0
  4. # need libvpx >= 1.8.0
  5. %global use_system_libvpx 1
  6. %endif
  7. %if 0
  8. # need libwebp >= 0.4.3
  9. %global use_system_libwebp 1
  10. %endif
  11. # upstream source does not support icu >= 68
  12. %if 0
  13. %global use_system_libicu 1
  14. %endif
  15. #global prerelease rc
  16. # spellchecking dictionary directory
  17. %global _qtwebengine_dictionaries_dir %{_qt5_datadir}/qtwebengine_dictionaries
  18. %global rpm_macros_dir %(d=%{_rpmconfigdir}/macros.d; [ -d $d ] || d=%{_sysconfdir}/rpm; echo $d)
  19. # exclude plugins (all architectures) and libv8.so (i686, it's static everywhere
  20. # else)
  21. %global __provides_exclude ^lib.*plugin\\.so.*|libv8\\.so$
  22. # exclude libv8.so (i686, it's static everywhere else)
  23. %global __requires_exclude ^libv8\\.so$
  24. # and designer plugins
  25. %global __provides_exclude_from ^%{_qt5_plugindir}/.*\\.so$
  26. %global qt5_minorver 5.15
  27. %global qt5_version 5.15.2
  28. #global qt5_patchlevel 1
  29. Summary: Qt5 - QtWebEngine components
  30. Name: qt5-qtwebengine
  31. Version: %{qt5_version}%{?qt5_patchlevel:.%{qt5_patchlevel}}
  32. Release: 1%{?_dist_release}
  33. Group: system
  34. Vendor: Project Vine
  35. Distribution: Vine Linux
  36. # See LICENSE.GPL LICENSE.LGPL LGPL_EXCEPTION.txt, for details
  37. # See also http://qt-project.org/doc/qt-5.0/qtdoc/licensing.html
  38. # The other licenses are from Chromium and the code it bundles
  39. License: (LGPLv2 with exceptions or GPLv3 with exceptions) and BSD and LGPLv2+ and ASL 2.0 and IJG and MIT and GPLv2+ and ISC and OpenSSL and (MPLv1.1 or GPLv2 or LGPLv2)
  40. URL: https://www.qt.io/
  41. # cleaned tarball with patent-encumbered codecs removed from the bundled FFmpeg
  42. # wget https://download.qt.io/official_releases/qt/5.6/5.6.1-1/submodules/qtwebengine-everywhere-src-5.6.1-1.tar.xz
  43. # ./clean_qtwebengine.sh 5.6.1-1
  44. Source0: %{qt_module}-everywhere-src-%{qt5_version}%{?qt5_patchlevel:-%{qt5_patchlevel}}-clean.tar.xz
  45. # cleanup scripts used above
  46. Source1: clean_qtwebengine.sh
  47. Source2: clean_ffmpeg.sh
  48. Source3: get_free_ffmpeg_source_files.py
  49. # macros
  50. Source10: macros.qt5-qtwebengine
  51. # pulseaudio headers
  52. Source20: pulseaudio-12.2-headers.tar.gz
  53. # some tweaks to linux.pri (system yasm, link libpci, run unbundling script)
  54. Patch0: qtwebengine-everywhere-src-5.10.0-linux-pri.patch
  55. # quick hack to avoid checking for the nonexistent icudtl.dat and silence the
  56. # resulting warnings - not upstreamable as is because it removes the fallback
  57. # mechanism for the ICU data directory (which is not used in our builds because
  58. # we use the system ICU, which embeds the data statically) completely
  59. Patch1: qtwebengine-everywhere-src-5.11.0-no-icudtl-dat.patch
  60. # fix extractCFlag to also look in QMAKE_CFLAGS_RELEASE, needed to detect the
  61. # ARM flags with our %%qmake_qt5 macro, including for the next patch
  62. Patch2: qtwebengine-opensource-src-5.12.4-fix-extractcflag.patch
  63. # disable NEON vector instructions on ARM where the NEON code FTBFS due to
  64. # GCC bug https://bugzilla.redhat.com/show_bug.cgi?id=1282495
  65. Patch3: qtwebengine-opensource-src-5.9.0-no-neon.patch
  66. # workaround FTBFS against kernel-headers-5.2.0+
  67. Patch4: qtwebengine-SIOCGSTAMP.patch
  68. # remove Android dependencies from openmax_dl ARM NEON detection (detect.c)
  69. Patch10: qtwebengine-opensource-src-5.9.0-openmax-dl-neon.patch
  70. # Force verbose output from the GN bootstrap process
  71. Patch21: qtwebengine-everywhere-src-5.12.0-gn-bootstrap-verbose.patch
  72. # Fix/workaround FTBFS on aarch64 with newer glibc
  73. Patch24: qtwebengine-everywhere-src-5.11.3-aarch64-new-stat.patch
  74. # Use Python2
  75. Patch26: qtwebengine-everywhere-5.13.2-use-python2.patch
  76. # Missing #includes for gcc-11
  77. Patch27: qtwebengine-gcc11.patch
  78. # Fix sandbox issue breaking text rendering with glibc >= 2.33 (#1904652)
  79. Patch28: qtwebengine-everywhere-src-5.15.2-#1904652.patch
  80. # Fix sandbox issue on 32-bit architectures with glibc >= 2.31 (from Debian)
  81. Patch29: qtwebengine-everywhere-src-5.15.2-sandbox-time64-syscalls.patch
  82. # from upstream
  83. Patch1000: icu-68.patch
  84. # handled by qt5-srpm-macros, which defines %%qt5_qtwebengine_arches
  85. ExclusiveArch: %{qt5_qtwebengine_arches}
  86. BuildRequires: qt5-rpm-macros
  87. BuildRequires: qt5-srpm-macros
  88. BuildRequires: qt5-qtbase-devel
  89. BuildRequires: qt5-qtbase-private-devel
  90. # TODO: check of = is really needed or if >= would be good enough -- rex
  91. %{?_qt5:Requires: %{_qt5}%{?_isa} = %{_qt5_version}}
  92. BuildRequires: qt5-qtdeclarative-devel
  93. BuildRequires: qt5-qtxmlpatterns-devel
  94. BuildRequires: qt5-qtlocation-devel
  95. BuildRequires: qt5-qtsensors-devel
  96. BuildRequires: qt5-qtsvg-devel
  97. BuildRequires: qt5-qtwebchannel-devel
  98. BuildRequires: qt5-qttools-static
  99. # for examples?
  100. BuildRequires: qt5-qtquickcontrols2-devel
  101. BuildRequires: ninja
  102. BuildRequires: cmake
  103. BuildRequires: bison
  104. BuildRequires: flex
  105. BuildRequires: gcc-c++
  106. # gn links statically (for now)
  107. BuildRequires: libstdc++-static
  108. BuildRequires: git-core
  109. BuildRequires: gperf
  110. BuildRequires: krb5-devel
  111. %if 0%{?use_system_libicu}
  112. BuildRequires: libicu-devel
  113. %endif
  114. BuildRequires: libjpeg-turbo-devel
  115. #BuildRequires: re2-devel
  116. BuildRequires: snappy-devel
  117. %ifarch %{ix86} x86_64
  118. BuildRequires: yasm
  119. %endif
  120. BuildRequires: pkgconfig(expat)
  121. BuildRequires: pkgconfig(gobject-2.0)
  122. BuildRequires: pkgconfig(glib-2.0)
  123. BuildRequires: pkgconfig(fontconfig)
  124. BuildRequires: pkgconfig(freetype2)
  125. BuildRequires: pkgconfig(gl)
  126. BuildRequires: pkgconfig(egl)
  127. BuildRequires: pkgconfig(jsoncpp)
  128. BuildRequires: pkgconfig(libpng)
  129. BuildRequires: pkgconfig(libudev)
  130. %if 0%{?use_system_libwebp}
  131. BuildRequires: pkgconfig(libwebp) >= 0.6.0
  132. %endif
  133. BuildRequires: pkgconfig(harfbuzz)
  134. BuildRequires: pkgconfig(libdrm)
  135. BuildRequires: opus-devel
  136. BuildRequires: pkgconfig(protobuf)
  137. BuildRequires: pkgconfig(libevent)
  138. BuildRequires: zlib-devel
  139. #BuildRequires: pkgconfig(minizip)
  140. BuildRequires: pkgconfig(x11)
  141. BuildRequires: pkgconfig(xi)
  142. BuildRequires: libXcursor-devel
  143. BuildRequires: pkgconfig(xext)
  144. BuildRequires: pkgconfig(xfixes)
  145. BuildRequires: pkgconfig(xrender)
  146. BuildRequires: pkgconfig(xdamage)
  147. BuildRequires: pkgconfig(xcomposite)
  148. BuildRequires: pkgconfig(xtst)
  149. BuildRequires: pkgconfig(xrandr)
  150. BuildRequires: pkgconfig(xscrnsaver)
  151. BuildRequires: pkgconfig(libcap)
  152. BuildRequires: pkgconfig(libpulse)
  153. BuildRequires: pkgconfig(alsa)
  154. BuildRequires: pciutils-devel
  155. BuildRequires: pkgconfig(dbus-1)
  156. BuildRequires: pkgconfig(nss)
  157. BuildRequires: pkgconfig(lcms2)
  158. BuildRequires: pkgconfig(xkbcommon)
  159. BuildRequires: perl
  160. BuildRequires: python
  161. BuildRequires: python-rpm-macros
  162. BuildRequires: python2-rpm-macros
  163. %if 0%{?use_system_libvpx}
  164. BuildRequires: pkgconfig(vpx) >= 1.7.0
  165. %endif
  166. # extra (non-upstream) functions needed, see
  167. # src/3rdparty/chromium/third_party/sqlite/README.chromium for details
  168. #BuildRequires: pkgconfig(sqlite3)
  169. ## Various bundled libraries that Chromium does not support unbundling :-(
  170. ## Only the parts actually built are listed.
  171. ## Query for candidates:
  172. ## grep third_party/ build.log | sed 's!third_party/!\nthird_party/!g' | \
  173. ## grep third_party/ | sed 's!^third_party/!!g' | sed 's!/.*$!!g' | \
  174. ## sed 's/\;.*$//g' | sed 's/ .*$//g' | sort | uniq | less
  175. ## some false positives where only shim headers are generated for some reason
  176. ## some false positives with dummy placeholder dirs (swiftshader, widevine)
  177. ## some false negatives where a header-only library is bundled (e.g. x86inc)
  178. ## Spot's chromium.spec also has a list that I checked.
  179. # Of course, Chromium itself is bundled. It cannot be unbundled because it is
  180. # not a library, but forked (modified) application code.
  181. # Some security fixes are backported, see:
  182. # http://code.qt.io/cgit/qt/qtwebengine-chromium.git/log/?h=45-based
  183. Provides: bundled(chromium) = 61.0.3163.140
  184. # Bundled in src/3rdparty/chromium/third_party:
  185. # Check src/3rdparty/chromium/third_party/*/README.chromium for version numbers,
  186. # except where specified otherwise.
  187. Provides: bundled(angle) = 2422
  188. # Google's fork of OpenSSL
  189. # We cannot build against NSS instead because it no longer works with NSS 3.21:
  190. # HTTPS on, ironically, Google's sites (Google, YouTube, etc.) stops working
  191. # completely and produces only ERR_SSL_PROTOCOL_ERROR errors:
  192. # http://kaosx.us/phpBB3/viewtopic.php?t=1235
  193. # https://bugs.launchpad.net/ubuntu/+source/chromium-browser/+bug/1520568
  194. # So we have to do what Chromium 47 now defaults to: a "chimera build", i.e.,
  195. # use the BoringSSL code and the system NSS certificates.
  196. Provides: bundled(boringssl)
  197. Provides: bundled(brotli)
  198. # Don't get too excited. MPEG and other legally problematic stuff is stripped
  199. # out. See clean_qtwebengine.sh, clean_ffmpeg.sh, and process_ffmpeg_gyp.py.
  200. # see src/3rdparty/chromium/third_party/ffmpeg/Changelog for the version number
  201. Provides: bundled(ffmpeg) = 3.3
  202. Provides: bundled(hunspell) = 1.6.0
  203. Provides: bundled(iccjpeg)
  204. # bundled as "khronos", headers only
  205. Provides: bundled(khronos_headers)
  206. # bundled as "leveldatabase"
  207. Provides: bundled(leveldb) = 1.20
  208. # bundled as "libjingle_xmpp"
  209. Provides: bundled(libjingle)
  210. # see src/3rdparty/chromium/third_party/libsrtp/CHANGES for the version number
  211. Provides: bundled(libsrtp) = 2.1.0
  212. %if !0%{?use_system_libvpx}
  213. # claims "Version: 1.6.0", but according to the fine print, this is actually a
  214. # snapshot from master from after the 1.6.1 release
  215. Provides: bundled(libvpx) = 1.6.1
  216. %endif
  217. %if !0%{?use_system_libwebp}
  218. Provides: bundled(libwebp) = 0.6.0
  219. %endif
  220. # bundled as "libxml"
  221. # see src/3rdparty/chromium/third_party/libxml/linux/include/libxml/xmlversion.h
  222. Provides: bundled(libxml2) = 2.9.4
  223. # see src/3rdparty/chromium/third_party/libxslt/linux/config.h for version
  224. Provides: bundled(libxslt) = 1.1.29
  225. Provides: bundled(libXNVCtrl) = 302.17
  226. Provides: bundled(libyuv) = 1658
  227. Provides: bundled(modp_b64)
  228. Provides: bundled(openmax_dl) = 1.0.2
  229. Provides: bundled(ots)
  230. # see src/3rdparty/chromium/third_party/protobuf/CHANGES.txt for the version
  231. #Provides: bundled(protobuf) = 3.0.0-0.1.beta3
  232. Provides: bundled(qcms) = 4
  233. Provides: bundled(sfntly)
  234. Provides: bundled(skia)
  235. # bundled as "smhasher"
  236. Provides: bundled(SMHasher) = 0-0.1.svn147
  237. Provides: bundled(sqlite) = 3.20
  238. Provides: bundled(usrsctp)
  239. Provides: bundled(webrtc) = 90
  240. %ifarch %{ix86} x86_64
  241. # bundled by ffmpeg and libvpx:
  242. # header (for assembly) only
  243. Provides: bundled(x86inc)
  244. %endif
  245. # Bundled in src/3rdparty/chromium/base/third_party:
  246. # Check src/3rdparty/chromium/third_party/base/*/README.chromium for version
  247. # numbers, except where specified otherwise.
  248. Provides: bundled(dmg_fp)
  249. Provides: bundled(dynamic_annotations) = 4384
  250. Provides: bundled(superfasthash) = 0
  251. Provides: bundled(symbolize)
  252. # bundled as "valgrind", headers only
  253. Provides: bundled(valgrind.h)
  254. # bundled as "xdg_mime"
  255. Provides: bundled(xdg-mime)
  256. # bundled as "xdg_user_dirs"
  257. Provides: bundled(xdg-user-dirs) = 0.10
  258. # Bundled in src/3rdparty/chromium/net/third_party:
  259. # Check src/3rdparty/chromium/third_party/net/*/README.chromium for version
  260. # numbers, except where specified otherwise.
  261. Provides: bundled(mozilla_security_manager) = 1.9.2
  262. # Bundled in src/3rdparty/chromium/url/third_party:
  263. # Check src/3rdparty/chromium/third_party/url/*/README.chromium for version
  264. # numbers, except where specified otherwise.
  265. # bundled as "mozilla", file renamed and modified
  266. Provides: bundled(nsURLParsers)
  267. # Bundled outside of third_party, apparently not considered as such by Chromium:
  268. Provides: bundled(mojo)
  269. # see src/3rdparty/chromium/v8/include/v8_version.h for the version number
  270. Provides: bundled(v8) = 6.1.534.44
  271. # bundled by v8 (src/3rdparty/chromium/v8/src/base/ieee754.cc)
  272. # The version number is 5.3, the last version that upstream released, years ago:
  273. # http://www.netlib.org/fdlibm/readme
  274. Provides: bundled(fdlibm) = 5.3
  275. %{?_qt5_version:Requires: qt5-qtbase%{?_isa} >= %{_qt5_version}}
  276. %description
  277. %{summary}.
  278. %package devel
  279. Summary: Development files for %{name}
  280. Requires: %{name}%{?_isa} = %{version}-%{release}
  281. Requires: qt5-qtbase-devel%{?_isa}
  282. Requires: qt5-qtdeclarative-devel%{?_isa}
  283. # not arch'd for now, see if can get away with avoiding multilib'ing -- rex
  284. Requires: %{name}-devtools = %{version}-%{release}
  285. %description devel
  286. %{summary}.
  287. %package devtools
  288. Summary: WebEngine devtools_resources
  289. Requires: %{name}%{?_isa} = %{version}-%{release}
  290. %description devtools
  291. Support for remote debugging.
  292. %package examples
  293. Summary: Example files for %{name}
  294. %description examples
  295. %{summary}.
  296. %if 0%{?docs}
  297. %package doc
  298. Summary: API documentation for %{name}
  299. BuildRequires: qt5-qhelpgenerator
  300. BuildRequires: qt5-qdoc
  301. BuildArch: noarch
  302. %description doc
  303. %{summary}.
  304. %endif
  305. %debug_package
  306. %prep
  307. %setup -q -n %{qt_module}-everywhere-src-%{qt5_version}
  308. %if 0
  309. tar xvf %{SOURCE20}
  310. mv pulse src/3rdparty/chromium/
  311. %endif
  312. %patch0 -p1 -b .linux-pri
  313. %if 0%{?use_system_libicu}
  314. %patch1 -p1 -b .no-icudtl-dat
  315. %endif
  316. %patch2 -p1 -b .fix-extractcflag
  317. %if !0%{?arm_neon}
  318. %patch3 -p1 -b .no-neon
  319. %endif
  320. %patch4 -p1 -b .SIOCGSTAMP
  321. ## upstream patches
  322. #patch10 -p1 -b .openmax-dl-neon
  323. ## NEEDSWORK
  324. #patch21 -p1 -b .gn-bootstrap-verbose
  325. %patch24 -p1 -b .aarch64-new-stat
  326. %patch26 -p1 -b .use-python2
  327. %patch27 -p1 -b .gcc11
  328. %patch28 -p1 -b .rh#1904652
  329. %patch29 -p1 -b .sandbox-time64-syscalls
  330. %if 0%{?use_system_libicu}
  331. # for ICU-68 or later
  332. pushd src/3rdparty
  333. %patch1000 -p1
  334. sed -i -e 's/TRUE/1/' chromium/third_party/libxml/src/encoding.c
  335. popd
  336. %endif
  337. # the xkbcommon config/feature was renamed in 5.12, so need to adjust QT_CONFIG references
  338. # when building on older Qt releases
  339. %if "%{_qt5_version}" < "5.12.0"
  340. sed -i -e 's|QT_CONFIG(xkbcommon)|QT_CONFIG(xkbcommon_evdev)|g' src/core/web_event_factory.cpp
  341. %endif
  342. # fix // in #include in content/renderer/gpu to avoid debugedit failure
  343. #sed -i -e 's!gpu//!gpu/!g' \
  344. # src/3rdparty/chromium/content/renderer/gpu/compositor_forwarding_message_filter.cc
  345. # and another one in 2 files in WebRTC
  346. sed -i -e 's!audio_processing//!audio_processing/!g' \
  347. src/3rdparty/chromium/third_party/webrtc/modules/audio_processing/utility/ooura_fft.cc \
  348. src/3rdparty/chromium/third_party/webrtc/modules/audio_processing/utility/ooura_fft_sse2.cc
  349. # remove ./ from #line commands in ANGLE to avoid debugedit failure (?)
  350. #sed -i -e 's!\./!!g' \
  351. # src/3rdparty/chromium/third_party/angle/src/compiler/preprocessor/Tokenizer.cpp \
  352. # src/3rdparty/chromium/third_party/angle/src/compiler/translator/glslang_lex.cpp
  353. # delete all "toolprefix = " lines from build/toolchain/linux/BUILD.gn, as we
  354. # never cross-compile in native Fedora RPMs, fixes ARM and aarch64 FTBFS
  355. sed -i -e '/toolprefix = /d' -e 's/\${toolprefix}//g' \
  356. src/3rdparty/chromium/build/toolchain/linux/BUILD.gn
  357. # http://bugzilla.redhat.com/1337585
  358. # can't just delete, but we'll overwrite with system headers to be on the safe side
  359. #cp -bv /usr/include/re2/*.h src/3rdparty/chromium/third_party/re2/src/re2/
  360. %if 0
  361. #ifarch x86_64
  362. # enable this to force -g2 on x86_64 (most arches run out of memory with -g2)
  363. # DISABLED BECAUSE OF:
  364. # /usr/lib/rpm/find-debuginfo.sh: line 188: 3619 Segmentation fault
  365. # (core dumped) eu-strip --remove-comment $r $g -f "$1" "$2"
  366. sed -i -e 's/symbol_level=1/symbol_level=2/g' src/core/config/common.pri
  367. %endif
  368. # generate qtwebengine-3rdparty.qdoc, it is missing from the tarball
  369. pushd src/3rdparty
  370. %{__python2} chromium/tools/licenses.py \
  371. --file-template ../../tools/about_credits.tmpl \
  372. --entry-template ../../tools/about_credits_entry.tmpl \
  373. credits >../webengine/doc/src/qtwebengine-3rdparty.qdoc
  374. popd
  375. # copy the Chromium license so it is installed with the appropriate name
  376. cp -p src/3rdparty/chromium/LICENSE LICENSE.Chromium
  377. %build
  378. export STRIP=strip
  379. export NINJAFLAGS="%{?__ninja_common_opts}"
  380. export NINJA_PATH=%{_bindir}/ninja-build
  381. export RE2_INCLUDE=$(pwd)/src/3rdparty/chromium/third_party/re2
  382. export CFLAGS="%{optflags}"
  383. #ifnarch x86_64
  384. # most arches run out of memory with full debuginfo, so use -g1 on non-x86_64
  385. export CFLAGS=`echo "$CFLAGS" | sed -e 's/ -g / -g1 /g'`
  386. #endif
  387. export CXXFLAGS="%{optflags}"
  388. #ifnarch x86_64
  389. # most arches run out of memory with full debuginfo, so use -g1 on non-x86_64
  390. export CXXFLAGS=`echo "$CXXFLAGS" | sed -e 's/ -g / -g1 /g'`
  391. #endif
  392. mkdir %{_target_platform}
  393. pushd %{_target_platform}
  394. %{qmake_qt5} \
  395. %{?debug_config:CONFIG+="%{debug_config}"} \
  396. CONFIG+="link_pulseaudio use_gold_linker" \
  397. %{?use_system_libicu:QMAKE_EXTRA_ARGS+="-system-webengine-icu"} \
  398. QMAKE_EXTRA_ARGS+="-webengine-kerberos" \
  399. ..
  400. # if we keep these set here, gyp picks up duplicate flags
  401. unset CFLAGS
  402. export CFLAGS
  403. unset CXXFLAGS
  404. export CXXFLAGS
  405. # workaround, disable parallel compilation as it fails to compile in brew
  406. make %{?_smp_mflags}
  407. popd
  408. %install
  409. rm -rf %{buildroot}
  410. make install INSTALL_ROOT=%{buildroot} -C %{_target_platform}
  411. # rpm macros
  412. install -p -m644 -D %{SOURCE10} \
  413. %{buildroot}%{rpm_macros_dir}/macros.qt5-qtwebengine
  414. sed -i \
  415. -e "s|@@NAME@@|%{name}|g" \
  416. -e "s|@@EPOCH@@|%{?epoch}%{!?epoch:0}|g" \
  417. -e "s|@@VERSION@@|%{version}|g" \
  418. -e "s|@@EVR@@|%{?epoch:%{epoch:}}%{version}-%{release}|g" \
  419. %{buildroot}%{rpm_macros_dir}/macros.qt5-qtwebengine
  420. # hardlink files to {_bindir}
  421. mkdir -p %{buildroot}%{_bindir}
  422. pushd %{buildroot}%{_qt5_bindir}
  423. for i in * ; do
  424. ln -v ${i} %{buildroot}%{_bindir}/${i}
  425. done
  426. popd
  427. ## .prl/.la file love
  428. # nuke .prl reference(s) to %%buildroot, excessive (.la-like) libs
  429. pushd %{buildroot}%{_qt5_libdir}
  430. for prl_file in libQt5*.prl ; do
  431. sed -i -e "/^QMAKE_PRL_BUILD_DIR/d" ${prl_file}
  432. if [ -f "$(basename ${prl_file} .prl).so" ]; then
  433. rm -fv "$(basename ${prl_file} .prl).la"
  434. sed -i -e "/^QMAKE_PRL_LIBS/d" ${prl_file}
  435. fi
  436. done
  437. popd
  438. # explicitly omit, at least until there's a real library installed associated with it -- rex
  439. rm -fv %{buildroot}%{_libdir}/Qt5WebEngineCore.la
  440. mkdir -p %{buildroot}%{_qtwebengine_dictionaries_dir}
  441. # adjust cmake dep(s) to allow for using the same Qt5 that was used to build it
  442. # using the lesser of %%version, %%_qt5_version
  443. %global lesser_version $(echo -e "%{version}\\n%{_qt5_version}" | sort -V | head -1)
  444. sed -i -e "s|%{version} \${_Qt5WebEngine|%{lesser_version} \${_Qt5WebEngine|" \
  445. %{buildroot}%{_qt5_libdir}/cmake/Qt5WebEngine*/Qt5WebEngine*Config.cmake
  446. %files
  447. %license LICENSE.* src/webengine/doc/src/qtwebengine-3rdparty.qdoc
  448. %{_qt5_libdir}/libQt5*.so.*
  449. %{_bindir}/qwebengine_convert_dict
  450. %{_qt5_bindir}/qwebengine_convert_dict
  451. %{_qt5_libdir}/qt5/qml/*
  452. %{_qt5_libdir}/qt5/libexec/QtWebEngineProcess
  453. #ifarch %{ix86}
  454. %if 0%{?sse2}
  455. # shared V8 library and its SSE2 version
  456. %{_qt5_libdir}/qtwebengine/
  457. %endif
  458. %{_qt5_plugindir}/designer/libqwebengineview.so
  459. %{_qt5_plugindir}/imageformats/libqpdf.so
  460. %dir %{_qt5_datadir}/resources/
  461. %if ! 0%{?use_system_libicu}
  462. %{_qt5_datadir}/resources/icudtl.dat
  463. %endif
  464. %{_qt5_datadir}/resources/qtwebengine_resources_100p.pak
  465. %{_qt5_datadir}/resources/qtwebengine_resources_200p.pak
  466. %{_qt5_datadir}/resources/qtwebengine_resources.pak
  467. %dir %{_qtwebengine_dictionaries_dir}
  468. %dir %{_qt5_translationdir}/qtwebengine_locales
  469. %lang(am) %{_qt5_translationdir}/qtwebengine_locales/am.pak
  470. %lang(ar) %{_qt5_translationdir}/qtwebengine_locales/ar.pak
  471. %lang(bg) %{_qt5_translationdir}/qtwebengine_locales/bg.pak
  472. %lang(bn) %{_qt5_translationdir}/qtwebengine_locales/bn.pak
  473. %lang(ca) %{_qt5_translationdir}/qtwebengine_locales/ca.pak
  474. %lang(cs) %{_qt5_translationdir}/qtwebengine_locales/cs.pak
  475. %lang(da) %{_qt5_translationdir}/qtwebengine_locales/da.pak
  476. %lang(de) %{_qt5_translationdir}/qtwebengine_locales/de.pak
  477. %lang(el) %{_qt5_translationdir}/qtwebengine_locales/el.pak
  478. %lang(en) %{_qt5_translationdir}/qtwebengine_locales/en-GB.pak
  479. %lang(en) %{_qt5_translationdir}/qtwebengine_locales/en-US.pak
  480. %lang(es) %{_qt5_translationdir}/qtwebengine_locales/es-419.pak
  481. %lang(es) %{_qt5_translationdir}/qtwebengine_locales/es.pak
  482. %lang(et) %{_qt5_translationdir}/qtwebengine_locales/et.pak
  483. %lang(fa) %{_qt5_translationdir}/qtwebengine_locales/fa.pak
  484. %lang(fi) %{_qt5_translationdir}/qtwebengine_locales/fi.pak
  485. %lang(fil) %{_qt5_translationdir}/qtwebengine_locales/fil.pak
  486. %lang(fr) %{_qt5_translationdir}/qtwebengine_locales/fr.pak
  487. %lang(gu) %{_qt5_translationdir}/qtwebengine_locales/gu.pak
  488. %lang(he) %{_qt5_translationdir}/qtwebengine_locales/he.pak
  489. %lang(hi) %{_qt5_translationdir}/qtwebengine_locales/hi.pak
  490. %lang(hr) %{_qt5_translationdir}/qtwebengine_locales/hr.pak
  491. %lang(hu) %{_qt5_translationdir}/qtwebengine_locales/hu.pak
  492. %lang(id) %{_qt5_translationdir}/qtwebengine_locales/id.pak
  493. %lang(it) %{_qt5_translationdir}/qtwebengine_locales/it.pak
  494. %lang(ja) %{_qt5_translationdir}/qtwebengine_locales/ja.pak
  495. %lang(kn) %{_qt5_translationdir}/qtwebengine_locales/kn.pak
  496. %lang(ko) %{_qt5_translationdir}/qtwebengine_locales/ko.pak
  497. %lang(lt) %{_qt5_translationdir}/qtwebengine_locales/lt.pak
  498. %lang(lv) %{_qt5_translationdir}/qtwebengine_locales/lv.pak
  499. %lang(ml) %{_qt5_translationdir}/qtwebengine_locales/ml.pak
  500. %lang(mr) %{_qt5_translationdir}/qtwebengine_locales/mr.pak
  501. %lang(ms) %{_qt5_translationdir}/qtwebengine_locales/ms.pak
  502. %lang(nb) %{_qt5_translationdir}/qtwebengine_locales/nb.pak
  503. %lang(nl) %{_qt5_translationdir}/qtwebengine_locales/nl.pak
  504. %lang(pl) %{_qt5_translationdir}/qtwebengine_locales/pl.pak
  505. %lang(pt_BR) %{_qt5_translationdir}/qtwebengine_locales/pt-BR.pak
  506. %lang(pt_PT) %{_qt5_translationdir}/qtwebengine_locales/pt-PT.pak
  507. %lang(ro) %{_qt5_translationdir}/qtwebengine_locales/ro.pak
  508. %lang(ru) %{_qt5_translationdir}/qtwebengine_locales/ru.pak
  509. %lang(sk) %{_qt5_translationdir}/qtwebengine_locales/sk.pak
  510. %lang(sl) %{_qt5_translationdir}/qtwebengine_locales/sl.pak
  511. %lang(sr) %{_qt5_translationdir}/qtwebengine_locales/sr.pak
  512. %lang(sv) %{_qt5_translationdir}/qtwebengine_locales/sv.pak
  513. %lang(sw) %{_qt5_translationdir}/qtwebengine_locales/sw.pak
  514. %lang(ta) %{_qt5_translationdir}/qtwebengine_locales/ta.pak
  515. %lang(te) %{_qt5_translationdir}/qtwebengine_locales/te.pak
  516. %lang(th) %{_qt5_translationdir}/qtwebengine_locales/th.pak
  517. %lang(tr) %{_qt5_translationdir}/qtwebengine_locales/tr.pak
  518. %lang(uk) %{_qt5_translationdir}/qtwebengine_locales/uk.pak
  519. %lang(vi) %{_qt5_translationdir}/qtwebengine_locales/vi.pak
  520. %lang(zh_CN) %{_qt5_translationdir}/qtwebengine_locales/zh-CN.pak
  521. %lang(zh_TW) %{_qt5_translationdir}/qtwebengine_locales/zh-TW.pak
  522. %files devel
  523. %{rpm_macros_dir}/macros.qt5-qtwebengine
  524. %{_qt5_headerdir}/Qt*/
  525. %{_qt5_libdir}/libQt5*.so
  526. %{_qt5_libdir}/libQt5*.prl
  527. #{_qt5_libdir}/Qt5WebEngineCore.la
  528. %{_qt5_libdir}/cmake/Qt5*/
  529. %{_qt5_libdir}/pkgconfig/Qt5*.pc
  530. %{_qt5_archdatadir}/mkspecs/modules/*.pri
  531. %files devtools
  532. %{_qt5_datadir}/resources/qtwebengine_devtools_resources.pak
  533. %files examples
  534. %{_qt5_examplesdir}/
  535. %if 0%{?docs}
  536. %files doc
  537. %{_qt5_docdir}/*
  538. %endif
  539. %changelog
  540. * Wed Apr 14 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 5.15.2-1
  541. - new upstream release.
  542. - imported Patch26-29 from rawhide.
  543. - imported Patch1000 from upstream to build with icu-69.
  544. * Fri Apr 24 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 5.12.8-2
  545. - rebuilt with icu-67.
  546. * Wed Apr 15 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 5.12.8-1
  547. - new upstream release.
  548. - built with libevent-2.1.11.
  549. * Mon Mar 23 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 5.12.7-1
  550. - new upstream release.
  551. - dropped Patch1000: fixed in upstream.
  552. * Sun Oct 20 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 5.12.5-1
  553. - new upstream release.
  554. * Fri Nov 16 2018 Toshiaki Ara <ara_t@384.jp> - 5.6.3-2
  555. - rebuild with libevent-2.1.8
  556. * Tue Jan 09 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 5.6.3-1
  557. - new upstream release.
  558. * Mon Jul 11 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 5.6.1.1-1
  559. - new upstream release.
  560. - initial build for Vine Linux.
  561. - updated Source1.
  562. * Tue Jun 14 2016 Rex Dieter <rdieter@fedoraproject.org> - 5.6.1-3
  563. - rebuild (glibc)
  564. * Sun Jun 12 2016 Rex Dieter <rdieter@fedoraproject.org> - 5.6.1-2
  565. - add versioned qt5-qtbase runtime dep
  566. * Sat Jun 11 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.1-1
  567. - Update to 5.6.1
  568. - Rebase linux-pri patch (drop the parts already fixed upstream)
  569. - Drop backported chimera-nss-init patch, already applied upstream
  570. - Rebase no-sse2 patch (the core_module.pro change)
  571. - Add the new designer/libqwebengineview.so plugin to the file list
  572. * Mon Jun 06 2016 Rex Dieter <rdieter@fedoraproject.org> - 5.6.0-8
  573. - workaround stackmashing runtime errors in re2-related bundled headers (#1337585)
  574. * Sat May 21 2016 Rex Dieter <rdieter@fedoraproject.org> - 5.6.0-7
  575. - rebuild (pciutuils)
  576. * Wed May 18 2016 Rex Dieter <rdieter@fedoraproject.org> 5.6.0-6
  577. - BR: git-core
  578. * Fri Apr 15 2016 David Tardon <dtardon@redhat.com> - 5.6.0-5
  579. - rebuild for ICU 57.1
  580. * Fri Apr 08 2016 Than Ngo <than@redhat.com> - 5.6.0-4
  581. - drop ppc ppc64 ppc64le from ExclusiveArch, it's not supported yet
  582. * Thu Mar 24 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-3
  583. - Build with CONFIG+="webcore_debug v8base_debug force_debug_info"
  584. - Force -fno-delete-null-pointer-checks through CXXFLAGS, Qt flags not used here
  585. - Use -g1 instead of -g on non-x86_64 to avoid memory exhaustion
  586. - Work around debugedit failure by removing "./" from #line commands and
  587. changing "//" to "/" in an #include command
  588. * Fri Mar 18 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-2
  589. - Avoid checking for the nonexistent icudtl.dat and silence the warnings
  590. * Thu Mar 17 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-1
  591. - Update to 5.6.0 (final)
  592. - Drop system-icu54 patch, fixed upstream
  593. * Thu Feb 25 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.19.rc
  594. - Update to 5.6.0 RC
  595. - Rebase linux-pri and no-sse2 patches
  596. - Remove BuildRequires pkgconfig(flac), pkgconfig(speex), no longer needed
  597. - Update file list for 5.6.0 RC (resources now in resources/ subdirectory)
  598. - Tag translations with correct %%lang tags
  599. * Wed Feb 24 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.18.beta
  600. - no-sse2 patch: Fix FFT (RealFourier) in webrtc on non-SSE2 x86
  601. * Tue Feb 23 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.17.beta
  602. - Fix FTBFS on aarch64: Respin tarball with fixed clean_ffmpeg.sh (#1310753).
  603. * Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 5.6.0-0.16.beta
  604. - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
  605. * Tue Jan 19 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.15.beta
  606. - Build V8 as a shared library on i686 to allow for swappable backends
  607. - Build both the x87 version and the SSE2 version of V8 on i686
  608. - Add the private library directory to the file list on i686
  609. - Add Provides/Requires filtering for libv8.so (i686) and for plugins
  610. * Sun Jan 17 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.14.beta
  611. - Do not require SSE2 on i686
  612. * Thu Jan 14 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.13.beta
  613. - Drop nss321 backport (and the related nss-headers patch), it did not help
  614. - Do an NSS/BoringSSL "chimera build" as will be the default in Chromium 47
  615. - Update License accordingly (add "OpenSSL")
  616. - Fix the "chimera build" to call EnsureNSSHttpIOInit (backport from Chromium)
  617. * Wed Jan 13 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.12.beta
  618. - Update forked NSS SSL code to 3.21, match system NSS (backport from Chromium)
  619. * Wed Jan 13 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.11.beta
  620. - Add an (optimistic) ExclusiveArch list because of V8 (tracking bug: #1298011)
  621. * Tue Jan 12 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.10.beta
  622. - Unbundle prtime.cc, use the system NSPR instead (which is already required)
  623. - Unbundle icu_utf.cc, use the system ICU instead (which is already required)
  624. * Mon Jan 11 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.9.beta
  625. - linux-pri.patch: Set icu_use_data_file_flag=0 for system ICU
  626. * Mon Jan 11 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.8.beta
  627. - Build against the system libvpx also on F23 (1.4.0), worked in Copr
  628. * Mon Jan 11 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.7.beta
  629. - Use the system libvpx on F24+ (1.5.0)
  630. - Fixes to Provides: bundled(*): libwebp if bundled, x86inc only on x86
  631. * Sun Jan 10 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.6.beta
  632. - Fix extractCFlag to also look in QMAKE_CFLAGS_RELEASE (needed for ARM)
  633. - Fix FTBFS on ARM: Disable NEON due to #1282495 (GCC bug)
  634. * Sat Jan 09 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.5.beta
  635. - Fix FTBFS on ARM: linux-pri patch: Set use_system_yasm only on x86_64 and i386
  636. - Fix FTBFS on ARM: Respin tarball with: clean_ffmpeg.sh: Add missing ARM files
  637. * Sat Jan 09 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.4.beta.1
  638. - Use more specific BuildRequires for docs (thanks to rdieter)
  639. - Fix FTBFS against ICU 54 (F22/F23), thanks to spot for the Chromium fix
  640. * Fri Jan 08 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.4.beta
  641. - Fix License tag
  642. - Use %%_qt5_examplesdir macro
  643. - Add Provides: bundled(*) for all the bundled libraries that I found
  644. * Wed Jan 06 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.3.beta
  645. - linux-pri patch: Add use_system_protobuf, went missing in the 5.6 rebase
  646. * Wed Jan 06 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.2.beta
  647. - linux-pri patch: Add missing newline at the end of the log line
  648. - Use export for NINJA_PATH (fixes system ninja-build use)
  649. * Wed Jan 06 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.6.0-0.1.beta
  650. - Readd BR pkgconfig(jsoncpp) because linux.pri now checks for it
  651. - BR yasm only on x86 (i686, x86_64)
  652. - Add dot at the end of %%description
  653. - Rebase no-format patch
  654. - Replace unbundle-gyp.patch with new linux-pri.patch
  655. - Use system ninja-build instead of the bundled one
  656. - Run the unbundling script replace_gyp_files.py in linux.pri rather than here
  657. - Update file list for 5.6.0-beta (no more libffmpegsumo since Chromium 45)
  658. * Tue Jan 05 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.5.1-4
  659. - Remove unused BRs flex, libgcrypt-devel, bzip2-devel, pkgconfig(gio-2.0),
  660. pkgconfig(hunspell), pkgconfig(libpcre), pkgconfig(libssl),
  661. pkgconfig(libcrypto), pkgconfig(jsoncpp), pkgconfig(libmtp),
  662. pkgconfig(libexif), pkgconfig(liblzma), pkgconfig(cairo), pkgconfig(libusb),
  663. perl(version), perl(Digest::MD5), perl(Text::ParseWords), ruby
  664. - Add missing explicit BRs on pkgconfig(x11), pkgconfig(xext),
  665. pkgconfig(xfixes), pkgconfig(xdamage), pkgconfig(egl)
  666. - Fix BR pkgconfig(flac++) to pkgconfig(flac) (libFLAC++ not used, only libFLAC)
  667. - Fix BR python-devel to python
  668. - Remove unused -Duse_system_openssl=1 flag (QtWebEngine uses NSS instead)
  669. - Remove unused -Duse_system_jsoncpp=1 and -Duse_system_libusb=1 flags
  670. * Mon Jan 04 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.5.1-3
  671. - Update file list for 5.5.1 (add qtwebengine_resources_[12]00p.pak)
  672. * Mon Jan 04 2016 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.5.1-2
  673. - Add missing explicit BRs on pkgconfig(expat) and pkgconfig(libxml-2.0)
  674. - Remove unused BR v8-devel (cannot currently be unbundled)
  675. * Thu Dec 24 2015 Kevin Kofler <Kevin@tigcc.ticalc.org> - 5.5.1-1
  676. - Update to 5.5.1
  677. - Remove patent-encumbered codecs in the bundled FFmpeg from the tarball
  678. * Fri Jul 17 2015 Helio Chissini de Castro <helio@kde.org> - 5.5.0-2
  679. - Update with unbundle flags. Adapted from original 5.4 Suse package
  680. - Disable vpx and sqlite as unbundle due some compilation issues
  681. - Enable verbose build
  682. * Fri Jul 17 2015 Helio Chissini de Castro <helio@kde.org> - 5.5.0-1
  683. - Initial spec
  684. * Thu Jun 25 2015 Helio Chissini de Castro <helio@kde.org> - 5.5.0-0.2.rc
  685. - Update for official RC1 released packages