<table><tr><td style="">rjvbb created this revision.<br />rjvbb added a reviewer: Okular.<br />Restricted Application added a project: Okular.<br />Restricted Application added a subscriber: okular-devel.<br />rjvbb requested review of this revision.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D13771">View Revision</a></tr></table><br /><div><strong>REVISION SUMMARY</strong><div><p>On Mac, shared libraries typically need to have their install location as part of their "install_name" (or "id"). The link editor uses this information to hardcode the location where shared library dependencies are expected, and the dynamic loader will this fail if this information is not correct.</p>
<p>Okular recently (?) made the okularplugin library dependent on the okularpart (fortunately built as a shared library). This dependency is installed in the KDE plugin directory but the install_name is set to the default location for shared libraries (<tt style="background: #ebebeb; font-size: 13px;">$prefix/lib/okularpart.dylib</tt>). As a result, the okularplugin fails to load.</p>
<p>This patch sets the required additional target property on both the okularpart and okularplugin shared libraries so they reflect the actual install location.</p></div></div><br /><div><strong>TEST PLAN</strong><div><p>Without, loading libokularplugin.dylib fails:</p>
<div class="remarkup-code-block" style="margin: 12px 0;" data-code-lang="text" data-sigil="remarkup-code-block"><pre class="remarkup-code" style="font: 11px/15px "Menlo", "Consolas", "Monaco", monospace; padding: 12px; margin: 0; background: rgba(71, 87, 120, 0.08);">can't open /opt/local/share/qt5/qml/org/kde/okular/libokularplugin.dylib (dlopen(/opt/local/share/qt5/qml/org/kde/okular/libokularplugin.dylib, 6): Library not loaded: /opt/local/lib/okularpart.dylib
Referenced from: /opt/local/share/qt5/qml/org/kde/okular/libokularplugin.dylib
Reason: image not found)
Exit 1</pre></div>
<p>The patch solves this.</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R223 Okular</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D13771">https://phabricator.kde.org/D13771</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>CMakeLists.txt<br />
mobile/components/CMakeLists.txt</div></div></div><br /><div><strong>To: </strong>rjvbb, Okular<br /><strong>Cc: </strong>okular-devel, kde-mac, ngraham, aacid<br /></div>