<div dir="ltr">Ok, with the attached patch I think it should include XDG_CONFIG_DIRS and XDG_DATA_DIRS for the GenericConfigLocation|ConfigLocation and GenericDataLocation respectively. However when I try to build qt 5.4 branch with this patch here I get a link error when it's trying to link moc.<div><br></div><div>







<p class=""><span class="">cd tools/rcc/ && ( test -e Makefile || /Users/jeremy/devel/kde/src/qt5build/qtbase/bin/qmake /Users/jeremy/devel/kde/src/qt5/qtbase/src/tools/rcc/<a href="http://rcc.pro">rcc.pro</a> -o Makefile ) && /Applications/Xcode.app/Contents/Developer/usr/bin/make -f Makefile </span></p>
<p class=""><span class="">cd tools/moc/ && ( test -e Makefile || /Users/jeremy/devel/kde/src/qt5build/qtbase/bin/qmake /Users/jeremy/devel/kde/src/qt5/qtbase/src/tools/moc/<a href="http://moc.pro">moc.pro</a> -o Makefile ) && /Applications/Xcode.app/Contents/Developer/usr/bin/make -f Makefile </span></p>
<p class=""><span class="">/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -headerpad_max_install_names -Wl,-dead_strip -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -stdlib=libc++ -mmacosx-version-min=10.7 -o ../../../bin/rcc .obj/rcc.o .obj/main.o   -L/opt/local/lib -L/Users/jeremy/devel/kde/src/qt5build/qtbase/lib -lQt5Bootstrap -framework CoreServices -framework Foundation -lz </span></p>
<p class=""><span class="">/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -headerpad_max_install_names -Wl,-dead_strip -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -stdlib=libc++ -mmacosx-version-min=10.7 -o ../../../bin/moc .obj/moc.o .obj/preprocessor.o .obj/generator.o .obj/parser.o .obj/token.o .obj/main.o   -L/opt/local/lib -L/Users/jeremy/devel/kde/src/qt5build/qtbase/lib -lQt5Bootstrap -framework CoreServices -framework Foundation -lz </span></p>
<p class=""><span class="">Undefined symbols for architecture x86_64:</span></p>
<p class=""><span class="">  "QLibraryInfo::location(QLibraryInfo::LibraryLocation)", referenced from:</span></p>
<p class=""><span class="">      QStandardPaths::standardLocations(QStandardPaths::StandardLocation) in libQt5Bootstrap.a(qstandardpaths_mac.o)</span></p>
<p class=""><span class="">      xdgDataDirs() in libQt5Bootstrap.a(qstandardpaths_mac.o)</span></p>
<p class=""><span class="">ld: symbol(s) not found for architecture x86_64</span></p>
<p class=""><span class="">clang: error: linker command failed with exit code 1 (use -v to see invocation)</span></p>
<p class=""><span class="">Undefined symbols for architecture x86_64:</span></p>
<p class=""><span class="">  "QLibraryInfo::location(QLibraryInfo::LibraryLocation)", referenced from:</span></p>
<p class=""><span class="">      QStandardPaths::standardLocations(QStandardPaths::StandardLocation) in libQt5Bootstrap.a(qstandardpaths_mac.o)</span></p>
<p class=""><span class="">      xdgDataDirs() in libQt5Bootstrap.a(qstandardpaths_mac.o)</span></p>
<p class=""><span class="">make[3]: *** [../../../bin/rcc] Error 1</span></p>
<p class=""><span class="">make[2]: *** [sub-rcc-make_first] Error 2</span></p>
<p class=""><span class="">make[2]: *** Waiting for unfinished jobs....</span></p>
<p class=""><span class="">ld: symbol(s) not found for architecture x86_64</span></p>
<p class=""><span class="">clang: error: linker command failed with exit code 1 (use -v to see invocation)</span></p>
<p class=""><span class="">make[3]: *** [../../../bin/moc] Error 1</span></p>
<p class=""><span class="">make[2]: *** [sub-moc-make_first] Error 2</span></p>
<p class=""><span class="">make[1]: *** [sub-src-make_first] Error 2</span></p>
<p class=""><span class="">make: *** [module-qtbase-make_first] Error 2</span></p><p class=""><span class=""><br></span></p><p class=""><span class="">Which confuses me because both QLibraryInfo and QStandardPaths are in QtCore module. Any ideas how to solve that?</span></p><p class=""><span class=""><br></span></p><p class=""><span class="">BR,</span></p><p class=""><span class="">Jeremy</span></p></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Jan 8, 2015 at 6:44 PM, Marko Käning <span dir="ltr"><<a href="mailto:mk-lists@email.de" target="_blank">mk-lists@email.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Jeremy,<br>
<span class=""><br>
On 09 Jan 2015, at 01:29 , David Faure <<a href="mailto:faure@kde.org">faure@kde.org</a>> wrote:<br>
<br>
> On Friday 09 January 2015 00:05:28 Marko Käning wrote:<br>
>>> PS: the last patch I saw didn't use XDG_CONFIG_DIRS, don't you want that<br>
>>> as  well?<br>
>><br>
>> We don’t need this for the CI system, which is why Jeremy did not include it<br>
>> in  the current QSP patch. But it is no problem to re-insert the code from<br>
>> my older QSP patch, if you think we should go for this right way.<br>
><br>
> I think it would be pretty inconsistent to support one and not the other - and<br>
> the CI doesn't test everything ;) some apps won't find their installed config<br>
> files (for the few that do pre-install something), without this in QSP.<br>
<br>
</span>will you include this code in your to-be-submitted patch:<br>
---<br>
    // <a href="http://standards.freedesktop.org/basedir-spec/latest/" target="_blank">http://standards.freedesktop.org/basedir-spec/latest/</a><br>
    const QString xdgConfigDirs = QFile::decodeName(qgetenv("XDG_CONFIG_DIRS"));<br>
<br>
    switch (type) {<br>
    case ConfigLocation:<br>
    case GenericConfigLocation:<br>
        if (!xdgConfigDirs.isEmpty())<br>
            dirs = xdgConfigDirs.split(QLatin1Char(':'));<br>
        break;<br>
---<br>
for QStandardPaths::standardLocations(StandardLocation type)!<br>
<br>
Sorry, there it is again, my switch statement. :)<br>
<br>
Thanks,<br>
Marko</blockquote></div><br></div>