Summary: | >=dev-qt/qt-creator-3.3: build against qt5 | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Alexander Mezin <mezin.alexander> |
Component: | [OLD] Development | Assignee: | Davide Pesavento <pesa> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | aambitny, b.brachaczek, franz.trischberger, headcrabextra, hwoarang, maggu2810, myoung008, qt, reagentoo, ua_gentoo_bugzilla, uwelk |
Priority: | Normal | Keywords: | PATCH |
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | 454132 | ||
Bug Blocks: | 476256, 528436 | ||
Attachments: |
Ebuild for qml2puppet
qt-creator-3.2.2.ebuild.patch qt-creator-3.2.2.ebuild.patch qt-creator-3.3.0_beta1.ebuild qtcore-5.3.2 with global_docs use flag qt-creator-3.3.0_beta1.ebuild qt-creator-3.3.0_beta1.ebuild qt-creator-3.3.0_beta1.ebuild |
Why does the ebuild say "qt creator" everywhere? Is this supposed to be an ebuild for dev-qt/qt-creator or a new package? (In reply to Jeroen Roovers from comment #1) > Why does the ebuild say "qt creator" everywhere? Is this supposed to be an > ebuild for dev-qt/qt-creator or a new package? It's part of qt creator So wouldn't a USE flag suffice to make it part of a dev-qt/qt-creator ebuild? (In reply to Jeroen Roovers from comment #3) > So wouldn't a USE flag suffice to make it part of a dev-qt/qt-creator ebuild? Maybe. I only found a solution that just works, and shared it. However, with an use-flag qt creator will have qt 5 in dependencies, so you'll have different ebuilds for overlay and for main tree. (In reply to Alexander Mezin from comment #4) > (In reply to Jeroen Roovers from comment #3) > > So wouldn't a USE flag suffice to make it part of a dev-qt/qt-creator ebuild? > > Maybe. I only found a solution that just works, and shared it. > However, with an use-flag qt creator will have qt 5 in dependencies, so > you'll have different ebuilds for overlay and for main tree. use.mask qt5 *** Bug 511148 has been marked as a duplicate of this bug. *** *** Bug 524016 has been marked as a duplicate of this bug. *** http://lists.qt-project.org/pipermail/qt-creator/2014-July/003803.html Qt Creator 3.3 (currently in development) requires to be built against qt >= 5.3.1 Qt4 support has been dropped completely. Created attachment 388714 [details, diff]
qt-creator-3.2.2.ebuild.patch
I created patch for QtCreator 3.2.2 to make it possible to compile it against Qt5 by adding 'qt5' use flag to it.
You still can use that patch for QtCreator 3.3 and newer, but then you would have to remove "!qt5" blocks and make "qt5" blocks unconditional.
Created attachment 388716 [details, diff]
qt-creator-3.2.2.ebuild.patch
Patch with minor fixes attached.
The only problem that remains is build error when 'doc' use flag is enabled.
It is because of this line in doc/qtcreator.qdocconf file:
include($QT_INSTALL_DOCS/global/qt-html-templates-offline.qdocconf)
In Ubuntu qt-html-templates-offline.qdocconf is included in qtbase5-dev package, so I suppose that we should have some new use flag in qtcore package that would result in these templates being copied.
(In reply to Paweł Stankowski from comment #9) > You still can use that patch for QtCreator 3.3 and newer, but then you would > have to remove "!qt5" blocks and make "qt5" blocks unconditional. I'm going to keep 3.2 qt4-only, and add qt5 support starting with 3.3 (beta1 is already out). Would you mind amending your patch to make qt5 deps unconditional? By the way, I believe the minimum required version is 5.3.1 or something like that... just put 5.3.2 since there's nothing else in portage. (In reply to Paweł Stankowski from comment #10) > The only problem that remains is build error when 'doc' use flag is enabled. > > It is because of this line in doc/qtcreator.qdocconf file: > include($QT_INSTALL_DOCS/global/qt-html-templates-offline.qdocconf) > > In Ubuntu qt-html-templates-offline.qdocconf is included in qtbase5-dev > package, so I suppose that we should have some new use flag in qtcore > package that would result in these templates being copied. Yeah, doc support is missing from Qt5 packages at the moment (see bug 457028). Is there any pre-built doc in qt-creator tarball (either in html or qch format)? (In reply to Davide Pesavento from comment #11) > (In reply to Paweł Stankowski from comment #9) > > You still can use that patch for QtCreator 3.3 and newer, but then you would > > have to remove "!qt5" blocks and make "qt5" blocks unconditional. > > I'm going to keep 3.2 qt4-only, and add qt5 support starting with 3.3 (beta1 > is already out). Would you mind amending your patch to make qt5 deps > unconditional? By the way, I believe the minimum required version is 5.3.1 > or something like that... just put 5.3.2 since there's nothing else in > portage. Yeah, no problem - I can leave 3.2 as it is. I am testing 3.3.0_beta1 ebuild at the moment. Indeed qt-creator 3.3 requires Qt 5.3.1 or newer, but qt-creator 3.2 could be used with any Qt5 version. > > (In reply to Paweł Stankowski from comment #10) > > The only problem that remains is build error when 'doc' use flag is enabled. > > > > It is because of this line in doc/qtcreator.qdocconf file: > > include($QT_INSTALL_DOCS/global/qt-html-templates-offline.qdocconf) > > > > In Ubuntu qt-html-templates-offline.qdocconf is included in qtbase5-dev > > package, so I suppose that we should have some new use flag in qtcore > > package that would result in these templates being copied. > > Yeah, doc support is missing from Qt5 packages at the moment (see bug > 457028). Is there any pre-built doc in qt-creator tarball (either in html or > qch format)? Ok, so I will try to use this little patch from the bug you mentioned: https://457028.bugs.gentoo.org/attachment.cgi?id=338736 That small patch creates 'doc' use flag that may be used to install documentation templates and few PNG files. It needs some corrections, but is so small that possibly could be merged without resolving whole bug, right? I will change 'doc' use flag name into 'global_docs', because I think current name is misleading. Created attachment 388806 [details]
qt-creator-3.3.0_beta1.ebuild
Ebuild for QtCreator 3.3 attached. I had to fix one bug that new plugin QmakeAndroidSupport requires Android plugin, so build failed when android use flag was disabled. Now both plugins are disabled using android use flag. We will have to check other plugins dependencies.
About 'doc' use flag:
Patching qtcore ebuild fixed problem with qtcreator documentation not being created. However I have to manually add QCH files in QtCreator Options, because it is not found automatically. I think that this is because QCH files are installed in /usr/share/doc/qtcreator-${PV} and default path is /usr/shared/doc/qtcreator. Maybe patching ICore::documentationPath() function would do the trick. Currently it looks like that:
QString ICore::documentationPath()
{
const QString docPath = QLatin1String(Utils::HostOsInfo::isMacHost()
? "/../Resources/doc" : "/../share/doc/qtcreator");
return QDir::cleanPath(QCoreApplication::applicationDirPath() + docPath);
}
Do you think it is worth trying?
Created attachment 388808 [details, diff]
qtcore-5.3.2 with global_docs use flag
Created attachment 388810 [details]
qt-creator-3.3.0_beta1.ebuild
Changed name of 'doc' use flag to 'global_docs'
(In reply to Paweł Stankowski from comment #12) > Ok, so I will try to use this little patch from the bug you mentioned: > https://457028.bugs.gentoo.org/attachment.cgi?id=338736 > > That small patch creates 'doc' use flag that may be used to install > documentation templates and few PNG files. It needs some corrections, but is > so small that possibly could be merged without resolving whole bug, right? > I will change 'doc' use flag name into 'global_docs', because I think > current name is misleading. How much stuff are we talking about here? If they're small enough, I'd prefer installing those files unconditionally rather than introducing yet another obscure USE flag. Also, please don't mix bugs... attach the updated doc patch to the original bug. And explain why '-make docs' is no longer needed. (In reply to Paweł Stankowski from comment #13) > About 'doc' use flag: [...] > Do you think it is worth trying? Probably not. Install the qch into /usr/share/doc/${PN} instead, where qtcreator expects it, and add a comment in the ebuild explaining why we're doing that. Created attachment 389332 [details, diff] qt-creator-3.3.0_beta1.ebuild > We will have to check other plugins dependencies. I've checked other plugins and found that very basic ones (as Welcome plugin) are using qtquickcontrols and qtxml, so I've added these packages to dependencies. > Install the qch into /usr/share/doc/${PN} instead, where > qtcreator expects it, and add a comment in the ebuild explaining why we're > doing that. Done. Documentation now works out of the box. When qtcreator was already run, removal of ~/.config/QtProject may be needed. Created attachment 390232 [details, diff]
qt-creator-3.3.0_beta1.ebuild
- fixed docs path
- doc use flag now has dependency on >=dev-qt/qtcore-5.3.2-r1 instead of dev-qt/qtcore[global_docs]
- added runtime dependency dev-qt/qttranslations when any LINGUAS use flag is enabled (w/o this dependency, translations file were installed but could not be used).
Thx for the ebuild! Just wanted to say that I used it without any modifications to install qt-creator-3.3.0_rc1. Works very well (compilation and tested features like C++ code completion (clang), qml editor, compilation, ...) I found another (minor) problem with this ebuild. Directory with syntax highlighthing definitions (Tools->Options->Text Editor->Generic Highlighter) by default points to subdirectory of my $HOME dir, but it should point to /usr/share/qtcreator/generic-highlighter. Have not found this bug earlier, because Kate's highlighting definitions were used as fallback and they were working well in most of cases. Any progress on merging that into portage? I spent a lot of time on that, so it would be great if users may make use of it. QtCreator 3.3 was officially released over a month ago. (In reply to Paweł Stankowski from comment #21) > Any progress on merging that into portage? I spent a lot of time on that, so > it would be great if users may make use of it. QtCreator 3.3 was officially > released over a month ago. Sorry, I forgot about this. Fixed in tree with 3.3.0, thanks a lot! *qt-creator-3.3.0 (18 Jan 2015) 18 Jan 2015; Davide Pesavento <pesa@gentoo.org> +qt-creator-3.3.0.ebuild, metadata.xml, qt-creator-2.8.1.ebuild, qt-creator-3.2.2.ebuild: Version bump (bug 528436). Build against Qt5 as now required by upstream, thanks to Paweł Stankowski in bug 479638 for the initial patch. Add support for qbs and winrt plugins (bug 476256). |
Created attachment 355026 [details] Ebuild for qml2puppet Qt creator is built with qt4, so designer doesn't work for qtquick 2. Building qml2puppet with qt5 solves the problem.