Please take our Survey
logo       

Choosing A Webhost:
A web hosting service is a type of Internet hosting service that allows individuals and organizations to provide their own website accessible via the World Wide Web. Web hosts are companies that provide space on a server they own for use by their clients as well as providing Internet connectivity, typically in a data center. Web hosts can also provide data center space and connectivity to the Internet for servers they do not own to be located in their data center, called colocation. more...

Re: Unrecognized character: msg#00001

lang.perl.par

Subject: Re: Unrecognized character

Augusto Flavio wrote:

Hi!


I'm have a big problem. I make a module(pm) and now i
want compile this module. I tried use the perlcc but i
receive the msg that the module can't be compiled
because have shared libs.

However i found a module, PAR(Perl Archive Toolkit)
which can compile my module. Then, i was to install
this module(PAR). After the instalation of module i
run the command:

$ pp -o compiled.pm -M Exporter module.pm

ps.: The module.pm just require the lib Exporter.

I not have problems with the compilation. Then the
next step would be execute a script (CGI) that use the
compiled module.

I open my firefox and make run the script(CGI).
Unhappyly i get this msg: Unrecognized character \x7F at compiled.pm line 1.

Which i do? Have something wrong with the method of
compilation? Is someone that used the module PAR and
can help me?

Thanks for all.
ps.: Sorry for my english



Augusto Flavio










__________________________________ Do you Yahoo!? Yahoo! Mail - You care about security. So do we. http://promotions.yahoo.com/new_mail


Are you working in a Windows variant? If so, Windows will not just execute something with a '.pm' extension. Try just using

pp -o compiled.exe main_perl_file.pl

Notice in your example below you have ".pm" twice:
> pp -o compiled.pm -M Exporter module.pm
I use "compiled.exe" because that would be the name of the executable I would
be trying to create. I use perl_file.pl because that is the perl code I would want the
compiled executable to be created from.

Also, I use Exporter quite often in my modules, and I NEVER have to use '-M Exporter'. Try making your line just pp -o compiled.exe main_perl_file.pl

Internal to each perl module that I use, where I want to export subroutines
(NOT in the .pl file!) I have something like this:

package my_package;
use Exporter;
@ISA = qw(Exporter);
@EXPORT = ( "subroutine_1",
"subroutine_2",
...
"subroutine_N",
);

Good luck










<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
qnx.openqnx.dev...    gcc.libstdc++.c...    solaris.opensol...    information-ret...    misc.misterhous...    web.catalyst.ge...    apache.webservi...    redhat.release....    hardware.lirc/2...    kernel.autofs/2...    technology.sust...    linux.vdr/2003-...    editors.lyx.gen...    org.user-groups...    netbsd.devel.pk...    xdg.devel/2004-...    version-control...    jakarta.slide.d...    debian.packages...    creativecommons...    ports.ppc.embed...    bug-tracking.bu...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe