toddr / Net-Daemon

Read-only release history for Net-Daemon
http://metacpan.org/release/Net-Daemon
0 stars 0 forks source link

Net::Daemon emitting warnings when forks package installs threads.pm [rt.cpan.org #75178] #16

Closed toddr closed 3 years ago

toddr commented 3 years ago

Migrated from rt.cpan.org#75178 (status was 'open')

Requestors:

From toddr@cpan.org on 2012-02-21 01:06:06 :

This will emit copious re-define warnings in perl 5.15+. It didn't in 5.14 as best I can tell
perl -cw  -MNet::Daemon -e1

The reason as best I can tell is because threads and threads::shared are pulled in even if perl 
was not compiled with threads. 

I suggest renaming the variable $this_is_510 to $this_is_510_threads

The change this:
my $this_is_510 = $^V ge v5.10.0;

To This:
$this_is_510_threads  = $^V ge v5.10.0 && $Config{'usethreads'};

From toddr@cpan.org on 2012-02-21 01:06:58 :

Malcom, I'd like your take on this idea. I'll do a release if you have nothing in the works ATM.

Todd

From m.nooning@comcast.net on 2012-02-21 11:49:50 :

Hello Todd,

I just started a new major task.  I cannot look at this until the 
weekend.  There were no problems on Windows XP when I checked last 
week.  However, there were problems on my CentOS Linux.

Do you have both Linux and Windows that you can test on?

On 2/20/2012 8:06 PM, Todd Rinaldo via RT wrote:
>         Queue: Net-Daemon
>   Ticket<URL: https://rt.cpan.org/Ticket/Display.html?id=75178>
>
> Malcom, I'd like your take on this idea. I'll do a release if you have nothing in the works ATM.
>
> Todd
>

From toddr@cpan.org on 2012-05-23 19:04:36 :

More info on this. It looks like when forks is installed, it installs it's own version of threads over 
top of threads.pm, probably when perl is built without threads support.

We probably need to detect that use threads is using forks and behave accordingly.

From toddr@cpan.org on 2012-05-23 19:08:46 :

If after loading threads, you notice that $forks::threads is true, it means threads is actually 
forks masquerading as threads.