MySQL Forums
Forum List  »  Perl

Problem building DBD on Linux
Posted by: Tony Green
Date: March 24, 2008 09:03AM

Hello,
I'm in the process of porting MySQL to Nokia's Linux Web Tablets (mainly for my own use, but also to make it available to other users). I've successfully built the MySQL client/server and the Perl DBI module, but I'm hitting a wall with the MySQL DBD module.

Running perl Makefile.PL fails with an error message: Can't load '/usr/lib/perl5/auto/DBI/DBI.so' for module DBI: /usr/lib/perl5/auto/DBI/DBI.so: cannot open shared object file: No such file or directory at /scratchbox/tools/lib/perl5/5.8.4/i686-linux-thread-multi/DynaLoader.pm line 230.

Digging further, I've run strace perl Makefile.PL; what appears to be the relevant output is:
----------------------------------------------------------------------------------
open("/scratchbox/tools/lib/perl5/5.8.4/AutoLoader.pm", O_RDONLY|O_LARGEFILE) = 5
ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, 0xbff7917c) = -1 ENOTTY (Inappropriate ioctl for device)
_llseek(5, 0, [0], SEEK_CUR) = 0
read(5, "package AutoLoader;\n\nuse strict;"..., 4096) = 4096
brk(0) = 0x84c6000
brk(0x84e7000) = 0x84e7000
read(5, " \'lib\').\n #\n\n (my $calldir"..., 4096) = 4096
_llseek(5, 4936, [4936], SEEK_SET) = 0
_llseek(5, 0, [4936], SEEK_CUR) = 0
close(5) = 0
stat64("/scratchbox/devkits/perl/lib/perl/auto/DBI", 0x814b158) = -1 ENOENT (No such file or directory)

[Deleted searching through @INC for clarity]

stat64("/usr/local/share/perl/5.8.4/auto/DBI", 0x814b158) = -1 ENOENT (No such file or directory)
stat64("/usr/lib/perl5/auto/DBI", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
stat64("/usr/lib/perl5/auto/DBI/DBI.so", {st_mode=S_IFREG|0644, st_size=117380, ...}) = 0
stat64("/usr/lib/perl5/auto/DBI/DBI.bs", {st_mode=S_IFREG|0644, st_size=0, ...}) = 0
open("/usr/lib/perl5/auto/DBI/DBI.so", O_RDONLY) = 5
read(5, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0(\0\1\0\0\0@0\0\000"..., 512) = 512
close(5) = 0
stat64("/scratchbox/devkits/perl/lib/perl/Carp/Heavy.pmc", 0xbff793c0) = -1 ENOENT (No such file or directory)

[Deleted searching through @INC for clarity]

open("/scratchbox/tools/lib/perl5/5.8.4/i686-linux-thread-multi/Carp/Heavy.pm", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
stat64("/scratchbox/tools/lib/perl5/5.8.4/Carp/Heavy.pmc", 0xbff793c0) = -1 ENOENT (No such file or directory)
open("/scratchbox/tools/lib/perl5/5.8.4/Carp/Heavy.pm", O_RDONLY|O_LARGEFILE) = 5
ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, 0xbff791bc) = -1 ENOTTY (Inappropriate ioctl for device)
_llseek(5, 0, [0], SEEK_CUR) = 0
read(5, "# Carp::Heavy uses some variable"..., 4096) = 4096
read(5, "ler($i++);\n my $caller = call"..., 4096) = 1831
read(5, "", 4096) = 0
close(5) = 0
_llseek(4, 7426, [7426], SEEK_SET) = 0
_llseek(4, 0, [7426], SEEK_CUR) = 0
close(4) = 0
_llseek(3, 109604, [109604], SEEK_SET) = 0
_llseek(3, 0, [109604], SEEK_CUR) = 0
close(3) = 0
write(2, "Can\'t load \'/usr/lib/perl5/auto/"..., 537Can't load '/usr/lib/perl5/auto/DBI/DBI.so' for module DBI: /usr/lib/perl5/auto/DBI/DBI.so: cannot open shared object file: No such file or directory at /scratchbox/tools/lib/perl5/5.8.4/i686-linux-thread-multi/DynaLoader.pm line 230.
at /usr/lib/perl5/DBI.pm line 261
BEGIN failed--compilation aborted at /usr/lib/perl5/DBI.pm line 261.
Compilation failed in require at /usr/lib/perl5/DBI/DBD.pm line 3044.
BEGIN failed--compilation aborted at /usr/lib/perl5/DBI/DBD.pm line 3045.
Compilation failed in require at Makefile.PL line 23.
) = 537
exit_group(255) = ?
--------------------------------------------------------------------------------

My best guess from this output is that for some reason it doesn't like what it's read from my DBI module. I wonder if anybody can shed any light on this please?

I'm using:
mysql 4.1.22 (the platform is missing pre-requisites for version 5)
DBI 1.58
dbd-mysql_4.005
gcc 3.4.4
on Nokia's development environment, which simulates an armel processor on X86.

Options: ReplyQuote


Subject
Written By
Posted
Problem building DBD on Linux
March 24, 2008 09:03AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.