Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 531284 - dev-qt/qtwebengine:5 packaging
Summary: dev-qt/qtwebengine:5 packaging
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: Normal enhancement with 3 votes (vote)
Assignee: Qt Bug Alias
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 554380 579164
  Show dependency tree
 
Reported: 2014-12-01 02:20 UTC by Davide Pesavento
Modified: 2016-04-23 19:12 UTC (History)
10 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Ebuild for qtwebengine-5.6.9999 (qtwebengine-5.6.9999.ebuild,1.11 KB, text/plain)
2016-01-11 04:14 UTC, Chiitoo
Details
qtwebengine-5.6.0_beta.ebuild (qtwebengine-5.6.0_beta.ebuild,1.50 KB, text/plain)
2016-01-12 19:14 UTC, Michael Palimaka (kensington)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Davide Pesavento gentoo-dev 2014-12-01 02:20:57 UTC
QtWebEngine is a new module in Qt 5.4.0, intended to eventually replace QtWebKit.

Unfortunately, proper packaging looks like a major PITA
http://lists.qt-project.org/pipermail/development/2014-November/019366.html
Comment 1 Davide Pesavento gentoo-dev 2014-12-12 01:13:42 UTC
Note to self: http://lists.qt-project.org/pipermail/development/2014-December/019436.html (applies to 5.4.0 for now, might be fixed in later versions)
Comment 2 anonymous 2015-05-01 11:46:42 UTC
KDE from trunk don't compile without qtwebengine:5 https://bugs.gentoo.org/show_bug.cgi?id=548220
Comment 3 Davide Pesavento gentoo-dev 2015-08-11 23:17:42 UTC
Upstream listened.
http://lists.qt-project.org/pipermail/development/2015-August/022869.html
Comment 4 Chiitoo gentoo-dev 2016-01-11 04:14:24 UTC
Created attachment 422536 [details]
Ebuild for qtwebengine-5.6.9999


Not sure of its worth, but here's an ebuild I've been using for a while now.  It's modified from the ebuild found in the 'fkmclane' overlay (https://github.com/fkmclane/overlay) as well as 'alexxy' more recently now (https://gitweb.gentoo.org/dev/alexxy.git/commit/?id=846307931dbcac734a4512ebde47de5127b8978b).

I've removed the patches as I'm not sure of their need, nor if they would apply to this version.  More importantly, and perhaps interestingly, I added the proprietary-codecs, system-ffmpeg, and system-icu flags to make them optional.

I'm not sure at this time if all the dependencies are included.  I made a terrible job at keeping track of them...

What else would need to be done?

Thanks!
Comment 5 Michael Palimaka (kensington) gentoo-dev 2016-01-12 19:14:58 UTC
Created attachment 422734 [details]
qtwebengine-5.6.0_beta.ebuild

Completely untested ebuild based upon quick source inspection.
Comment 6 Michael Palimaka (kensington) gentoo-dev 2016-01-13 15:56:36 UTC
This is in the overlay now. Still needs a lot of work though.
Comment 7 Davide Pesavento gentoo-dev 2016-01-13 16:03:13 UTC
Thanks Michael. Did you take a look at other qtwebengine ebuilds that are floating around, to potentially merge interesting ideas that they implemented?
Comment 8 Michael Palimaka (kensington) gentoo-dev 2016-01-13 16:10:54 UTC
I checked the three versions found on gpo.zugaina.org, and the main differences seem to be extra USE flags (which no longer seem to be optional) and some patches for QTBUG-41960 which appears to be fixed.
Comment 9 Franz Trischberger 2016-01-22 06:45:43 UTC
Just wanted to test the beta, and it installs really fast ;)

===

>>> Source unpacked in /var/tmp/portage/dev-qt/qtwebengine-5.6.0_beta/work
>>> Preparing source in /var/tmp/portage/dev-qt/qtwebengine-5.6.0_beta/work/qtwebengine-opensource-src-5.6.0-beta ...
 * Applying qtwebengine-5.6.0-icu.patch ...                                                                      [ ok ]
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/dev-qt/qtwebengine-5.6.0_beta/work/qtwebengine-opensource-src-5.6.0-beta ...
 * Running qt5_qmake 
Info: creating cache file /var/tmp/portage/dev-qt/qtwebengine-5.6.0_beta/work/qtwebengine-opensource-src-5.6.0-beta/.qmake.cache
 
Using gcc version ., but at least gcc version 4.7 is required to build Qt WebEngine. 
Using gcc version ., but at least gcc version 4.7 is required to build Qt WebEngine.
QtWebEngine will not be built.
>>> Source configured.
>>> Compiling source in /var/tmp/portage/dev-qt/qtwebengine-5.6.0_beta/work/qtwebengine-opensource-src-5.6.0-beta ...
 * Running emake 
make -j11 
make: Nothing to be done for 'first'.
>>> Source compiled.
 * Skipping make test/check due to ebuild restriction.
>>> Test phase [disabled because of RESTRICT=test]: dev-qt/qtwebengine-5.6.0_beta

>>> Install qtwebengine-5.6.0_beta into /var/tmp/portage/dev-qt/qtwebengine-5.6.0_beta/image/ category dev-qt
 * Running emake INSTALL_ROOT=/var/tmp/portage/dev-qt/qtwebengine-5.6.0_beta/image/ install 
make -j11 INSTALL_ROOT=/var/tmp/portage/dev-qt/qtwebengine-5.6.0_beta/image/ install 
make: Nothing to be done for 'install'.
>>> Completed installing qtwebengine-5.6.0_beta into /var/tmp/portage/dev-qt/qtwebengine-5.6.0_beta/image/

===

I use clang for that (because gcc uses my whole RAM with large c++-projects, don't know why...). I inspected the top-level Makefile, and QMAKE_CXX says "clang++". I think there could be a hardcoded check for "gcc" that tries to match some COMPILER_VERSION generated from clang.
I use clang-3.7.0 and gcc-4.9.3 - so the gcc-check really should not return false.
And of course emerge should error out and not successfully finish installation ;)
Comment 10 Davide Pesavento gentoo-dev 2016-01-22 23:12:19 UTC
(In reply to Franz Fellner from comment #9)
> I use clang for that (because gcc uses my whole RAM with large c++-projects,
> don't know why...).

Try with a lower -j setting for MAKEOPTS...

> I think there could be a hardcoded check for "gcc" that tries to
> match some COMPILER_VERSION generated from clang.

Yep. I suspect your QT_GCC_* values in /usr/lib/qt5/mkspecs/qconfig.pri are empty. Did you build qtcore with clang?

> And of course emerge should error out and not successfully finish
> installation ;)

This has been (and in fact still is) a problem with qtwebkit as well, and it's due to the way the build system is structured... unfortunately there isn't really a clean solution, we will need to find a workaround.
Comment 11 Franz Trischberger 2016-01-23 07:34:06 UTC
(In reply to Davide Pesavento from comment #10)
> (In reply to Franz Fellner from comment #9)
> > I use clang for that (because gcc uses my whole RAM with large c++-projects,
> > don't know why...).
> 
> Try with a lower -j setting for MAKEOPTS...

It even happens for -j1 (and without -pipe in the CFLAGS). At some point during compilation one gcc process takes up way more than 3GB of RAM. I have 4GB (+4GB swap) where the kernel and the iGPU take their part. clang does not have such issues. AFAIR this started with gcc-4.8.

> > I think there could be a hardcoded check for "gcc" that tries to
> > match some COMPILER_VERSION generated from clang.
> 
> Yep. I suspect your QT_GCC_* values in /usr/lib/qt5/mkspecs/qconfig.pri are
> empty. Did you build qtcore with clang?

There are no QT_GCC-values in qconfig.pri. But qmodule.pri says:
QMAKE_LINK = clang++
QMAKE_CC = clang
QMAKE_CXX = clang++
I have configured package.env to use clang for the whole qt-suite. And qtcore of course was built with clang, just had a look again: emerge -1 --nodeps qtcore

>>> Verifying ebuild manifests

>>> Emerging (1 of 1) dev-qt/qtcore-5.6.0_beta::qt
[...]
Creating qmake...
clang++ -c [...]

And all the other modules (like qtx11extras, qtwebchannel, ...) just compiled fine.
Comment 12 Davide Pesavento gentoo-dev 2016-01-23 23:26:22 UTC
Can you try with this patch please? https://codereview.qt-project.org/144993
Comment 13 Franz Trischberger 2016-01-24 09:13:44 UTC
The patch didn't fix my issue.
Comment 14 Davide Pesavento gentoo-dev 2016-01-26 14:19:30 UTC
Try the latest version of that patch please (patch set 8)
Comment 15 Franz Trischberger 2016-01-27 12:47:11 UTC
(In reply to Davide Pesavento from comment #14)
> Try the latest version of that patch please (patch set 8)

Patch set 8 didn't fix it. Also No 9 didn't make it build.
Comment 16 Franz Trischberger 2016-01-27 13:05:55 UTC
It's building now, with a package.env file to export QMAKESPEC=linux-clang
So somehow qtwebengine has issues to properly detect I am building with clang (although CC and CXX are exported properly) or it doesn't set QMAKESPEC correctly. Or something else - I don't know much (anything?) about those internlals ;)
Comment 17 Davide Pesavento gentoo-dev 2016-01-27 17:04:22 UTC
(In reply to Franz Fellner from comment #16)
> It's building now, with a package.env file to export QMAKESPEC=linux-clang
> So somehow qtwebengine has issues to properly detect I am building with
> clang (although CC and CXX are exported properly) or it doesn't set
> QMAKESPEC correctly. Or something else - I don't know much (anything?) about
> those internlals ;)

Thanks, you anticipated my next question (about QMAKESPEC) ;-)

Please open a separate bug then, as the problem is not really specific to qtwebengine, but it's related to how we currently handle (or rather, don't handle) qmake's mkspec.
Comment 18 Davide Pesavento gentoo-dev 2016-04-23 19:12:45 UTC
qtwebengine-5.6.0 is in tree. Thanks everyone!