Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Perl > Perl Misc > Perl Packager, pp, compilation

Reply
Thread Tools

Perl Packager, pp, compilation

 
 
mathieu.lory@gmail.com
Guest
Posts: n/a
 
      11-14-2006
Hello,

I developped a Perl application and I would like to use it under
different computers (and differents OS) whose haven't Perl on it.
So, I want to compile my script.

I saw "Perl Packager" sur CPAN :
http://search.cpan.org/~autrijus/PAR-0.85/script/pp

I can use it locally, the binary works well on my computer, but not on
other computers.

This is the error message when I run it on other computer :
Can't load
'/tmp/par-mathieu/cache-708ca5057424e91f75390798270f708076161471/e86591d6.so'
for module Gtk2::MozEmbed: libgtkembedmoz.so: Ne peut ouvrir le fichier
d'objet partagé: Aucun fichier ou répertoire de ce type at
/usr/lib/perl/5.8/DynaLoader.pm line 225.
at /usr/share/perl5/PAR/Heavy.pm line 107
Compilation failed in require at script/script.pl line 5.,

But, with pp command, I've added the libgtkembedmoz.so to the .PAR file
(with --addlist parameter)

I also use these depedencies :
Mozilla:OM
Gtk2::MozEmbed

Please, could you help me compiling my script ?

 
Reply With Quote
 
 
 
 
Ben Morrow
Guest
Posts: n/a
 
      11-14-2006

Quoth http://www.velocityreviews.com/forums/(E-Mail Removed):
>
> I saw "Perl Packager" sur CPAN :
> http://search.cpan.org/~autrijus/PAR-0.85/script/pp
>
> I can use it locally, the binary works well on my computer, but not on
> other computers.
>
> This is the error message when I run it on other computer :
> Can't load
> '/tmp/par-mathieu/cache-708ca5057424e91f75390798270f708076161471/e86591d6.so'
> for module Gtk2::MozEmbed: libgtkembedmoz.so: Ne peut ouvrir le fichier
> d'objet partagé: Aucun fichier ou répertoire de ce type at
> /usr/lib/perl/5.8/DynaLoader.pm line 225.
> at /usr/share/perl5/PAR/Heavy.pm line 107
> Compilation failed in require at script/script.pl line 5.,
>
> But, with pp command, I've added the libgtkembedmoz.so to the .PAR file
> (with --addlist parameter)


You don't use -A for dependant libraries, you use -l, e.g.

pp -o mozembed -l gtkembedmoz mozembed.pl

Ben

--
Musica Dei donum optimi, trahit homines, trahit deos. |
Musica truces mollit animos, tristesque mentes erigit.|(E-Mail Removed)
Musica vel ipsas arbores et horridas movet feras. |
 
Reply With Quote
 
 
 
 
mathieu.lory@gmail.com
Guest
Posts: n/a
 
      11-15-2006
Ben Morrow a écrit :
> You don't use -A for dependant libraries, you use -l, e.g.
> pp -o mozembed -l gtkembedmoz mozembed.pl


Thanks for your help Ben, It's work now. But I've another strange error
: my application crash at startup, with only 2 warnings :

*** This build of Glib was compiled with glib 2.9.5, but is currently
running with 2.8.3, which is too old. We'll continue, but expect
problems!
*** This build of Gtk2 was compiled with gtk+ 2.8.16, but is currently
running with 2.8.6, which is too old. We'll continue, but expect
problems!

So, I don't understand the problem, because As I know, all the libs are
included to the package, so it can't be a problem of version ! no ?

then, for Gtk2 : "was compiled with gtk+ 2.8.16, but is currently
running with 2.8.6, which is too old" => 2.8.16 is older than 2.8.6 ?
really ?

 
Reply With Quote
 
Ben Morrow
Guest
Posts: n/a
 
      11-16-2006

Quoth (E-Mail Removed):
> Ben Morrow a écrit :
> > You don't use -A for dependant libraries, you use -l, e.g.
> > pp -o mozembed -l gtkembedmoz mozembed.pl

>
> Thanks for your help Ben, It's work now. But I've another strange error
> : my application crash at startup, with only 2 warnings :
>
> *** This build of Glib was compiled with glib 2.9.5, but is currently
> running with 2.8.3, which is too old. We'll continue, but expect
> problems!
> *** This build of Gtk2 was compiled with gtk+ 2.8.16, but is currently
> running with 2.8.6, which is too old. We'll continue, but expect
> problems!
>
> So, I don't understand the problem, because As I know, all the libs are
> included to the package, so it can't be a problem of version ! no ?


Did you include *all* the required libraries? On my system, a program
which links libgtkembedmoz.so needs at least

-lgtkembedmoz -lxpcom -lplds4 -lplc4 -lnspr4 -lgtk-x11-2.0
-lgdk-x11-2.0 -latk-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0
-lpango-1.0 -lcairo -lgobject-2.0 -lgmodule-2.0 -lglib-2.0

(along with some runtime linker flags to let it find those libraries),
plus a whole lot of other stuff like -lglitz and -lexpat that those
libraries pull in, plus a whole lot more stuff like -lm, -ldl and -lX11
that are definitely part of the operating system and which it would be a
very bad idea to attempt to put in a package.

Now that I've thought about it a little further, what you are trying to
do is likely to be rather difficult. You need to decide what you are
going to require the client to have installed: gtkembedmoz? Mozilla?
Gtk? Gdk? Glib? X? Things you require to be present on the client system
will obviously have to be the correct version, so you will need to find
out what those need to be. Things you don't require to be present you
must include; and you will need to include all their dependencies. You
can use the ldd tool to find these if you are on Linux; if you aren't
I'm sure there is some equivalent tool for your platform. You must also
be aware that if you package something (say, Mozilla) and the client
already has it installed, then things may not work as the user expects.
For instance, any plugins they have installed may or may not be found by
your packaged version; and they may or may not work correctly. In the
worst case, your packaged version will find some plugin or some user
setting that is incompatible and causes it to break.

> then, for Gtk2 : "was compiled with gtk+ 2.8.16, but is currently
> running with 2.8.6, which is too old" => 2.8.16 is older than 2.8.6 ?
> really ?


No, it's saying 2.8.6 is too old, as 2.8.6 is older than 2.8.16. The
sentence is not terribly clear, so if English is not your native tongue
I'm not surprised you misunderstood it .

Ben

--
The cosmos, at best, is like a rubbish heap scattered at random.
Heraclitus
(E-Mail Removed)
 
Reply With Quote
 
mathieu.lory@gmail.com
Guest
Posts: n/a
 
      11-16-2006
Ben Morrow a écrit :
> Did you include *all* the required libraries? On my system, a program
> which links libgtkembedmoz.so needs at least
>
> -lgtkembedmoz -lxpcom -lplds4 -lplc4 -lnspr4 -lgtk-x11-2.0
> -lgdk-x11-2.0 -latk-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0
> -lpango-1.0 -lcairo -lgobject-2.0 -lgmodule-2.0 -lglib-2.0


Thanks to your help, I've included them now ; I don't have my previous
warning about versions, but... My app crash at startup. I thinks it's a
problem with gtk or with the compilation, because app works fine under
computer where it compile from.
I haven't any error message in the console, only a dialog box like this
(but in french) : "application has quit, you can inform developpers or
restart application now ..."

> that are definitely part of the operating system and which it would be a
> very bad idea to attempt to put in a package.

If it's a bad idea...

> sentence is not terribly clear, so if English is not your native tongue
> I'm not surprised you misunderstood it .

No, it's not my mother tongue didn't you guess it ?

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
FAQ 1.4 What are Perl 4, Perl 5, or Perl 6? PerlFAQ Server Perl Misc 0 02-27-2011 11:00 PM
FAQ 2.17 What is perl.com? Perl Mongers? pm.org? perl.org? cpan.org? PerlFAQ Server Perl Misc 0 02-03-2011 11:00 AM
FAQ 1.4 What are Perl 4, Perl 5, or Perl 6? PerlFAQ Server Perl Misc 0 01-23-2011 05:00 AM
Compilation error with seperate compilation C__chp C++ 4 02-15-2008 03:57 PM
Perl Help - Windows Perl script accessing a Unix perl Script dpackwood Perl 3 09-30-2003 02:56 AM



Advertisments