| Summary: | =dev-util/qbs-1.4.5 stabilization | ||
|---|---|---|---|
| Product: | Gentoo Linux | Reporter: | Davide Pesavento (RETIRED) <pesa> |
| Component: | [OLD] Keywording and Stabilization | Assignee: | Qt Bug Alias <qt> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | Keywords: | STABLEREQ |
| Priority: | Normal | ||
| Version: | unspecified | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Package list: | Runtime testing required: | --- | |
| Bug Depends on: | 569924, 585398 | ||
| Bug Blocks: | 581878 | ||
| Attachments: | build.log | ||
|
Description
Davide Pesavento (RETIRED)
2016-05-02 19:50:43 UTC
When built with FEATURES="test", I'm getting a libqbscore.so installed that links to libQt5Test.so.5. (In reply to Michael Palimaka (kensington) from comment #1) > When built with FEATURES="test", I'm getting a libqbscore.so installed that > links to libQt5Test.so.5. Cannot reproduce: /tmp/portage/dev-util/qbs-1.4.5/image $ scanelf -nqy usr/lib64/libqbs* libQt5Script.so.5,libQt5Gui.so.5,libQt5Xml.so.5,libQt5Core.so.5,libpthread.so.0,libstdc++.so.6,libgcc_s.so.1,libc.so.6 usr/lib64/libqbscore.so.1.4.5 libqbscore.so.1,libQt5Core.so.5,libstdc++.so.6,libgcc_s.so.1,libc.so.6 usr/lib64/libqbsqtprofilesetup.so.1.4.5 I suspect libQt5Test.so is somehow being leaked by one or more qt libraries. Try something like `grep Qt5Test /usr/lib/pkgconfig/Qt5*.pc` and/or `scanelf -nqy /usr/lib/libQt5*`. $ scanelf -nqy /usr/lib/libQt5* | grep -i test libQt5Test.so.5,libQt5Widgets.so.5,libQt5Gui.so.5,libQt5Core.so.5,libQt5Quick.so.5,libQt5Qml.so.5,libstdc++.so.6,libc.so.6 /usr/lib/libQt5QuickTest.so.5.6.1 libQt5Core.so.5,libpthread.so.0,libstdc++.so.6,libgcc_s.so.1,libc.so.6 /usr/lib/libQt5Test.so.5.6.1 $ grep Qt5Test /usr/lib/pkgconfig/Qt5*.pc /usr/lib/pkgconfig/Qt5QuickTest.pc:Libs.private: -lQt5Test -lQt5Widgets -lQt5Gui -lQt5Core -lpthread -lQt5Quick -lQt5Qml -lQt5Gui -lQt5Network -lQt5Core -lpthread -lGL /usr/lib/pkgconfig/Qt5QuickTest.pc:Requires: Qt5Core Qt5Test Qt5Widgets /usr/lib/pkgconfig/Qt5Test.pc:Libs: -lQt5Test $ scanelf -nqy /usr/lib64/libqbs* libQt5Script.so.5,libQt5Test.so.5,libQt5Gui.so.5,libQt5Xml.so.5,libQt5Core.so.5,libpthread.so.0,libstdc++.so.6,libgcc_s.so.1,libc.so.6 /usr/lib64/libqbscore.so.1.4.5 libqbscore.so.1,libQt5Core.so.5,libstdc++.so.6,libgcc_s.so.1,libc.so.6 /usr/lib64/libqbsqtprofilesetup.so.1.4.5 Thanks. Can you also attach a build.log of dev-util/qbs-1.4.5 please? Created attachment 437640 [details]
build.log
I'm really puzzled by this. I tried reproducing on an almost identical system (same compiler, same linker, same CXXFLAGS and LDFLAGS; the only differences are that I'm using a non-hardened profile, and that I have Qt 5.6.0 instead of 5.6.1), but I still can't reproduce. I compared our build logs line-by-line and they're practically identical, including the presence of -DQT_TESTLIB_LIB and -lQt5Test in both. Nevertheless, my libqbscore.so ends up *not* being linked to libQt5Test.so. So, unless --as-needed is behaving randomly, I'm inclined to think the difference is due to hardened vs non-hardened compiler.
In any case, there are a couple of files in src/lib/corelib/ that do include either <QtTest> or <QTest>. These files are included in the build only when qbs is configured with qbs_enable_unit_tests, which we do when USE=test is enabled.
So, although I don't understand why the dependency doesn't end up in DT_NEEDED on my system, I think it's clear that it's indeed required for USE=test because QtTest *is* used in library code. Therefore I've moved dev-qt/qttest from DEPEND to both {,R}DEPEND in commit 1ffe27368ea16216067b7a4f92c82e57d6baff10.
amd64/x86 stable |