[KDE/Mac] Success at last (sort of)
Ian Wadham
iandw.au at gmail.com
Fri May 30 03:18:00 UTC 2014
On 30/05/2014, at 12:15 PM, Bradley Giesbrecht wrote:
> On May 29, 2014, at 7:10 PM, Bradley Giesbrecht <pixilla at macports.org> wrote:
>> On May 28, 2014, at 11:52 PM, Ian Wadham <iandw.au at gmail.com> wrote:
>>> Hi guys,
>>>
>>> You've all been a bit quiet the last few days. What's up?
>>>
>>> On 25/05/2014, at 4:25 PM, Ian Wadham wrote:
>>>
>>> Well I found out about dyld, RPATH and otool -L and the solution to the above problem
>>> and now I have a successful kdesrc-build with all of KDE games building and most of the
>>> games running OK in my private execution environment, with Debug versions of code.
>>> I can also run one or two core and base KDE apps, such as Konqueror.
>>>
>>> I have also incorporated almost all the CMake command-line options from the cmake
>>> and kde4 portgroups. They are a bit of an overkill in some cases, but at least they
>>> avoid all those ambiguities between libraries in /usr/lib and /opt/local/lib wherever
>>> they may occur in the course of building scores of modules.
>>>
>>> There are still two problems occurring in the built applications:
>>>
>>> 1. If an application uses some CMakeLists.txt code like:
>>> target_link_libraries(kbounce ${KDE4_KDEUI_LIBS} kdegames ${KDE4_PHONON_LIBS})
>>> the Phonon part is still given a relative path, rather than the absolute path that dyld
>>> requires, e.g. "otool -L /blah/blah/kbounce" shows,
>>> /Applications/KDE_MAC/kbounce.app/Contents/MacOS/kbounce:
>>> /kdedev/KDE-MAC/kde/lib/libkdeui.5.dylib (compatibility version 5.0.0, current version 5.13.1)
>>> /kdedev/KDE-MAC/kde/lib/libkdegames.6.dylib (compatibility version 6.0.0, current version 6.1.0)
>>> lib/libphonon.4.dylib (compatibility version 4.0.0, current version 4.7.50) …
>>> Notice that libkdeui and libkdegames come out correctly, but not libphonon.
>>
>> You probably are looking to fix the source of the problem
>> but in case you are not aware there is a tool (install_name_tool) that can fix
>> this problem after the fact given enough header padding.
>> man install_name_tool
>
>
> I can give you usage examples if that is helpful. I think this command would fix the phonon issue you mentioned:
> sudo install_name_tool -change lib/libphonon.4.dylib /opt/local/lib/libphonon.4.dylib /Applications/KDE_MAC/kbounce.app/Contents/MacOS/kbounce
Thanks, Bradley. I will keep that tool in mind.
However, at the very same time as you were writing, I found another solution. Avoid building
Phonon from source and instead link to the copy in /opt/local/lib, which has a full prefix and
then gets linked into apps and libraries with an absolute path.
I now have KMyMoney, KBounce and Dolphin running. Also KMM crashes when I use it with
raster graphics, so now I can start debugging that … :-)
Cheers, Ian W.
More information about the kde-mac
mailing list