Ich entwickle einen Plug-in-Bundle, sagt MyPlugIn.bundle
für eine Anwendung, sagt BigApp.app
. Dieses Bündel benötigt eine Dylib, sagen MyPlugIn.bundle/Contents/Resources/library.dylib
. Ich habe verlegt Pfade für library.dylib, wie ich für ein einfaches Anwendungspaket getan hätte:dylib @executable_path Pfad Ausgabe in einem Plug-in-Bundle
$ otool -L MyPlugIn.bundle/Contents/MacOS/MyPlugIn
MyPlugIn.bundle/Contents/MacOS/MyPlugIn:
@executable_path/../Resources/library.dylib (compatibility version 0.0.0, current version 0.0.0)
[...]
$ otool -L MyPlugIn.bundle/Contents/Resources/library.dylib
MyPlugIn.bundle/Contents/Resources/library.dylib:
@executable_path/../Resources/library.dylib (compatibility version 0.0.0, current version 0.0.0)
[...]
Aber BigApp.app versagt dieses Bundle zu laden, und Mac OS X Console.app protokolliert, was folgt:
19/01/10 15:42:59 BigApp[51516] Error loading /Library/Application Support/BigApp/Plug-Ins/MyPlugIn.bundle/Contents/MacOS/MyPlugIn: dlopen(/Library/Application Support/BigApp/Plug-Ins/MyPlugIn.bundle/Contents/MacOS/MyPlugIn, 262): Library not loaded: @executable_path/../Resources/library.dylib
Referenced from: /Library/Application Support/BigApp/Plug-Ins/MyPlugIn.bundle/Contents/MacOS/MyPlugIn
Reason: image not found
Es scheint, dass @executable_path nicht durch den MyPlugIn.bundle ausführbaren Pfad ersetzt wird, sondern durch den BigApp.app ausführbaren Pfad.
Jede Abhilfe zu, dass ohne absoluten Pfad und so, dass es auf Mac OS X 10.4 (Tiger) funktionieren wird? Vielen Dank.
Sagen wir, ich Plug In Zusammengestellt haben und ich möchte in es einige dynamische Bibliotheken kopieren es hängt davon ab. Wie kann ich dafür sorgen, dass nach ihnen gesucht wird? Danke. – Royi
können Sie einige Links reparieren? Sie sind kaputt –