Qt 5 Fedora 21 packages
rdieter at math.unl.edu
Thu Oct 16 12:24:53 UTC 2014
There are several strategies:
* The <bin>-qt5 convention is already used by most distributions, so many
applications/tools have adapted to it already. If you're aware of any that
haven't yet, I'd be happy to help produce upstreamable patches to implement
* qt5-qtbase-devel provides rpm macros (in /usr/lib/rpm/macros.d/macros.qt5)
that are useful during package creation, including:
As you noted, one way to ensure Qt5 gets used is to prepend %_qt5_bindir to
$PATH. This is essentially what kf5's %_cmake_kf5 (and similarly
%_cmake_kde4) macros do.
* As far as 'moc', that's not *usually* a tool an end-user typically runs,
so we've never seen a need to provide easy access (via pkg-config, or rpm
macro). If you have a justifiable use-case, we can certainly add it.
* there's a developer tool 'qtchooser' that allows users to switch between
default Qt developer environments. For the Qt5 qmake case,
$ qtchooser -qt=qt5 -run-tool=qmake
qtchooser is a little controversial (not universally endorsed by the kde-
sig), so currently it is not recommended to rely on it in any fedora package
Michael Schwendt wrote:
> Some confusion here trying to use Fedora's Qt 5 packages, and it seems
> they cannot be use quickly.
> $ rpm -qa qt5\*|sort
> No "moc" in PATH, no "uic" either. Just moc-qt5 and uic-qt5.
> $ pkg-config --variable=moc Qt5
> $ pkg-config --variable=uic Qt5
> $ rpm -qf /usr/lib64/qt5/bin/moc
> No documentation in that package:
> $ rpm -qd qt5-qtbase-devel
> It seems to be specific to Fedora. Looking up the qt5-qtbase spec file,
> even the Qt5.pc file is generated there. The "moc" variable is added there
> to help finding MOC, but why not also UIC? All binaries get renamed to
> avoid a conflict, but I couldn't find a helper script to make them
> available in path again. I think of a shell file in a fixed location one
> could source. And why isn't any of this documented in the package
> It looks like one could simply prepend
> to $PATH to make available the executables, which are renamed to avoid
> conflicts with other Qt versions.
> $ rpm -qi qt5-qtbase-devel|tail -2
> Description :
> Development files for qt5-qtbase.
More information about the devel