Thread

Posted on Wed May 23 12:02:23 2007 by mb
DynaLoader
Hi all, I am trying to embed perl into C. when I compile i am getting the error "undefined reference to boot_DynaLoader" my command options are: gcc -L/usr/lib/perl5/5.8.6/i386-linux-thread-multi/CORE -L/usr/lib/perl5/5.8.6/i386-linux-thread-multi/auto/DynaLoader/DynaLoader.a -I/usr/lib/perl5/5.8.6/i386-linux-thread-multi/CORE -ldl -lm -lpthread -lc -lcrypt -lperl could any one help on this. Thanks, mb.
Direct Responses: 5221 | Write a response
Posted on Thu May 24 16:32:23 2007 by karthic in response to 5207
Re: DynaLoader
Should be like this
gcc -L/usr/lib/perl5/5.8.6/i386-linux-thread-multi/CORE /usr/lib/perl5/5.8.6/i386-linux-thread-multi/auto/DynaLoader/DynaLoader.a -I/usr/lib/perl5/5.8.6/i386-linux-thread-multi/CORE -ldl -lm -lpthread -lc -lcrypt -lperl


You are directly including the archive file DynaLoader.a and you should not include -L before that. Instead use `perl -MExtUtils::Embed -e ccopts -e ldopts`, ExtUtils::Embed module will determine all of this information for you.

- Karthic
Write a response