Skip Menu |

This queue is for tickets about the Event-Lib CPAN distribution.

Report information
The Basics
Id: 7494
Status: open
Priority: 0/
Queue: Event-Lib

People
Owner: VPARSEVAL [...] cpan.org
Requestors:
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: 0.02
Fixed in: (no value)



Subject: Makefile.PL bugs
return 1 if system("$CC check.c $INC $LIBS 2>/dev/null") == 0; you should omit the "2>/dev/null" part Also, you should pass ccflags, ie my $CC = $Config{cc}.' '.$Config{ccflags}.' '; also, when you WriteMakefile, you ignore %args which should be fixed
--- Makefile.PL 2004-08-26 23:21:14.000000000 -0700 +++ Makefile.PL.new 2004-08-27 06:27:33.578125000 -0700 @@ -2,12 +2,13 @@ use ExtUtils::MakeMaker; use Config; +my %args = map { split /\s*=\s*/ } @ARGV; sub have_libevent { - my $CC = $Config{cc}; - my %args = map { split /\s*=\s*/ } @ARGV; + my $CC = $Config{cc}.' '.$Config{ccflags}.' '; my $LIBS = $args{ LIBS } || "-levent"; my $INC = $args{ INC }; - return 1 if system("$CC check.c $INC $LIBS 2>/dev/null") == 0; +# return 1 if system("$CC check.c $INC $LIBS 2>/dev/null") == 0; + return 1 if system("$CC check.c $INC $LIBS") == 0; return 0; } @@ -29,9 +30,9 @@ PREREQ_PM => {}, ABSTRACT_FROM => 'lib/Event/Lib.pm', AUTHOR => 'Tassilo von Parseval <tassilo.von.parseval@rwth-aachen.de>', - LIBS => ['-levent -lm'], - DEFINE => '', - INC => '-I.', + LIBS => [ $args{LIBS} ], + DEFINE => '-DHAVE_CONFIG_H', + INC => $args{INC} , clean => { FILES => "a.out" }, );
I had to assign a default to $args{LIBS} so that the module is linked with "-levent -lm" when LIBS wasn't given on the command-line.
Date: Fri, 27 Aug 2004 16:08:08 +0200
From: Tassilo von Parseval <tassilo.von.parseval [...] rwth-aachen.de>
Subject: Re: [cpan #7494] Makefile.PL bugs
To: Guest via RT <bug-Event-Lib [...] rt.cpan.org>
RT-Send-Cc:
On Fri, Aug 27, 2004 at 08:59:39AM -0400 Guest via RT wrote: Show quoted text
> This message about Event-Lib was sent to you by guest <> via rt.cpan.org
[ Uggh. I wish rt.cpan.org told me who wrote this ] Show quoted text
> Full context and any attached attachments can be found at: > <URL: https://rt.cpan.org/Ticket/Display.html?id=7494 > > > > return 1 if system("$CC check.c $INC $LIBS 2>/dev/null") == 0; > > you should omit the "2>/dev/null" part > Also, you should pass ccflags, ie > > my $CC = $Config{cc}.' '.$Config{ccflags}.' '; > > also, when you WriteMakefile, you ignore %args which should be fixed
Yep, you're right. Thanks for your two patches. I'll both apply the Makefile.PL and Lib.xs patch. Tassilo -- $_=q#",}])!JAPH!qq(tsuJ[{@"tnirp}3..0}_$;//::niam/s~=)]3[))_$-3(rellac(=_$({ pam{rekcahbus})(rekcah{lrePbus})(lreP{rehtonabus})!JAPH!qq(rehtona{tsuJbus#; $_=reverse,s+(?<=sub).+q#q!'"qq.\t$&."'!#+sexisexiixesixeseg;y~\n~~dddd;eval
[tassilo.parseval@post.rwth-aachen.de - Fri Aug 27 11:08:36 2004]: Show quoted text
> On Fri, Aug 27, 2004 at 08:59:39AM -0400 Guest via RT wrote: >
> > This message about Event-Lib was sent to you by guest <> via
rt.cpan.org Show quoted text
> > [ Uggh. I wish rt.cpan.org told me who wrote this ] >
> > Full context and any attached attachments can be found at: > > <URL: https://rt.cpan.org/Ticket/Display.html?id=7494 > > > > > > > return 1 if system("$CC check.c $INC $LIBS 2>/dev/null") == 0; > > > > you should omit the "2>/dev/null" part > > Also, you should pass ccflags, ie > > > > my $CC = $Config{cc}.' '.$Config{ccflags}.' '; > > > > also, when you WriteMakefile, you ignore %args which should be fixed
> > Yep, you're right. Thanks for your two patches. I'll both apply the > Makefile.PL and Lib.xs patch.
It'd be a good idea to make that my $CC = $Config{cc}.' '.$Config{ccflags}.' -DHAVE_CONFIG_H '; -DHAVE_CONFIG_H like we have for the module (it helps)