OESF Portables Forum
Everything Else => General Support and Discussion => Zaurus General Forums => Archived Forums => Software => Topic started by: Zar2Cool on September 29, 2004, 04:00:40 pm
-
Hello to everyone.
I am trying to install Apache/Perl/Mysql on my Zaurus. I write a lot of perl scripts that work with mysql and it would be handly to test stuff on the Zaurus. Speaking of, it's a 5600 with 1GB SD and Sharp 3.00 rom (I really should upgrade the rom, but I don't want to blast everything away.)
Ya, I know it's going to be slow and all that, but I am doing this more to just see if I can.
Apache, mySQL, and Perl 5.8 installed fine. It's the Perl DBI module that I am having problems with.
In order to build it, I need make. I downloaded dev_img and tried to install it, but I got this error.
# ./image_setup.sh /mnt/card/devel/dev_img-1.5 /mnt/dev
Setting mount point /mnt/dev...
Mounting image /mnt/card/devel/dev_img-1.5...
Failed to mount image /mnt/card/devel/dev_img-1.5 on /mnt/dev
#
It does mount the image fine, but seems to fail seting up the symlinks.
I tried to set them up by hand and I think it's right. Least the config script is happy.
I downloaded the Perl DBI source and did.
Perl Makefile.pl
and it was happy. I edited the makefile to point to the correct location of gcc and ran make, but I get this error.
cp lib/DBI/DBD.pm blib/lib/DBI/DBD.pm
cp lib/DBI/ProxyServer.pm blib/lib/DBI/ProxyServer.pm
cp lib/Win32/DBIODBC.pm blib/lib/Win32/DBIODBC.pm
cp dbi_sql.h blib/arch/auto/DBI/dbi_sql.h
cp lib/DBD/ExampleP.pm blib/lib/DBD/ExampleP.pm
cp lib/DBI/PurePerl.pm blib/lib/DBI/PurePerl.pm
cp lib/DBI/ProfileData.pm blib/lib/DBI/ProfileData.pm
/home/system/var/mnt/dev/usr/bin/perl5.8.0 -p -e "s/~DRIVER~/Perl/g" ./Driver.xst > Perl.xsi
/home/system/var/mnt/dev/usr/bin/perl5.8.0 /mnt/pkgs/perl/perl5.8.0/lib/5.8.0/ExtUtils/xsubpp -typemap /mnt/pkgs/perl/perl5.8.0/lib/5.8.0/ExtUtils/typemap -typemap typemap Perl.xs > Perl.xsc && mv Perl.xsc Perl.c
/mnt/dev/bin/gcc -c -fno-strict-aliasing -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -O3 -DVERSION=\"1.43\" -DXS_VERSION=\"1.43\" -fpic "-I/mnt/pkgs/perl/perl5.8.0/lib/5.8.0/linux/CORE" -Wall -Wno-comment -DDBI_NO_THREADS Perl.c
gcc: installation problem, cannot exec `as': No such file or directory
make: *** [Perl.o] Error 1
I have not had this problem when installing on X86 systems, so I am assuming that it is something that I need to change for arm CPU support.
Can anyone offer any tips or pointers on how to debug this?
Thank you
-Eddie
-
I successfully got the MySQLPP (the pure Perl implementation of the MySQL driver) and DBI modules to compile on my Zaurus, but I was never able to connect to the MySQL database with any of the scripts that I wrote. I will gladly tar up the modules for you if you are interested.
Hope this helps!
-
Here are the modules that I compiled with dev_img-1.5. If you untar the modules under /mnt/card, You should be able to add these modules to your path with:
use lib qw(/mnt/card/perlmods);
use DBI;
You can take a look at the documentation for mysqlPP on CPAN (http://search.cpan.org/~oyama/DBD-mysqlPP-0.04/mysqlPP.pm).
Let me know if you actually get it to connect to the database.
Enjoy!
-
Thank for the code. I got it working.
The trick is not to say what host you are connecting to. It defaults to the localhost and that seems to work.
My test program blow.
#!/usr/bin/perl
use lib qw(/mnt/card/perlmods);
use DBI;
# Connect to the database.
my $dbh10 = DBI->connect("dbi:mysqlPP:inv","root","");
$sth = $dbh10->prepare( "
SELECT itemnumber,itemgroup,descrip
FROM maininv" );
$sth->execute();
while ( ($itemnumber,$itemgroup,$descrip ) = $sth->fetchrow_array() ) {
print "$itemnumber,$itemgroup,$descrip\n";
};
$sth->finish;
Thanks a bunch. Now to see if my Zaurus can handle this large program.
-Eddie
-
If you have time, can you try.
[code[
select count(*) from <table>;
[/code]
it's hanging if i do that. However,
select count(*) from where == 1;
having anything where in the statement and it seems to work.
Not sure what is going on here.
Thanks
-
I'm excited to give the modules a try. I'll take a look at the problem you are seeing, but I'm going on a weeks vacation starting today.
TTFN