You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Haroon Rafique <ha...@utoronto.ca> on 2003/06/06 15:50:47 UTC
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
On Today at 11:32am, SB=>Stas Bekman <st...@stason.org> wrote:
SB>
SB> Both failed due to the missing LWP. I was able to reproduce the exact
SB> problem by removing LWP/UserAgent.pm. I have now fixed both in cvs.
SB> Please 'cvs up' and test again. Thanks.
SB>
after cvs up, "make test" skipped a bunch of tests in both the first batch
and the 2nd batch (since libwww-perl was not installed). 100% successful.
After that, I installed:
libwww-perl-5.69
CGI.pm-2.93
HTML-Parser-3.28
URI-1.23
to satisfy all dependencies for installing libwww-perl
The tests, that were skipped last time around, ran successfully this time.
100%.
Now onto investigating my originally reported problem as to why the older,
system-wide installation is interfering with the "make test". Any
suggestions on how to get started on that?
Thanks,
--
Haroon Rafique
<ha...@utoronto.ca>
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Stas Bekman <st...@stason.org>.
Perrin Harkins wrote:
> On Thu, 2003-06-12 at 20:10, Stas Bekman wrote:
>
>>Perrin, do you think it's worth documented this somewhere in the
>>troubleshooting section? OS-specific issues?
>
>
> That's a good idea. I'm going on vacation for a couple of weeks and
> won't be able to look at it until I get back, but if no one else has
> done it by then I'll whip something up.
OK, I'll add your reply's content to:
http://perl.apache.org/docs/1.0/guide/troubleshooting.html#OS_Specific_Notes
and then once you return you can polish it further.
Enjoy the vacation. Soon I'm taking one too ;)
__________________________________________________________________
Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org http://ticketmaster.com
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Perrin Harkins <pe...@elem.com>.
On Thu, 2003-06-12 at 20:10, Stas Bekman wrote:
> Perrin, do you think it's worth documented this somewhere in the
> troubleshooting section? OS-specific issues?
That's a good idea. I'm going on vacation for a couple of weeks and
won't be able to look at it until I get back, but if no one else has
done it by then I'll whip something up.
- Perrin
Re: UTF-8 support
Posted by Mithun Bhattacharya <in...@yahoo.com>.
I did a search for UTF-8 and locale at
http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/
In the past 2-3 months the only problem seems to be that regex doesnt
seem to work properly on UTF-8 input
[http://www.xray.mpe.mpg.de/cgi-bin/w3glimpse2html/perl5-porters/2003-05/msg00183.html?68#mfs]
and that RedHat 9.0 ships with a buggy maintenance snapshot of perl
5.8.x
[http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2003-05/msg00352.html]
I think it means we better wait a while before making large scale
applications to manipulate UTF-8 data but I could possibly be wrong.
Also ofcourse dont develop applications using RedHat 9.0's perl :).
Mithun
--- Stas Bekman <st...@stason.org> wrote:
> To second Perrin, 5.8.0's UTF8 support is not broken. From what I was
>
> following on the p5p, 5.8.0 had some minor issues, but 5.8.1 which
> will be
> released really soon now (my guess: July at OSCon) have them (all?)
> sorted
> out. You may want to browse p5p archives and rt.perl.org to see what
> UTF8
> problems were if any and whether they were resolved. If you find
> something
> that would be of interest to other readers, please post a summary
> here.
__________________________________
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
http://sbc.yahoo.com
Re: UTF-8 support [was : (Re: [mp2] make test fails with 1.99_10-dev
sources on redhat)]
Posted by Stas Bekman <st...@stason.org>.
Perrin Harkins wrote:
> Mithun Bhattacharya wrote:
>
>> If
>> perl's UTF-8 support is broken in 5.8.0 doesnt that mean it will break
>> any mod_perl application which is handling XML's or UTF-8 data ?
>
>
> I didn't say it was broken. I don't really know if it is. What I do
> know is that some documents, including CPAN modules, are not UTF8
> compliant, and opening them as UTF8 gives mysterious errors and test
> failures. Remember, this locale setting is a recent change. I doubt
> that chaning it back to what it was in Red Hat 7.3 will impact XML parsing.
To second Perrin, 5.8.0's UTF8 support is not broken. From what I was
following on the p5p, 5.8.0 had some minor issues, but 5.8.1 which will be
released really soon now (my guess: July at OSCon) have them (all?) sorted
out. You may want to browse p5p archives and rt.perl.org to see what UTF8
problems were if any and whether they were resolved. If you find something
that would be of interest to other readers, please post a summary here.
__________________________________________________________________
Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org http://ticketmaster.com
Re: UTF-8 support [was : (Re: [mp2] make test fails with 1.99_10-dev
sources on redhat)]
Posted by Perrin Harkins <pe...@elem.com>.
Mithun Bhattacharya wrote:
> If
> perl's UTF-8 support is broken in 5.8.0 doesnt that mean it will break
> any mod_perl application which is handling XML's or UTF-8 data ?
I didn't say it was broken. I don't really know if it is. What I do
know is that some documents, including CPAN modules, are not UTF8
compliant, and opening them as UTF8 gives mysterious errors and test
failures. Remember, this locale setting is a recent change. I doubt
that chaning it back to what it was in Red Hat 7.3 will impact XML parsing.
- Perrin
UTF-8 support [was : (Re: [mp2] make test fails with 1.99_10-dev sources on redhat)]
Posted by Mithun Bhattacharya <in...@yahoo.com>.
--- Stas Bekman <st...@stason.org> wrote:
> > My understanding is that setting locale to UTF8 makes it try to
> open
> > everything as a UTF8 document, but not everything is one. It
> causes
> > problems for Java and Konsole too apparently. It could simply be
> that
> > Perl's handlling of UTF8 is broken, but I didn't want UTF8 in the
> first
> > place so putting LANG back to what it was before seems like a
> reasonable
> > fix to me.
If I understand correctly most XML parsers support UTF-8 primarily. If
perl's UTF-8 support is broken in 5.8.0 doesnt that mean it will break
any mod_perl application which is handling XML's or UTF-8 data ? What
about Axkit etc ? Anyone facing problem handling UTF-8 data using 5.8.0
based mod_perl setup ?
Mithun
__________________________________
Do you Yahoo!?
Yahoo! Calendar - Free online calendar with sync to Outlook(TM).
http://calendar.yahoo.com
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Stas Bekman <st...@stason.org>.
Perrin Harkins wrote:
> On Tue, 2003-06-10 at 05:08, Mithun Bhattacharya wrote:
>
>>What exactly is broken in RedHat 8.0/9.0 - RedHat's build of perl,
>>perl's support for unicode or perl's support for locales ?
>
>
> Short answer: the Perl build is fine if you change the locale to what it
> was in previous version of Red Hat (en_US.ISO8859-1) or simply remove
> the UTF8 part.
>
> My understanding is that setting locale to UTF8 makes it try to open
> everything as a UTF8 document, but not everything is one. It causes
> problems for Java and Konsole too apparently. It could simply be that
> Perl's handlling of UTF8 is broken, but I didn't want UTF8 in the first
> place so putting LANG back to what it was before seems like a reasonable
> fix to me.
>
> More here:
> http://twiki.org/cgi-bin/view/Codev/UsingPerl58OnRedHat8
> http://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=87682
Perrin, do you think it's worth documented this somewhere in the
troubleshooting section? OS-specific issues?
__________________________________________________________________
Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org http://ticketmaster.com
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Perrin Harkins <pe...@elem.com>.
On Tue, 2003-06-10 at 05:08, Mithun Bhattacharya wrote:
> What exactly is broken in RedHat 8.0/9.0 - RedHat's build of perl,
> perl's support for unicode or perl's support for locales ?
Short answer: the Perl build is fine if you change the locale to what it
was in previous version of Red Hat (en_US.ISO8859-1) or simply remove
the UTF8 part.
My understanding is that setting locale to UTF8 makes it try to open
everything as a UTF8 document, but not everything is one. It causes
problems for Java and Konsole too apparently. It could simply be that
Perl's handlling of UTF8 is broken, but I didn't want UTF8 in the first
place so putting LANG back to what it was before seems like a reasonable
fix to me.
More here:
http://twiki.org/cgi-bin/view/Codev/UsingPerl58OnRedHat8
http://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=87682
- Perrin
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Mithun Bhattacharya <in...@yahoo.com>.
What exactly is broken in RedHat 8.0/9.0 - RedHat's build of perl,
perl's support for unicode or perl's support for locales ?
I dont think the LANG variable is wrong as such is it ?
I have to currently upgrade a couple of production servers running
mod_perl and I am finding it difficult to decide between choosing a
old/possible becoming unsupported but functional RedHat 7.3 and RedHat
9.0 with a possibly broken perl or some issues with perl 5.8 which I am
not able to comprehend.
Mithun
--- Perrin Harkins <pe...@elem.com> wrote:
> Just a thought: did you fix the locale on that machine? Most of CPAN
> won't compile on Red Hat 8 and 9 because of the broken UTF8 locale
> setting they have. If you haven't already, edit /etc/sysconfig/i18n
> and
> change LANG="en_US.UTF-8" to LANG="en_US.ISO8859-1". That fixed many
> mysterious things for me.
__________________________________
Do you Yahoo!?
Yahoo! Calendar - Free online calendar with sync to Outlook(TM).
http://calendar.yahoo.com
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Haroon Rafique <ha...@utoronto.ca>.
On Today at 12:38am, PH=>Perrin Harkins <pe...@elem.com> wrote:
PH> On Mon, 2003-06-09 at 09:55, Haroon Rafique wrote:
PH> > Now onto serious stuff. /usr/bin/perl here is the system-wide perl
PH> > install that came bundled with Redhat.
PH>
PH> Just a thought: did you fix the locale on that machine? Most of CPAN
PH> won't compile on Red Hat 8 and 9 because of the broken UTF8 locale
PH> setting they have. If you haven't already, edit /etc/sysconfig/i18n
PH> and change LANG="en_US.UTF-8" to LANG="en_US.ISO8859-1". That fixed
PH> many mysterious things for me.
PH>
PH> - Perrin
Hi Perrin,
I don't think locale is the issue here. I say that because by installing a
new perl in my home directory (I don't have root access to this machine,
just developer access), I'm able to install 1.99_10-dev and pass 100% of
the tests. I think the issue is that I asked the admin to install 1.99_08
a couple of months ago. Now 1.99_10-dev won't pass "make test" properly,
as we suspect, it is finding the older 1.99_08 mod_perl.
Just for completeness, I checked for the LANG variable,
env | grep LANG
LANG=en_US
so more than likely that is not the issue.
Stas suggested some steps to take in his latest reply. I will post my
findings as a reply to his email.
--
Haroon Rafique
<ha...@utoronto.ca>
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Perrin Harkins <pe...@elem.com>.
On Mon, 2003-06-09 at 09:55, Haroon Rafique wrote:
> Now onto serious stuff. /usr/bin/perl here is the system-wide perl install
> that came bundled with Redhat.
Just a thought: did you fix the locale on that machine? Most of CPAN
won't compile on Red Hat 8 and 9 because of the broken UTF8 locale
setting they have. If you haven't already, edit /etc/sysconfig/i18n and
change LANG="en_US.UTF-8" to LANG="en_US.ISO8859-1". That fixed many
mysterious things for me.
- Perrin
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Stas Bekman <st...@stason.org>.
Haroon Rafique wrote:
> On Today at 6:58pm, SB=>Stas Bekman <st...@stason.org> wrote:
>
> SB> please try this patch against the current cvs. I did some testing and
> SB> it seems to work. Test it on your old setup where you still have this
> SB> problem.
> SB>
> SB> [...patch snipped...]
> SB>
> SB>
>
> I applied your suggested patch to the 2 files and voila I have 100%
> success in both batches of tests. Just for completeness, I did a make
> clean afterwards and then with the same patched files, built again against
> my locally installed perl and it passed both batches of tests at a 100%
> success rate as well.
>
> Apache::Filter is now found at:
> /home/haroon/src/build/modperl-2.0/blib/lib/Apache/Filter.pm
Perfect. Thank you for testing my patch, Haroon. I'll apply it shortly.
__________________________________________________________________
Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org http://ticketmaster.com
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Haroon Rafique <ha...@utoronto.ca>.
On Today at 6:58pm, SB=>Stas Bekman <st...@stason.org> wrote:
SB> please try this patch against the current cvs. I did some testing and
SB> it seems to work. Test it on your old setup where you still have this
SB> problem.
SB>
SB> [...patch snipped...]
SB>
SB>
I applied your suggested patch to the 2 files and voila I have 100%
success in both batches of tests. Just for completeness, I did a make
clean afterwards and then with the same patched files, built again against
my locally installed perl and it passed both batches of tests at a 100%
success rate as well.
Apache::Filter is now found at:
/home/haroon/src/build/modperl-2.0/blib/lib/Apache/Filter.pm
--
Haroon Rafique
<ha...@utoronto.ca>
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Stas Bekman <st...@stason.org>.
Stas Bekman wrote:
> Haroon Rafique wrote:
>
>> On Today at 9:46am, SB=>Stas Bekman <st...@stason.org> wrote:
>>
>> SB> SB> Actually it was Sunday (future!) and it's winter (past?) here in
>> SB> Melbourne ;)
>>
>> I figured we were a few continents away.
>>
>> SB> SB> Then, if it's indeed your globally installed Apache::Filter
>> and not
>> SB> the local one, dump @INC (in the same place) to see whether the
>> global
>> SB> path comes before the local one.
>> SB>
>> Apache::Filter is indeed the globally installed one as evidenced by:
>>
>> Apache::Filter
>> /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi/Apache2/Apache/Filter.pm
>> at
>> /home/haroon/src/build/modperl-2.0/t/filter/TestFilter/in_init_basic.pm
>> line 15.
>>
>> Here's what @INC looks like:
>>
>> /home/haroon/src/build/modperl-2.0/Apache-Test/lib
>> /home/haroon/src/build/modperl-2.0/lib
>> /home/haroon/src/build/modperl-2.0/t/response
>> /home/haroon/src/build/modperl-2.0/t/protocol
>> /home/haroon/src/build/modperl-2.0/t/preconnection
>> /home/haroon/src/build/modperl-2.0/t/hooks
>> /home/haroon/src/build/modperl-2.0/t/filter
>> /home/haroon/src/build/modperl-2.0/t
>> /home/haroon/src/build/modperl-2.0/t/htdocs/testdirective/perlmodule-vh
>> /home/haroon/src/build/modperl-2.0/t/htdocs/testdirective/main
>> /home/haroon/src/build/modperl-2.0/t/
>> /home/haroon/src/build/modperl-2.0/t/lib/perl
>> /home/haroon/src/build/modperl-2.0/blib/lib
>> /home/haroon/src/build/modperl-2.0/blib/arch
>> Apache-Test/lib
>> /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi/Apache2
>> /usr/lib/perl5/5.8.0/i386-linux-thread-multi
>> /usr/lib/perl5/5.8.0
>> /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi
>> /usr/lib/perl5/site_perl/5.8.0
>> /usr/lib/perl5/site_perl/5.6.1
>> /usr/lib/perl5/site_perl
>> /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi
>> /usr/lib/perl5/vendor_perl/5.8.0
>> /usr/lib/perl5/vendor_perl at
>> /home/haroon/src/build/modperl-2.0/t/filter/TestFilter/in_init_basic.pm
>> line 16.
>>
>> I used the following diff to gather this diagnostic output:
>> ===================================================================
>> --- t/filter/TestFilter/in_init_basic.pm 9 May 2003 03:33:37
>> -0000 1.2
>> +++ t/filter/TestFilter/in_init_basic.pm 10 Jun 2003 14:46:33
>> -0000
>> @@ -11,6 +11,11 @@
>>
>> use base qw(Apache::Filter);
>>
>> +BEGIN {
>> + warn "Apache::Filter $INC{'Apache/Filter.pm'}";
>> + warn join "\n", @INC;
>> +}
>> +
>> use Apache::Const -compile => qw(OK M_POST);
>>
>> use constant READ_SIZE => 1024;
>>
>>
>> What's next to try?
>
>
> That now explains everything:
>
> > *** using lib/Apache/BuildConfig.pm
> > *** Makefile.PL options:
> > MP_AP_PREFIX => /servers/httpd-2.0.44-pl
> > MP_COMPAT_1X => 1
> > MP_GENERATE_XS => 1
> > MP_LIBNAME => mod_perl
> > MP_USE_DSO => 1
> > MP_USE_STATIC => 1
>
> previously you have built mod_perl with MP_INST_APACHE2=1, this time you
> did without, so the Apache2/ from the old install was getting into @INC
> first. Hence the local blib was going after the global
> .../i386-linux-thread-multi/Apache2/.
>
> How do we prevent this problem from re-curring is a question. Perhaps we
> should autogenerate Apache2.pm and make it:
>
> package Apache2;
>
> 1;
>
> in case, MP_INST_APACHE2=1 wasn't used.
please try this patch against the current cvs. I did some testing and it seems
to work. Test it on your old setup where you still have this problem.
Index: Makefile.PL
===================================================================
RCS file: /home/cvs/modperl-2.0/Makefile.PL,v
retrieving revision 1.104
diff -u -r1.104 Makefile.PL
--- Makefile.PL 23 Apr 2003 04:46:07 -0000 1.104
+++ Makefile.PL 12 Jun 2003 08:57:15 -0000
@@ -111,6 +111,8 @@
}
}
+ $build->generate_apache2_pm;
+
if (WIN32()) {
#Makefile.PL's in WrapXS/ just need to pass the -e mod_perl.lib test
#the real mod_perl.lib will be in place when WrapXS/ dll's are
Index: lib/Apache/Build.pm
===================================================================
RCS file: /home/cvs/modperl-2.0/lib/Apache/Build.pm,v
retrieving revision 1.125
diff -u -r1.125 Build.pm
--- lib/Apache/Build.pm 20 May 2003 23:52:42 -0000 1.125
+++ lib/Apache/Build.pm 12 Jun 2003 08:57:15 -0000
@@ -1366,6 +1366,37 @@
return "";
}
+# in case MP_INST_APACHE2=0 we shouldn't try to adjust @INC
+# because it may pick older Apache2 from the previous install
+sub generate_apache2_pm {
+ my $self = shift;
+
+ my $fixup = !$self->{MP_INST_APACHE2}
+ ? '# MP_INST_APACHE2=0, do nothing'
+ : <<'EOF';
+BEGIN {
+ my @dirs = ();
+
+ for my $path (@INC) {
+ my $dir = "$path/Apache2";
+ next unless -d $dir;
+ push @dirs, $dir;
+ }
+
+ if (@dirs) {
+ unshift @INC, @dirs;
+ }
+}
+EOF
+
+ my $content = join "\n\n", 'package Apache2;', $fixup, "1;";
+ my $file = catfile qw(lib Apache2.pm);
+ open my $fh, '>', $file or die "Can't open $file: $!";
+ print $fh $content;
+ close $fh;
+
+}
+
1;
__END__
__________________________________________________________________
Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org http://ticketmaster.com
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Stas Bekman <st...@stason.org>.
Haroon Rafique wrote:
> On Today at 9:46am, SB=>Stas Bekman <st...@stason.org> wrote:
>
> SB>
> SB> Actually it was Sunday (future!) and it's winter (past?) here in
> SB> Melbourne ;)
>
> I figured we were a few continents away.
>
> SB>
> SB> Then, if it's indeed your globally installed Apache::Filter and not
> SB> the local one, dump @INC (in the same place) to see whether the global
> SB> path comes before the local one.
> SB>
>
> Apache::Filter is indeed the globally installed one as evidenced by:
>
> Apache::Filter
> /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi/Apache2/Apache/Filter.pm
> at /home/haroon/src/build/modperl-2.0/t/filter/TestFilter/in_init_basic.pm
> line 15.
>
> Here's what @INC looks like:
>
> /home/haroon/src/build/modperl-2.0/Apache-Test/lib
> /home/haroon/src/build/modperl-2.0/lib
> /home/haroon/src/build/modperl-2.0/t/response
> /home/haroon/src/build/modperl-2.0/t/protocol
> /home/haroon/src/build/modperl-2.0/t/preconnection
> /home/haroon/src/build/modperl-2.0/t/hooks
> /home/haroon/src/build/modperl-2.0/t/filter
> /home/haroon/src/build/modperl-2.0/t
> /home/haroon/src/build/modperl-2.0/t/htdocs/testdirective/perlmodule-vh
> /home/haroon/src/build/modperl-2.0/t/htdocs/testdirective/main
> /home/haroon/src/build/modperl-2.0/t/
> /home/haroon/src/build/modperl-2.0/t/lib/perl
> /home/haroon/src/build/modperl-2.0/blib/lib
> /home/haroon/src/build/modperl-2.0/blib/arch
> Apache-Test/lib
> /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi/Apache2
> /usr/lib/perl5/5.8.0/i386-linux-thread-multi
> /usr/lib/perl5/5.8.0
> /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi
> /usr/lib/perl5/site_perl/5.8.0
> /usr/lib/perl5/site_perl/5.6.1
> /usr/lib/perl5/site_perl
> /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi
> /usr/lib/perl5/vendor_perl/5.8.0
> /usr/lib/perl5/vendor_perl at
> /home/haroon/src/build/modperl-2.0/t/filter/TestFilter/in_init_basic.pm
> line 16.
>
> I used the following diff to gather this diagnostic output:
> ===================================================================
> --- t/filter/TestFilter/in_init_basic.pm 9 May 2003 03:33:37 -0000
> 1.2
> +++ t/filter/TestFilter/in_init_basic.pm 10 Jun 2003 14:46:33 -0000
> @@ -11,6 +11,11 @@
>
> use base qw(Apache::Filter);
>
> +BEGIN {
> + warn "Apache::Filter $INC{'Apache/Filter.pm'}";
> + warn join "\n", @INC;
> +}
> +
> use Apache::Const -compile => qw(OK M_POST);
>
> use constant READ_SIZE => 1024;
>
>
> What's next to try?
That now explains everything:
> *** using lib/Apache/BuildConfig.pm
> *** Makefile.PL options:
> MP_AP_PREFIX => /servers/httpd-2.0.44-pl
> MP_COMPAT_1X => 1
> MP_GENERATE_XS => 1
> MP_LIBNAME => mod_perl
> MP_USE_DSO => 1
> MP_USE_STATIC => 1
previously you have built mod_perl with MP_INST_APACHE2=1, this time you did
without, so the Apache2/ from the old install was getting into @INC first.
Hence the local blib was going after the global
.../i386-linux-thread-multi/Apache2/.
How do we prevent this problem from re-curring is a question. Perhaps we
should autogenerate Apache2.pm and make it:
package Apache2;
1;
in case, MP_INST_APACHE2=1 wasn't used.
__________________________________________________________________
Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org http://ticketmaster.com
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Haroon Rafique <ha...@utoronto.ca>.
On Today at 9:46am, SB=>Stas Bekman <st...@stason.org> wrote:
SB>
SB> Actually it was Sunday (future!) and it's winter (past?) here in
SB> Melbourne ;)
I figured we were a few continents away.
SB>
SB> Then, if it's indeed your globally installed Apache::Filter and not
SB> the local one, dump @INC (in the same place) to see whether the global
SB> path comes before the local one.
SB>
Apache::Filter is indeed the globally installed one as evidenced by:
Apache::Filter
/usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi/Apache2/Apache/Filter.pm
at /home/haroon/src/build/modperl-2.0/t/filter/TestFilter/in_init_basic.pm
line 15.
Here's what @INC looks like:
/home/haroon/src/build/modperl-2.0/Apache-Test/lib
/home/haroon/src/build/modperl-2.0/lib
/home/haroon/src/build/modperl-2.0/t/response
/home/haroon/src/build/modperl-2.0/t/protocol
/home/haroon/src/build/modperl-2.0/t/preconnection
/home/haroon/src/build/modperl-2.0/t/hooks
/home/haroon/src/build/modperl-2.0/t/filter
/home/haroon/src/build/modperl-2.0/t
/home/haroon/src/build/modperl-2.0/t/htdocs/testdirective/perlmodule-vh
/home/haroon/src/build/modperl-2.0/t/htdocs/testdirective/main
/home/haroon/src/build/modperl-2.0/t/
/home/haroon/src/build/modperl-2.0/t/lib/perl
/home/haroon/src/build/modperl-2.0/blib/lib
/home/haroon/src/build/modperl-2.0/blib/arch
Apache-Test/lib
/usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi/Apache2
/usr/lib/perl5/5.8.0/i386-linux-thread-multi
/usr/lib/perl5/5.8.0
/usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.0
/usr/lib/perl5/site_perl/5.6.1
/usr/lib/perl5/site_perl
/usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi
/usr/lib/perl5/vendor_perl/5.8.0
/usr/lib/perl5/vendor_perl at
/home/haroon/src/build/modperl-2.0/t/filter/TestFilter/in_init_basic.pm
line 16.
I used the following diff to gather this diagnostic output:
===================================================================
--- t/filter/TestFilter/in_init_basic.pm 9 May 2003 03:33:37 -0000
1.2
+++ t/filter/TestFilter/in_init_basic.pm 10 Jun 2003 14:46:33 -0000
@@ -11,6 +11,11 @@
use base qw(Apache::Filter);
+BEGIN {
+ warn "Apache::Filter $INC{'Apache/Filter.pm'}";
+ warn join "\n", @INC;
+}
+
use Apache::Const -compile => qw(OK M_POST);
use constant READ_SIZE => 1024;
What's next to try?
--
Haroon Rafique
<ha...@utoronto.ca>
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Stas Bekman <st...@stason.org>.
Haroon Rafique wrote:
> On Saturday at 9:22am, SB=>Stas Bekman <st...@stason.org> wrote:
>
> SB> I think the issue is very simple: @INC had system libraries dirs
> SB> before the freshly build ones, so dumping @INC contents prior to libs
> SB> loading should aid the debug. But please use the latest cvs, since
> SB> I've messed with @INC a bit recently.
> SB>
> SB> In parallel, we are planning to verify .so objects that they were
> SB> created by the same mod_perl.so to avoid completely this kind of
> SB> problems. Well it won't prevent the pickup of wrong libraries, it'll
> SB> just scream aloud when this will happen. So your debug is still very
> SB> important.
> SB>
>
> Seeing that you were answering emails even on a Saturday, I feel guilty
> about taking that out of town trip yesterday. Oh well! I think we should
> be able to enjoy the little bit of summer that we get here in Canada to
> the fullest.
Actually it was Sunday (future!) and it's winter (past?) here in Melbourne ;)
> Now onto serious stuff. /usr/bin/perl here is the system-wide perl install
> that came bundled with Redhat.
>
> /usr/bin/perl -MApache2 -Mmod_perl -le 'print mod_perl->VERSION'
> 1.9908
>
> I posted t/REPORT output in the beginning of the thread and can
> repost upon request.
no need to
> I did a cvs up, and issued:
>
> * /usr/bin/perl Makefile.PL MP_AP_PREFIX=/servers/httpd-2.0.44-pl
> * make
> * make test
>
> and was greeted by the now familiar output (same as originally reported)
>
> /usr/bin/perl -Iblib/arch -Iblib/lib \
> t/TEST -clean
> *** setting ulimit to allow core files
> ulimit -c unlimited; t/TEST -clean
> sh: line 1: ulimit: core file size: cannot modify limit: Operation not
> permitted
> APACHE_USER= APACHE_GROUP= APACHE_PORT= APACHE= APXS= \
> /usr/bin/perl -Iblib/arch -Iblib/lib \
> t/TEST -verbose=0
> *** setting ulimit to allow core files
> ulimit -c unlimited; t/TEST -verbose=0
> sh: line 1: ulimit: core file size: cannot modify limit: Operation not
> permitted
> /servers/httpd-2.0.44-pl/bin/httpd -d
> /home/haroon/src/build/modperl-2.0/t -f
> /home/haroon/src/build/modperl-2.0/t/conf/httpd.conf -DAPACHE2
> -DPERL_USEITHREADS
> using Apache/2.0.44 (prefork MPM)
>
> waiting for server to start: ..[Mon Jun 09 09:38:20 2003] [info] 22
> Apache:: modules loaded
> [Mon Jun 09 09:38:20 2003] [info] 5 APR:: modules loaded
> [Mon Jun 09 09:38:20 2003] [info] base server + 9 vhosts ready to run
> tests
> [Mon Jun 09 09:38:20 2003] [error] Invalid CODE attribute:
> TestFilter::in_init_basic at
> /home/haroon/src/build/modperl-2.0/t/filter/TestFilter/in_init_basic.pm
> line 30
> BEGIN failed--compilation aborted at
> /home/haroon/src/build/modperl-2.0/t/filter/TestFilter/in_init_basic.pm
> line 30.
> Compilation failed in require at (eval 35) line 3.
>
> [Mon Jun 09 09:38:20 2003] [error] Can't load Perl module
> TestFilter::in_init_basic for server localhost.localdomain:8529,
> exiting...
>
> !!!
> server has died with status 255 (t/logs/error_log wasn't created, start
> the server in the debug mode)
> make: *** [run_tests] Error 143
Well, nothing has changed, hasn't it? Now try to figure out which .so gets
loaded and why it is not the locally built one. The module in question is
Apache::Filter
For example change TestFilter/in_init_basic.pm to dump the location of the
Apache::Filter library.
Index: t/filter/TestFilter/in_init_basic.pm
===================================================================
RCS file: /home/cvs/modperl-2.0/t/filter/TestFilter/in_init_basic.pm,v
retrieving revision 1.2
diff -u -r1.2 in_init_basic.pm
--- t/filter/TestFilter/in_init_basic.pm 9 May 2003 03:33:37 -0000 1.2
+++ t/filter/TestFilter/in_init_basic.pm 9 Jun 2003 23:45:58 -0000
@@ -11,6 +11,8 @@
use base qw(Apache::Filter);
+BEGIN { warn "Apache::Filter $INC{'Apache/Filter.pm'}" }
+
use Apache::Const -compile => qw(OK M_POST);
use constant READ_SIZE => 1024;
Then, if it's indeed your globally installed Apache::Filter and not the local
one, dump @INC (in the same place) to see whether the global path comes before
the local one.
__________________________________________________________________
Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org http://ticketmaster.com
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Haroon Rafique <ha...@utoronto.ca>.
On Saturday at 9:22am, SB=>Stas Bekman <st...@stason.org> wrote:
SB> I think the issue is very simple: @INC had system libraries dirs
SB> before the freshly build ones, so dumping @INC contents prior to libs
SB> loading should aid the debug. But please use the latest cvs, since
SB> I've messed with @INC a bit recently.
SB>
SB> In parallel, we are planning to verify .so objects that they were
SB> created by the same mod_perl.so to avoid completely this kind of
SB> problems. Well it won't prevent the pickup of wrong libraries, it'll
SB> just scream aloud when this will happen. So your debug is still very
SB> important.
SB>
Seeing that you were answering emails even on a Saturday, I feel guilty
about taking that out of town trip yesterday. Oh well! I think we should
be able to enjoy the little bit of summer that we get here in Canada to
the fullest.
Now onto serious stuff. /usr/bin/perl here is the system-wide perl install
that came bundled with Redhat.
/usr/bin/perl -MApache2 -Mmod_perl -le 'print mod_perl->VERSION'
1.9908
I posted t/REPORT output in the beginning of the thread and can
repost upon request.
I did a cvs up, and issued:
* /usr/bin/perl Makefile.PL MP_AP_PREFIX=/servers/httpd-2.0.44-pl
* make
* make test
and was greeted by the now familiar output (same as originally reported)
/usr/bin/perl -Iblib/arch -Iblib/lib \
t/TEST -clean
*** setting ulimit to allow core files
ulimit -c unlimited; t/TEST -clean
sh: line 1: ulimit: core file size: cannot modify limit: Operation not
permitted
APACHE_USER= APACHE_GROUP= APACHE_PORT= APACHE= APXS= \
/usr/bin/perl -Iblib/arch -Iblib/lib \
t/TEST -verbose=0
*** setting ulimit to allow core files
ulimit -c unlimited; t/TEST -verbose=0
sh: line 1: ulimit: core file size: cannot modify limit: Operation not
permitted
/servers/httpd-2.0.44-pl/bin/httpd -d
/home/haroon/src/build/modperl-2.0/t -f
/home/haroon/src/build/modperl-2.0/t/conf/httpd.conf -DAPACHE2
-DPERL_USEITHREADS
using Apache/2.0.44 (prefork MPM)
waiting for server to start: ..[Mon Jun 09 09:38:20 2003] [info] 22
Apache:: modules loaded
[Mon Jun 09 09:38:20 2003] [info] 5 APR:: modules loaded
[Mon Jun 09 09:38:20 2003] [info] base server + 9 vhosts ready to run
tests
[Mon Jun 09 09:38:20 2003] [error] Invalid CODE attribute:
TestFilter::in_init_basic at
/home/haroon/src/build/modperl-2.0/t/filter/TestFilter/in_init_basic.pm
line 30
BEGIN failed--compilation aborted at
/home/haroon/src/build/modperl-2.0/t/filter/TestFilter/in_init_basic.pm
line 30.
Compilation failed in require at (eval 35) line 3.
[Mon Jun 09 09:38:20 2003] [error] Can't load Perl module
TestFilter::in_init_basic for server localhost.localdomain:8529,
exiting...
!!!
server has died with status 255 (t/logs/error_log wasn't created, start
the server in the debug mode)
make: *** [run_tests] Error 143
Thanks,
--
Haroon Rafique
<ha...@utoronto.ca>
Re: [mp2] make test fails with 1.99_10-dev sources on redhat
Posted by Stas Bekman <st...@stason.org>.
Haroon Rafique wrote:
> On Today at 11:32am, SB=>Stas Bekman <st...@stason.org> wrote:
>
> SB>
> SB> Both failed due to the missing LWP. I was able to reproduce the exact
> SB> problem by removing LWP/UserAgent.pm. I have now fixed both in cvs.
> SB> Please 'cvs up' and test again. Thanks.
> SB>
>
> after cvs up, "make test" skipped a bunch of tests in both the first batch
> and the 2nd batch (since libwww-perl was not installed). 100% successful.
>
> After that, I installed:
> libwww-perl-5.69
> CGI.pm-2.93
> HTML-Parser-3.28
> URI-1.23
> to satisfy all dependencies for installing libwww-perl
>
> The tests, that were skipped last time around, ran successfully this time.
> 100%.
Fantastic, thanks!
> Now onto investigating my originally reported problem as to why the older,
> system-wide installation is interfering with the "make test". Any
> suggestions on how to get started on that?
I think the issue is very simple: @INC had system libraries dirs before the
freshly build ones, so dumping @INC contents prior to libs loading should aid
the debug. But please use the latest cvs, since I've messed with @INC a bit
recently.
In parallel, we are planning to verify .so objects that they were created by
the same mod_perl.so to avoid completely this kind of problems. Well it won't
prevent the pickup of wrong libraries, it'll just scream aloud when this will
happen. So your debug is still very important.
__________________________________________________________________
Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org http://ticketmaster.com