Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

PerlApp : use threads

by P0w3rK!d (Pilgrim)
on May 22, 2003 at 16:09 UTC ( [id://260125]=perlquestion: print w/replies, xml ) Need Help??

P0w3rK!d has asked for the wisdom of the Perl Monks concerning the following question:

Hello,

When I use the following:

use threads; use threads::shared;
I am unable to compile an executable file using PerlApp from ActiveState Perl.
This is perl, v5.8.0 built for MSWin32-x86-multi-thread Binary build 806 provided by ActiveState Corp.
The console outputs the following:
C:\Work>perlapp my_app.pl --verbose PerlApp 5.1.0 build 510 Copyright (C) 1998-2003 ActiveState Corp. All rights reserved. Commercial license for P0w3rK!d <P0w3rK!d@MovingToPluto.com> -e syntax OK 'my_app.pl' had compilation errors.
An error dialog appears stating perlapp.exe threw an exception before the last 2 lines of output appear. Also, the verbose mode gave me no useful information.

Does anyone know what the problem is?

Note: non-threaded code compiles okay.

Thanks :)

-P0w3rK!d

Replies are listed 'Best First'.
Re: PerlApp : use threads
by P0w3rK!d (Pilgrim) on May 22, 2003 at 16:47 UTC
    Here's what I found on the ActiveState PDK mailing list...

    "It looks like you are using the Thread.pm module. PerlApp doesn't detect dependencies correctly for it; you will need to explicitly add the threads.pm module to your application:

    perlapp --nocheck --add threads YourApp.pl

    However, you may want to change your script to use threads.pm explicitly. Thread.pm is just a wrapper for backward compatibility with older thread implementations. If you only use Perl 5.8 and later, Thread.pm is just useless bloat."

    -(Credit to Jan Dubois c/o PDK@listserv.ActiveState.com)

    I used:

    C:\Work>perlapp --nocheck --add threads my_app.pl
    ...and it works now. Thanks Jan! :)

    -P0w3rK!d

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://260125]
Approved by hardburn
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others contemplating the Monastery: (4)
As of 2024-03-29 08:57 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found