Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post links to your 64bit module repos here. Repo maintainers are responsible for resolving any issues caused by their xzm's.
jssouza
Samurai
Samurai
Posts: 179
Joined: 09 Jul 2015, 14:17
Distribution: Porteus x86 arm
Location: Liechtenstein

Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#1 by jssouza » 03 Jul 2017, 18:52

Built from the official sources at http://download.qt.io/official_releases ... ubmodules/ and based on the slackware qt5 filesystem layout.

qt5-5.9.1-x86_64-1jss.xzm
Contans packages needed by qt, qtbase, qtx11extras, qtsvg and qtserialport- for developing minimal Qt widgets based application
http://www.mediafire.com/file/g6vgq4ug0 ... 4-1jss.xzm

qtquick-5.9.1-x86_64-1jss.xzm
Contans qtdeclarative, qtquickcontrols, qtquickcontrols2 and qtgraphicaleffects - for developing QML/Qt Quick applications
http://www.mediafire.com/file/5kyk88d1t ... 4-1jss.xzm

qttools-5.9.1-x86_64-1jss.xzm
http://www.mediafire.com/file/oe807n450 ... 4-1jss.xzm

qtscript-5.9.1-x86_64-1jss.xzm
http://www.mediafire.com/file/psjfep99i ... 4-1jss.xzm

qttranslations-5.9.1-x86_64-1jss.xzm
http://www.mediafire.com/file/n1q3a6g2t ... 4-1jss.xzm

Also, as an extra, built from the above modules is the Qt IDE
qtcreator-4.3.1-x86_64-1jss.xzm
http://www.mediafire.com/file/hsma5b0ip ... 4-1jss.xzm

Let me know if any more modules from the framework are needed, and I will create and upload them as needed.
Last edited by jssouza on 04 Jul 2017, 06:03, edited 1 time in total.

User avatar
francois
Contributor
Contributor
Posts: 4946
Joined: 28 Dec 2010, 14:25
Distribution: kde xfce porteus manjaro kubun
Location: Enfin l'été, le changement climatique attendu: le soleil.

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.2

Post#2 by francois » 04 Jul 2017, 03:49

Your contribution is quite appreciated.

Thanks a lot. :)
Voltaire: Le mieux est l'ennemi du bien.

fulalas
Contributor
Contributor
Posts: 587
Joined: 26 Oct 2016, 15:34
Distribution: Porteus
Location: Brazil

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.2

Post#3 by fulalas » 04 Jul 2017, 05:22

@jssouza, thanks for your contribution! I've just built a new LXQt module using your Qt 5.9.1 files and it's working flawlessly :)

Just a correction: you wrote QtCretator 4.3.2 in the title of this topic, but I think it was a typo since the actual version is 4.3.1, right?

jssouza
Samurai
Samurai
Posts: 179
Joined: 09 Jul 2015, 14:17
Distribution: Porteus x86 arm
Location: Liechtenstein

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#4 by jssouza » 04 Jul 2017, 06:05

Oops! Yes it was a typo, thanks for pointing it out. I corrected it now.

fulalas
Contributor
Contributor
Posts: 587
Joined: 26 Oct 2016, 15:34
Distribution: Porteus
Location: Brazil

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#5 by fulalas » 10 Jul 2017, 10:46

@jssouza, did you notice that there's a message regarding XDG_RUNTIME_DIR not being set (to see it press ctrl + alt + f1)? I think that maybe we need to set this variable before compiling Qt.

jssouza
Samurai
Samurai
Posts: 179
Joined: 09 Jul 2015, 14:17
Distribution: Porteus x86 arm
Location: Liechtenstein

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#6 by jssouza » 10 Jul 2017, 14:26

Hi fulalas,

Thanks. It seems like a qt 5.9 requirement. With qt 5.8 the warning is not shown, even though XDG_RUNTIME_DIR is not set. The only module where porteus sets it seems to be 003-kde5.xzm

Alienbob mentions in one of the comments in the post http://alien.slackbook.org/blog/kde-5_1 ... e-current/ (Search for XDG_RUNTIME_DIR) to set it to /run/user/$USER. Our kde5 sets it to /tmp/xdg-runtime-$USER. So I have also set it to /tmp/xdg-runtime-$USER. Updated link to qt5-5.9.1-x86_64-1jss.xzm in first post.

Do you want to set XDG_RUNTIME_DIR in 003-lxqt just like what kde5 does? If yes, I will revert to the old qt5-5.9.1 module. Although, IMHO it should be set earlier in either 001 or 002.

fulalas
Contributor
Contributor
Posts: 587
Joined: 26 Oct 2016, 15:34
Distribution: Porteus
Location: Brazil

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#7 by fulalas » 10 Jul 2017, 22:55

@jssouza, thanks for the new build! It's working nice, with no messages regarding XDG_RUNTIME_DIR. :good:

I don't know where's the best place to set this variable, but maybe in your Qt build is good enough. Can this variable be used by something else besides Qt?

jssouza
Samurai
Samurai
Posts: 179
Joined: 09 Jul 2015, 14:17
Distribution: Porteus x86 arm
Location: Liechtenstein

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#8 by jssouza » 11 Jul 2017, 04:26

fulalas wrote:Can this variable be used by something else besides Qt?
Yes, any application that complies with the XDG specification, like Qt 5.9 now does.

This is what the XDG specification says about the $XDG_RUNTIME_DIR directory:
It MUST be created when the user first logs in and if the user fully logs out the directory MUST be removed.
This would mean that the variable must be set by the module that logs in the user.
lxqt will still not have a problem, since it includes this qt module already when it logs in the user and hence the variable would be set. However, if the Qt module is activated by a user from some other DE, then the warning would still occur, since the variable was not set upon login.
See who sets it in other Linux distros (like Arch).

I will keep it in the Qt module for the time being.

fulalas
Contributor
Contributor
Posts: 587
Joined: 26 Oct 2016, 15:34
Distribution: Porteus
Location: Brazil

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#9 by fulalas » 11 Jul 2017, 06:50

@jssouza, I see. Maybe brokenman can help us by setting this variable inside 001-core module. Thanks for sharing such useful information :good:

fulalas
Contributor
Contributor
Posts: 587
Joined: 26 Oct 2016, 15:34
Distribution: Porteus
Location: Brazil

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#10 by fulalas » 11 Jul 2017, 07:15

@jssouza, since you're the guy who knows this stuff, when I try to execute pcmanfm-qt with lxqt-sudo -s, I got this:

Code: Select all

QStandardPaths: wrong ownership on runtime directory /tmp/xdg-runtime-guest, 1000 instead of 0    
                                                                                                     
** (process:30844): WARNING **: The directory '~/Templates' doesn't exist, ignoring it 
Do you know why?

jssouza
Samurai
Samurai
Posts: 179
Joined: 09 Jul 2015, 14:17
Distribution: Porteus x86 arm
Location: Liechtenstein

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#11 by jssouza » 11 Jul 2017, 09:37

They are two separate warnings.
The first one again seems to be a lack of a login. I see that lxqt-sudo with -s calls su as the backend. So I executed the same in a terminal directly with su:

Code: Select all

guest@porteus:~$ su -c /usr/bin/pcmanfm-qt 
Password: 
QStandardPaths: wrong ownership on runtime directory /tmp/xdg-runtime-guest, 1000 instead of 0
guest@porteus:~$ getent passwd guest
guest:x:1000:100:,,,:/home/guest:/bin/bash
guest@porteus:~$ ls -ld /tmp/xdg-runtime-guest/
drwx------ 5 guest users 120 Jul 11 09:20 /tmp/xdg-runtime-guest//
You can see xdg-runtime-guest has correct ownership and uid 1000 and should not be root (0). However, if I run the command from a login shell:

Code: Select all

guest@porteus:~$ su -l -c /usr/bin/pcmanfm-qt 
Then there is no warning. You can also see /tmp/xdg-runtime-root created. Maybe lxqt-sudo, when it calls su as backend (with -s) must also make the su call within a login shell...

The second one is a warning that comes even when executing pcmanfm-qt directly from the terminal without su/sudo/lxqt-sudo. pcmanfm-qt sees the Templates directory is not present in user's home. You can bring back the templates directory by uncommenting it in /etc/xdg/user-dirs.defaults. (Put the modified file in rootcopy as a quick test).
The Templates was commented off as part of porteus 3.2rc5 release: http://forum.porteus.org/viewtopic.php? ... 187#p48578 Please check the changelog in that post. I dont know why it was commented. Maybe brokenman could let you know the reason.

jssouza
Samurai
Samurai
Posts: 179
Joined: 09 Jul 2015, 14:17
Distribution: Porteus x86 arm
Location: Liechtenstein

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#12 by jssouza » 11 Jul 2017, 12:57

@fulalas: Regarding the first warning:
QStandardPaths: wrong ownership on runtime directory /tmp/xdg-runtime-guest, 1000 instead of 0

I looked in the qt core code (src/corelib/io/qstandardpaths_unix.cpp) and it seems like they are comparing effective uid with the XDG_RUNTIME_DIR directory's actual owner id. This would mean when you su, then your effective userid would be root and hence the warning. I created a qt bugreport, let's see what they say.

Compile and run this code directly and with lxqt-sudo/su

Code: Select all

#include <QCoreApplication>
#include <QFile>
#include <QFileInfo>
#include <QFileSystemWatcher>
#include <QDir>
#include <QDebug>
#include <unistd.h>

int main(int argc, char *argv[])
{
    QCoreApplication a(argc, argv);

    const uint myUid = uint(geteuid());
    qDebug() << "myUid" << myUid;

    QFileInfo fileInfo;
    QString xdgRuntimeDir = QFile::decodeName(qgetenv("XDG_RUNTIME_DIR"));
    qDebug() << "xdgRuntimeDir" << xdgRuntimeDir;

    fileInfo.setFile(xdgRuntimeDir);

    qDebug() << "fileowner:" << fileInfo.ownerId();
    // "The directory MUST be owned by the user"
    if (fileInfo.ownerId() != myUid) {
          qWarning("QStandardPaths: wrong ownership on runtime directory %s, %d instead of %d", qPrintable(xdgRuntimeDir),
                   fileInfo.ownerId(), myUid);
    }
    return a.exec();
}

Code: Select all

$ ./test
myUid 1000
xdgRuntimeDir "/tmp/xdg-runtime-guest/"
fileowner: 1000

$ su -c ./test
myUid 0
xdgRuntimeDir "/tmp/xdg-runtime-guest/"
fileowner: 1000
QStandardPaths: wrong ownership on runtime directory /tmp/xdg-runtime-guest/, 1000 instead of 0
By the way this happens in qt 5.8 too, so not a qt 5.9 thing. Of course, XDG_RUNTIME_DIR should be set in both cases.

fulalas
Contributor
Contributor
Posts: 587
Joined: 26 Oct 2016, 15:34
Distribution: Porteus
Location: Brazil

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#13 by fulalas » 11 Jul 2017, 13:54

Really nice dig, man! Thank you very much! Let's wait for brokenman's response. And, if possible, let me know what Qt developers answered. :good:

jssouza
Samurai
Samurai
Posts: 179
Joined: 09 Jul 2015, 14:17
Distribution: Porteus x86 arm
Location: Liechtenstein

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#14 by jssouza » 12 Jul 2017, 06:13

They have not yet replied. The id is QTBUG-61899.

jssouza
Samurai
Samurai
Posts: 179
Joined: 09 Jul 2015, 14:17
Distribution: Porteus x86 arm
Location: Liechtenstein

Re: Qt 5.9.1 framework (modular) + Qt Creator 4.3.1

Post#15 by jssouza » 18 Jul 2017, 09:25

@fulalas, they acknowledged the bug today and gave it a P3 priority.
https://bugreports.qt.io/browse/QTBUG-61899

Post Reply