[Gambas-user] Problems with Library libffi.so.5 using GB_DIR
EA7DFH
ea7dfh at ...2382...
Tue Apr 6 22:12:47 CEST 2010
craf escribió:
> -----Mensaje original-----
> De: Benoît Minisini <gambas at ...1...>
> Reply-to: mailing list for gambas users
> <gambas-user at lists.sourceforge.net>
> Para: mailing list for gambas users <gambas-user at lists.sourceforge.net>
> Asunto: Re: [Gambas-user] Problems with Library libffi.so.5 using GB_DIR
> Fecha: Tue, 6 Apr 2010 18:50:35 +0200
>
>
>> -----Mensaje original-----
>> De: craf <prog at ...2177...>
>> Reply-to: mailing list for gambas users
>> <gambas-user at lists.sourceforge.net>
>> Para: Lista Gambas Ingles <gambas-user at lists.sourceforge.net>
>> Asunto: [Gambas-user] Problems with Library libffi.so.5 using GB_DIR
>> Fecha: Mon, 05 Apr 2010 20:40:21 -0400
>>
>>> Hi.
>>>
>>> I'm still trying to port an application made in Gambas 2.20.2 in a
>>> distribution Ubuntu 9.10 to a distribution Ubuntu 8.04, using the
>>> variable GB_DIR.
>>>
>>> My file executable.sh is as follows:
>>>
>>> #!/bin/sh
>>> export PATH=/opt/project/gambas2/bin
>>> export GB_DIR=/opt/project/gambas2/lib
>>> export
>>> LD_LIBRARY_PATH=/opt/project/gambas2/lib_shared/lib:/opt/project/gambas2/l
>>> ib_shared/usr/lib exec /opt/project/project.gambas
>>>
>>> When I try to execute it, gives me:
>>>
>>> "Segmentation fault"
>>>
>>> When you run the following command:
>>>
>>> ldd gbr2
>>>
>>> I stated:
>>>
>>> libffi.so.5 => not found
>>>
>>> This link is really there and points to the library libffi.so.5.0.8
>>>
>>> I searched the Internet for a possible solution, but all say that this
>>> error is because it is the libffi library, but in this case if.
>>> Could it be a problem in the library that comes with Ubuntu 9.10
>>> distribution?.
>>>
>>> Regards
>> Hi.
>>
>>
>> Gradually I have been understanding the operation of the variable
>> GB_DIR. As commented in the previous post, GBR2 not find the shared
>> library libffi.so.
>> Since I have little knowledge about C, I can not find you may be
>> failing.
>> As libffi.so.5.0.8 shared library is generated at compile Gambas, is
>> there any option to be added to the configure command?.
>> Do all the tips Doriano kindly told me, but nothing has worked.
>>
>> Any light on this matter is appreciated.
>>
>> Regards
>>
>
>
>> 1) GB_DIR must point at the gambas installation directory, i.e.
>> "/opt/project/gambas2/"
>
> Yes, That's right, this is the path that was provided in the file .sh
>
>> 2) You must check where the segfault occurs, because a missing shared library
>> should not cause that.
>
>> To do that, compile Gambas with debugging information enabled (i.e. compile it
>>from sources without changing any option). Then use the "gdb" debugger as
>> explained on the web site ("Reporting a problem" page).
>
> This is what gives me as a result:
>
> GNU gdb 6.8-debian
> Copyright (C) 2008 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law. Type "show copying"
> and "show warranty" for details.
> This GDB was configured as "i486-linux-gnu"...
>
> (gdb) set args -p
>
> (gdb) run
>
> Starting program: /opt/project/gambas2/bin/gbx2 -p
>
> /opt/project/gambas2/bin/gbx2: error while loading shared libraries: libffi.so.5: cannot open shared object file: No such file or directory
>
> Program exited with code 0177.
>
> (gdb) bt
> No stack.
>
>> 3) libffi is checked at configuration time, so if it is not installed on your
>> system, either not detected, you will have a warning that you won't be able to
>> use extern functions, but that's all. Gambas will work anyway.
>
> The libffi library if installed on my system, before compiling and installing Gambas 2.
>
> This gives me running the following command:
>
> $locate libffi.so
> ..
> /usr/lib/libffi.so
> /usr/lib/libffi.so.5
> /usr/lib/libffi.so.5.0.8
>
> The main problem is that I failed to explain my problem.
>
> I have Gambas 2.20.2 installed on my computer with Ubuntu 9.10.
>
> If I create a project and execute it on the same computer running
> smoothly.
>
> Now, if I want to bring my project to another computer with Ubuntu 9.10
> is not installed Gambas 2.20.2, use the variable GB_DIR. I think the
> routes and folders, copy and gbr2 gbx2. Copy only the libraries of
> components that need to make the program work, example. gb.gtk.so, la,
> so.0.0.0, etc.
> Do not copy the shared libraries needed by libraries Gambas components,
> as these are installed on the other computer.
>
> Run the program and works flawlessly.
>
> Now, I wanted to see if this worked for a different distribution of
> 9.10, ex. 8.04 (the oldest supported by Canonical).
>
> For this I installed VirtualBox and I think a clean install of Ubuntu
> 8.04 on my computer.
>
> I copy the previous project, but now I add the shared libraries needed
> by the libraries of components of Gambas.
>
> I run the program and fails.
>
>
> Regards
Ooops. I think I replied in the wrong thread. Craf, please, look at your
other thread "Problem with PATH to shared library", may be it could help.
Regards,
Jesus Guardon
More information about the User
mailing list