Just to let folks know:
After installing the new perl5.002 beta1 in a test directory (I'm not quite
ready to replace the standard one yet), I thought I would try out the new
perl extension features (the last time I did an extension I had a
Makefile.SH and you had to build your extension along with perl, so its been
a while, which is why I wanted to try the new stuff :-).
The XS tutorial looked like a great place to start, so I put
/amb21/perl5.002/bin at the beginning of my $PATH (that's the test directory
where I installed perl) and I tried the first example.
Everything got built OK, but the first time I tried running the test1.pl
script I got:
amber> ./test1.pl
Can't load './Test1.o' for module Test1: dynamic linker: /amb21/perl5.002/bin/perl: /amb21/tom/testing/Test1/./Test1.o not a shared object at /amb21/perl5.002/lib/DynaLoader.pm line 136.
at blib/Test1.pm line 13
Can't load './Test1.o' for module Test1: dynamic linker: /amb21/perl5.002/bin/perl: /amb21/tom/testing/Test1/./Test1.o not a shared object at /amb21/perl5.002/lib/DynaLoader.pm line 136.
at blib/Test1.pm line 13
BEGIN failed--compilation aborted at ./test1.pl line 5.
So, I figured for some reason it is finding the .o file instead of the .so
file, so I removed it and tried again. This time I got:
amber> rm Test1.o
amber> perl test1.pl
Can't find loadable object for module Test1 in @INC (./blib /amb21/perl5.002/lib/m88k-cxux/5.002 /amb21/perl5.002/lib /amb21/perl5.002/lib/site_perl/m88k-cxux .) at blib/Test1.pm line 13
Can't find loadable object for module Test1 in @INC (./blib /amb21/perl5.002/lib/m88k-cxux/5.002 /amb21/perl5.002/lib /amb21/perl5.002/lib/site_perl/m88k-cxux .) at blib/Test1.pm line 13
BEGIN failed--compilation aborted at test1.pl line 5.
Since it was finding the .o file when I had it laying around, I tried making
a symlink from the .so file down inside ./blib to the current directory:
amber> ln -s blib/m88k-cxux/auto/Test1/Test1.so .
amber> pwd
/amb21/tom/testing/Test1
amber> ./test1.pl
Hello, world!
And now it works! I'm guessing that ./blib isn't enough to add to @INC, but
I'm not sure if the inconsistency is in the XS tutorial doc or the version
of make maker that shipped with beta1 or what.
I'm not in dire need of any kind of fix, but it would be nice if the
examples work as described by the time 5.002 gets out of beta, so I just
figured I'd let people know about it.
--
Tom.Horsley@mail.hcsc.com
Home: 511 Kingbird Circle Delray Beach FL 33444
Work: Harris Computers, 2101 W. Cypress Creek Rd. Ft. Lauderdale FL 33309
Support Project Vote Smart! They need your support in non-election years too!
(email pvs@neu.edu, 1-800-622-SMART, http://www.vote-smart.org)
After installing the new perl5.002 beta1 in a test directory (I'm not quite
ready to replace the standard one yet), I thought I would try out the new
perl extension features (the last time I did an extension I had a
Makefile.SH and you had to build your extension along with perl, so its been
a while, which is why I wanted to try the new stuff :-).
The XS tutorial looked like a great place to start, so I put
/amb21/perl5.002/bin at the beginning of my $PATH (that's the test directory
where I installed perl) and I tried the first example.
Everything got built OK, but the first time I tried running the test1.pl
script I got:
amber> ./test1.pl
Can't load './Test1.o' for module Test1: dynamic linker: /amb21/perl5.002/bin/perl: /amb21/tom/testing/Test1/./Test1.o not a shared object at /amb21/perl5.002/lib/DynaLoader.pm line 136.
at blib/Test1.pm line 13
Can't load './Test1.o' for module Test1: dynamic linker: /amb21/perl5.002/bin/perl: /amb21/tom/testing/Test1/./Test1.o not a shared object at /amb21/perl5.002/lib/DynaLoader.pm line 136.
at blib/Test1.pm line 13
BEGIN failed--compilation aborted at ./test1.pl line 5.
So, I figured for some reason it is finding the .o file instead of the .so
file, so I removed it and tried again. This time I got:
amber> rm Test1.o
amber> perl test1.pl
Can't find loadable object for module Test1 in @INC (./blib /amb21/perl5.002/lib/m88k-cxux/5.002 /amb21/perl5.002/lib /amb21/perl5.002/lib/site_perl/m88k-cxux .) at blib/Test1.pm line 13
Can't find loadable object for module Test1 in @INC (./blib /amb21/perl5.002/lib/m88k-cxux/5.002 /amb21/perl5.002/lib /amb21/perl5.002/lib/site_perl/m88k-cxux .) at blib/Test1.pm line 13
BEGIN failed--compilation aborted at test1.pl line 5.
Since it was finding the .o file when I had it laying around, I tried making
a symlink from the .so file down inside ./blib to the current directory:
amber> ln -s blib/m88k-cxux/auto/Test1/Test1.so .
amber> pwd
/amb21/tom/testing/Test1
amber> ./test1.pl
Hello, world!
And now it works! I'm guessing that ./blib isn't enough to add to @INC, but
I'm not sure if the inconsistency is in the XS tutorial doc or the version
of make maker that shipped with beta1 or what.
I'm not in dire need of any kind of fix, but it would be nice if the
examples work as described by the time 5.002 gets out of beta, so I just
figured I'd let people know about it.
--
Tom.Horsley@mail.hcsc.com
Home: 511 Kingbird Circle Delray Beach FL 33444
Work: Harris Computers, 2101 W. Cypress Creek Rd. Ft. Lauderdale FL 33309
Support Project Vote Smart! They need your support in non-election years too!
(email pvs@neu.edu, 1-800-622-SMART, http://www.vote-smart.org)