Looks like I've found it. I've added sys.dylib using *jl_init_with_image() 
(*that symbol was in the sys.dylib). And it looks like I have to add all 
the libraries from the Julia.app to my project. Also some of them searching 
in specific paths that can be changed using install_name_tool. I guess it 
should solve the problem. But I'm still not sure if I do it right.

суббота, 12 декабря 2015 г., 15:50:57 UTC+3 пользователь Ales Tsurko 
написал:
>
> Thanks to this thread: 
> https://groups.google.com/forum/#!topic/julia-users/RFsP21thyBI I've 
> solved the problem regarding to sys.dylib.
> If someone in the future would looking for the solution of the problem, 
> use *jl_init_with_image*(*<JULIA_HOME>*,*<PATH_TO_JULIA_IMAGE>*) (
> https://groups.google.com/d/msg/julia-users/RFsP21thyBI/FenpD-tPAgAJ)
>
> But now I have the next problem:
>
> *ERROR: could not load symbol "jl_sysimg_cpu_target"*
>
> *dlsym(0x600000162580, jl_sysimg_cpu_target): symbol not found*
>
> Could someone explain or at least give me a direction how to solve this 
> problem? Sorry if it's a basic question, I have no much experience with 
> linking and using dylibs.
>
> вторник, 8 декабря 2015 г., 0:25:05 UTC+3 пользователь Ales Tsurko написал:
>>
>> A huge thanks for the direction! It's helped me a lot with understanding 
>> of my problem! But now I can't find from where sys.dylib is calling. I've 
>> checked out the dependencies, but didn't found why the path is 
>> ../lib/julia/sys.dylib Also the path for sys.dylib is @rpath/sys.dylib, 
>> which is the same as for libjulia.dylib, but I've no problems with the 
>> libjulia only with sys.dylib... It's blowing my mind. Where did this come 
>> from?
>>
>> понедельник, 7 декабря 2015 г., 20:33:01 UTC+3 пользователь Isaiah 
>> написал:
>>>
>>> You can change the lookup path using `install_name_tool`. See e.g. [1] 
>>> and check other answers on StackOverflow.
>>>
>>> [1] 
>>> http://thecourtsofchaos.com/2013/09/16/how-to-copy-and-relink-binaries-on-osx/
>>>
>>> On Sun, Dec 6, 2015 at 9:05 AM, Ales Tsurko <[email protected]> wrote:
>>>
>>>> Hello there! I'm trying to embed Julia in Xcode project. And what I 
>>>> don't understand is how to link Julia without installing Julia.
>>>> Currently I've done this steps:
>>>>
>>>> 1. Copied /include/ and /lib/ directories from Julia.app to my Xcode's 
>>>> project directory. Also I've changed directory structure from /lib/julia/ 
>>>> and /include/julia/ to just /lib/ and /include/, so in my project's 
>>>> directory it's in /julia/lib and /julia/include/ ;
>>>> 2. Linked libjulia.dylib;
>>>> 3. In the Build Settings added $(PROJECT_DIR)/julia/lib to Runpath 
>>>> Search Path;
>>>> 4. Added copy files phase with julia.h to Build Phases.
>>>>
>>>> And I get this error:
>>>>
>>>> *ERROR: system image file 
>>>>> "/Users/alestsurko/Library/Developer/Xcode/DerivedData/AUJulia-cudsforcspcktlaicnqzwclmzbye/Build/Products/Debug/AUJulia.app/Contents/MacOS/../lib/julia/sys.dylib"
>>>>>  
>>>>> not found*
>>>>
>>>>
>>>> It looks like something search library as if it was in the Julia.app 
>>>> directory structure. But I don't know how to change it. Is it possible at 
>>>> all or installing Julia is the required step?
>>>>
>>>
>>>

Reply via email to