On Thursday 10 May 2012 23:21:55 Stephen Kelly wrote: > David Faure wrote: > >> Now we don't do that anymore. > >> So for Windows the dlls and the exes have to go into the same directory. > > > > And how will the libs be found on Unix, given that they are under lib/ and > > not bin/? > > > > Putting all executables in bin doesn't remove the need for wrapper > > scripts, on unix. > > We have RPATH for that. Is that enough?
Doesn't seem to work currently. Apply attached patch in kcoreaddons, make, then try to run ./krandomsequencetest: ./krandomsequencetest: symbol lookup error: ./krandomsequencetest: undefined symbol: _ZN7KBackup10helloSteveEv Hmm, let's investigate: ldd ./krandomsequencetest | grep kcoreadd libkcoreaddons.so.5 => /d/kde/inst/kde_frameworks/lib64/libkcoreaddons.so.5 (0x00007ff56b385000) objdump -p krandomsequencetest | grep PATH RPATH /d/qt/4/qt-for-trunk/lib:/d/kde/build/5/kdelibs-frameworks/tier1/kcoreaddons/src:/d/kde/build/5/kdelibs-frameworks/libinqt5/src:/d/kde/build/5/kdelibs-frameworks/libkdeqt5staging/src RUNPATH /d/qt/4/qt-for-trunk/lib:/d/kde/build/5/kdelibs-frameworks/tier1/kcoreaddons/src:/d/kde/build/5/kdelibs-frameworks/libinqt5/src:/d/kde/build/5/kdelibs-frameworks/libkdeqt5staging/src Hmm, so this comes from $LD_LIBRARY_PATH pointing to $KDEDIR/lib64. Emptying it works: LD_LIBRARY_PATH= ldd ./krandomsequencetest | grep kcoreadd libkcoreaddons.so.5 => /d/kde/build/5/kdelibs-frameworks/tier1/kcoreaddons/src/libkcoreaddons.so.5 (0x00007f506c524000) But wasn't RPATH supposed to take precedence over $LD_LIBRARY_PATH? -- David Faure, fa...@kde.org, http://www.davidfaure.fr Sponsored by Nokia to work on KDE, incl. KDE Frameworks 5
diff --git a/tier1/kcoreaddons/src/io/kbackup.cpp b/tier1/kcoreaddons/src/io/kbackup.cpp index f0ea720..c2fba7a 100644 --- a/tier1/kcoreaddons/src/io/kbackup.cpp +++ b/tier1/kcoreaddons/src/io/kbackup.cpp @@ -198,5 +198,8 @@ bool numberedBackupFile( const QString& qFilename, return QFile::copy(qFilename, sTemplate.arg(1)); } - +void helloSteve() +{ +} + } diff --git a/tier1/kcoreaddons/src/io/kbackup.h b/tier1/kcoreaddons/src/io/kbackup.h index b8fe23d..700a9f7 100644 --- a/tier1/kcoreaddons/src/io/kbackup.h +++ b/tier1/kcoreaddons/src/io/kbackup.h @@ -118,6 +118,8 @@ namespace KBackup const QString& backupDir = QString(), const QString& backupMessage = QString() ); + + KCOREADDONS_EXPORT void helloSteve(); } #endif diff --git a/tier1/kcoreaddons/tests/krandomsequencetest.cpp b/tier1/kcoreaddons/tests/krandomsequencetest.cpp index 4873748..0966e2d 100644 --- a/tier1/kcoreaddons/tests/krandomsequencetest.cpp +++ b/tier1/kcoreaddons/tests/krandomsequencetest.cpp @@ -21,6 +21,7 @@ #include "krandomsequence.h" #include "krandom.h" +#include "kbackup.h" #include <stdio.h> @@ -30,6 +31,8 @@ main( /*int argc, char *argv[]*/ ) long seed; KRandomSequence seq; + KBackup::helloSteve(); + seed = 2; seq.setSeed(seed);printf("Seed = %4ld :", seed); for(int i = 0; i < 20; i++)
_______________________________________________ Kde-frameworks-devel mailing list Kde-frameworks-devel@kde.org https://mail.kde.org/mailman/listinfo/kde-frameworks-devel