Le 14/05/2013 20:54, nono a �crit :
> Hello,
Hello
>
> since days, I search and can't find the answer, so I'm asking here if
> anybody has a clue how to solve this thing ...
>
> What I've done :
> - added a package "perl-DBI", that builds and installs fine (I think).
> - try to add another perl package required by my experiment (and
> requiring the previous one saddly).
>
> And there it explodes.
>
> Basically, on my host linux, I did for perl-DBI :
> "perl Makefile.PL
> make
> make install"
>
> On the geexbox tools :
> "scripts/package perl-DBI" (ends OK)
>
>
> Then :
>
> on host :
>
on target ?
> perl -e 'require DBI;' ------------> ends OK, no problem.
>
>
>
>
> a the headache :
>
> ../toolchain/bin/perl -W
> -I../toolchain/armv7-openbricks-linux-gnueabihf/sysroot/usr/local/lib/perl/5.14.2/
> -e 'require "DBI.pm";'
>
> give the error :
>
>
> Can't load
> '../toolchain/armv7-openbricks-linux-gnueabihf/sysroot/usr/local/lib/perl/5.14.2//auto/DBI/DBI.so'
> for module DBI:
> ../toolchain/armv7-openbricks-linux-gnueabihf/sysroot/usr/local/lib/perl/5.14.2//auto/DBI/DBI.so:
> cannot open shared object file: No such file or directory at
> ../toolchain/armv7-openbricks-linux-gnueabihf/sysroot/usr/local/lib/perl/5.14.2//DynaLoader.pm
> line 190.
> at
> ../toolchain/armv7-openbricks-linux-gnueabihf/sysroot/usr/local/lib/perl/5.14.2//DBI.pm
> line 117
> BEGIN failed--compilation aborted at
> ../toolchain/armv7-openbricks-linux-gnueabihf/sysroot/usr/local/lib/perl/5.14.2//DBI.pm
> line 117.
> Compilation failed in require at -e line 1.
>
because you try to load a lib not built for your native arch ....
>
>
> Of course, the file exists and is readable :
> ls -l
> ../toolchain/armv7-openbricks-linux-gnueabihf/sysroot/usr/local/lib/perl/5.14.2//auto/DBI/DBI.so
> -rwxr-xr-x 1 root root 85148 2013-05-14 08:43
> ../toolchain/armv7-openbricks-linux-gnueabihf/sysroot/usr/local/lib/perl/5.14.2//auto/DBI/DBI.so
>
>
> trying ldd on the host gives nothing :
>
>
> root@Ubuntu-htpc:/opt/build/geexbox/openbricks/build/build.cubox.eglibc/test-1.37#
> ldd
> ../toolchain/armv7-openbricks-linux-gnueabihf/sysroot/usr/local/lib/perl/5.14.2//auto/DBI/DBI.so
> not a dynamic executable
normal
> root@Ubuntu-htpc:/opt/build/geexbox/openbricks/build/build.cubox.eglibc/test-1.37#
> ../toolchain/armv7-openbricks-linux-gnueabihf/sysroot/usr/bin/ldd
> ../toolchain/armv7-openbricks-linux-gnueabihf/sysroot/usr/local/lib/perl/5.14.2//auto/DBI/DBI.so
> $ not a dynamic executable
>
>
>
> However, on the cubox, it gives me (after installing package perl-DBI) :
> # ldd /usr/lib/perl/5.14.2/auto/DBI/DBI.so
> libc.so.6 => /lib/libc.so.6 (0xb6dfb000)
> /lib/ld-linux-armhf.so.3 (0xb6f45000)
> # ldd /lib/libc.so.6
> /lib/ld-linux-armhf.so.3 (0xb6eaa000)
> # ldd /lib/ld-linux-armhf.so.3
> statically linked
> #
>
and I'm pretty sure it works on cubox ;-)
>
>
> Has ANYONE ANY idea how to have this simple "require DBI;" to compile
> please ? (that is to say, have perl read the readable .so file)
>
yes
look at the attached archive (I have added perl-DBD-SQLite too , and it
builds fine here)
you need a host-perl-DBI package
Please test, and if it works as expected submit a patch
Regards
Tom
> I join the perl-DBI package files if you want to try on your dev
> environment . (I have not yet commited since it is useless for now :/)
> --
> You received this message because you are subscribed to the Google
> Groups "OpenBricks Development List" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to
openbricks-dev...@googlegroups.com.
> For more options, visit
https://groups.google.com/groups/opt_out.
>
>