Skip to content

re/regexp.t failures on ubuntu 11.04 #11667

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
p5pRT opened this issue Sep 25, 2011 · 5 comments
Closed

re/regexp.t failures on ubuntu 11.04 #11667

p5pRT opened this issue Sep 25, 2011 · 5 comments

Comments

@p5pRT
Copy link

p5pRT commented Sep 25, 2011

Migrated from rt.perl.org#99972 (status was 'resolved')

Searchable as RT99972$

@p5pRT
Copy link
Author

p5pRT commented Sep 25, 2011

From [email protected]

Created by [email protected]

I upgraded my ubuntu to 11.04 and started have compilation
and test failures. With the supplied gcc-4.5.2 I reduced
the problems to re/regexp failures.

Failed 6 tests out of 2044, 99.71% okay.
  re/regexp.t
  re/regexp_noamp.t
  re/regexp_notrie.t
  re/regexp_qr.t
  re/regexp_qr_embed.t
  re/regexp_trielist.t

This is the same test failure​: each regexp_*.t test calls regexp.t

The tests pass with C<(cd t; ./perl harness re/*.t) but

./perl -Ilib t/re/regexp.t
# RT #89774
not ok 1539 # TODO () /s\xDF/ui​:\xDFs​:yT​:$&​:\xDFs => `T', match=
$subject = "\337s";

$got = "T";

  ;
  $match = ($subject =~ m/s\xDF/ui) while $c--;
  $got = "$&amp;";

Before upgrading to ubuntu 11.04, I had no test failues, using gcc-4.6.0
After upgrading, gcc-4.6.0 would not compile perl​: missing asm/errno.h

I tried upgrading to gcc-4.6.1 but it would not compile.
I put in a symlink from /usr/include/asm
and was able to build gcc-4.6.1 and to build perl,
but again I got the above test failure with perl.

Perl Info

Flags:
    category=core
    severity=medium

Site configuration information for perl 5.15.3:

Configured by robin at Sun Sep 25 17:39:55 BST 2011.

Summary of my perl5 (revision 5 version 15 subversion 3) configuration:
  Commit id: 9c8c35062b12e41237396ffd50b944586cbce3bf
  Platform:
    osname=linux, osvers=2.6.38-11-generic, archname=i686-linux-64int
    uname='linux spade-ubuntu 2.6.38-11-generic #50-ubuntu smp mon sep
12 21:18:14 utc 2011 i686 i686 i386 gnulinux '
    config_args='-des -Dcc=/usr/bin/gcc -Dusedevel -Doptimize=-O2
-DDEBUGGING -Duse64bitint'
    hint=recommended, useposix=true, d_sigaction=define
    useithreads=undef, usemultiplicity=undef
    useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef
    use64bitint=define, use64bitall=undef, uselongdouble=undef
    usemymalloc=n, bincompat5005=undef
  Compiler:
    cc='/usr/bin/gcc', ccflags ='-DDEBUGGING -fno-strict-aliasing -pipe
-fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64',
    optimize='-O2 -g',
    cppflags='-DDEBUGGING -fno-strict-aliasing -pipe -fstack-protector
-I/usr/local/include'
    ccversion='', gccversion='4.5.2', gccosandvers=''
    intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=12345678
    d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12
    ivtype='long long', ivsize=8, nvtype='double', nvsize=8,
Off_t='off_t', lseeksize=8
    alignbytes=4, prototype=define
  Linker and Libraries:
    ld='/usr/bin/gcc', ldflags =' -fstack-protector -L/usr/local/lib'

libpth=/usr/local/lib /lib /usr/lib /usr/lib/i386-linux-gnu /usr/lib64
    libs=-lnsl -ldl -lm -lcrypt -lutil -lc
    perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc
    libc=, so=so, useshrplib=false, libperl=libperl.a
    gnulibc_version='2.13'
  Dynamic Linking:
    dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E'
    cccdlflags='-fPIC', lddlflags='-shared -O2 -g -L/usr/local/lib
-fstack-protector'

Locally applied patches:
    


@INC for perl 5.15.3:
    lib
    /usr/local/lib/perl5/site_perl/5.15.3/i686-linux-64int
    /usr/local/lib/perl5/site_perl/5.15.3
    /usr/local/lib/perl5/5.15.3/i686-linux-64int
    /usr/local/lib/perl5/5.15.3
    /usr/local/lib/perl5/site_perl
    .


Environment for perl 5.15.3:
    HOME=/home/robin
    LANG=en_GB.UTF-8
    LANGUAGE=en_GB:en
    LD_LIBRARY_PATH=/usr/lib:/usr/local/lib
    LOGDIR (unset)

PATH=/home/robin/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
    PERL_BADLANG (unset)
    SHELL=/bin/tcsh


@p5pRT
Copy link
Author

p5pRT commented Sep 26, 2011

From @cpansprout

On Sun Sep 25 15​:34​:33 2011, rmbarker.cpan@​btinternet.com wrote​:

This is a bug report for perl from rmbarker@​cpan.org,
generated with the help of perlbug 1.39 running under perl 5.15.3.

-----------------------------------------------------------------
[Please describe your issue here]

I upgraded my ubuntu to 11.04 and started have compilation
and test failures. With the supplied gcc-4.5.2 I reduced
the problems to re/regexp failures.

Failed 6 tests out of 2044, 99.71% okay.
re/regexp.t
re/regexp_noamp.t
re/regexp_notrie.t
re/regexp_qr.t
re/regexp_qr_embed.t
re/regexp_trielist.t

I believe this has just been fixed with this commit​:
http​://perl5.git.perl.org/perl.git/commitdiff/1b7228c9af6

If that is not the case, please holler and I will re-open the ticket.

This is the same test failure​: each regexp_*.t test calls regexp.t

The tests pass with C<(cd t; ./perl harness re/*.t) but

./perl -Ilib t/re/regexp.t
# RT #89774
not ok 1539 # TODO () /s\xDF/ui​:\xDFs​:yT​:$&​:\xDFs => `T', match=
$subject = "\337s";

$got = "T";

            ;
            $match = \($subject =~ m/s\\xDF/ui\) while $c\-\-;
            $got = "$&";

Before upgrading to ubuntu 11.04, I had no test failues, using gcc-
4.6.0
After upgrading, gcc-4.6.0 would not compile perl​: missing asm/errno.h

I tried upgrading to gcc-4.6.1 but it would not compile.
I put in a symlink from /usr/include/asm
and was able to build gcc-4.6.1 and to build perl,
but again I got the above test failure with perl.

[Please do not change anything below this line]
-----------------------------------------------------------------
---
Flags​:
category=core
severity=medium
---
Site configuration information for perl 5.15.3​:

Configured by robin at Sun Sep 25 17​:39​:55 BST 2011.

Summary of my perl5 (revision 5 version 15 subversion 3)
configuration​:
Commit id​: 9c8c35062b12e41237396ffd50b944586cbce3bf
Platform​:
osname=linux, osvers=2.6.38-11-generic, archname=i686-linux-64int
uname='linux spade-ubuntu 2.6.38-11-generic #50-ubuntu smp mon sep
12 21​:18​:14 utc 2011 i686 i686 i386 gnulinux '
config_args='-des -Dcc=/usr/bin/gcc -Dusedevel -Doptimize=-O2
-DDEBUGGING -Duse64bitint'
hint=recommended, useposix=true, d_sigaction=define
useithreads=undef, usemultiplicity=undef
useperlio=define, d_sfio=undef, uselargefiles=define,
usesocks=undef
use64bitint=define, use64bitall=undef, uselongdouble=undef
usemymalloc=n, bincompat5005=undef
Compiler​:
cc='/usr/bin/gcc', ccflags ='-DDEBUGGING -fno-strict-aliasing
-pipe
-fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64',
optimize='-O2 -g',
cppflags='-DDEBUGGING -fno-strict-aliasing -pipe -fstack-protector
-I/usr/local/include'
ccversion='', gccversion='4.5.2', gccosandvers=''
intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=12345678
d_longlong=define, longlongsize=8, d_longdbl=define,
longdblsize=12
ivtype='long long', ivsize=8, nvtype='double', nvsize=8,
Off_t='off_t', lseeksize=8
alignbytes=4, prototype=define
Linker and Libraries​:
ld='/usr/bin/gcc', ldflags =' -fstack-protector -L/usr/local/lib'

libpth=/usr/local/lib /lib /usr/lib /usr/lib/i386-linux-gnu /usr/lib64
libs=-lnsl -ldl -lm -lcrypt -lutil -lc
perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc
libc=, so=so, useshrplib=false, libperl=libperl.a
gnulibc_version='2.13'
Dynamic Linking​:
dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E'
cccdlflags='-fPIC', lddlflags='-shared -O2 -g -L/usr/local/lib
-fstack-protector'

Locally applied patches​:

---
@​INC for perl 5.15.3​:
lib
/usr/local/lib/perl5/site_perl/5.15.3/i686-linux-64int
/usr/local/lib/perl5/site_perl/5.15.3
/usr/local/lib/perl5/5.15.3/i686-linux-64int
/usr/local/lib/perl5/5.15.3
/usr/local/lib/perl5/site_perl
.

---
Environment for perl 5.15.3​:
HOME=/home/robin
LANG=en_GB.UTF-8
LANGUAGE=en_GB​:en
LD_LIBRARY_PATH=/usr/lib​:/usr/local/lib
LOGDIR (unset)

PATH=/home/robin/bin​:/usr/local/sbin​:/usr/local/bin​:/usr/sbin​:/usr/bin​:/sbin​:/bin​:/usr/games

PERL\_BADLANG \(unset\)
SHELL=/bin/tcsh

@p5pRT
Copy link
Author

p5pRT commented Sep 26, 2011

The RT System itself - Status changed from 'new' to 'open'

@p5pRT
Copy link
Author

p5pRT commented Sep 26, 2011

@cpansprout - Status changed from 'open' to 'resolved'

@p5pRT p5pRT closed this as completed Sep 26, 2011
@p5pRT
Copy link
Author

p5pRT commented Sep 28, 2011

From @nwc10

On Sun, Sep 25, 2011 at 03​:34​:34PM -0700, Robin Barker wrote​:

-----------------------------------------------------------------
[Please describe your issue here]

I upgraded my ubuntu to 11.04 and started have compilation
and test failures. With the supplied gcc-4.5.2 I reduced
the problems to re/regexp failures.

Failed 6 tests out of 2044, 99.71% okay.
re/regexp.t
re/regexp_noamp.t
re/regexp_notrie.t
re/regexp_qr.t
re/regexp_qr_embed.t
re/regexp_trielist.t

This is the same test failure​: each regexp_*.t test calls regexp.t

The tests pass with C<(cd t; ./perl harness re/*.t) but

./perl -Ilib t/re/regexp.t
# RT #89774
not ok 1539 # TODO () /s\xDF/ui​:\xDFs​:yT​:$&​:\xDFs => `T', match=
$subject = "\337s";

$got = "T";

            ;
            $match = \($subject =~ m/s\\xDF/ui\) while $c\-\-;
            $got = "$&";

Before upgrading to ubuntu 11.04, I had no test failues, using gcc-4.6.0
After upgrading, gcc-4.6.0 would not compile perl​: missing asm/errno.h

Summary of my perl5 (revision 5 version 15 subversion 3) configuration​:
Commit id​: 9c8c35062b12e41237396ffd50b944586cbce3bf

I can't work out what version this actually is.

$ git show 9c8c35062b12e41237396ffd50b944586cbce3bf
fatal​: bad object 9c8c35062b12e41237396ffd50b944586cbce3bf

The above description looks suspiciously like the problem solved by
Karl Williamson in​:

commit 1b7228c
Author​: Karl Williamson <public@​khwilliamson.com>
Date​: Thu Sep 22 17​:34​:35 2011 -0600

  regexp.t​: print diagnostics with leading '#'
 
  Some test platforms don't like unexpected output without the comment
  prefix character

Inline Patch
diff --git a/t/re/regexp.t b/t/re/regexp.t
index 9c430ad..815b877 100644
--- a/t/re/regexp.t
+++ b/t/re/regexp.t
@@ -59,6 +59,11 @@ BEGIN {
 
 }
 
+sub _comment {
+    return map { /^#/ ? "$_\n" : "# $_\n" }
+           map { split /\n/ } @_;
+}
+
 use strict;
 use warnings FATAL=>"all";
 use vars qw($iters $numtests $bang $ffff $nulnul $OP);
@@ -175,7 +180,7 @@ EOFCODE
 	    next TEST;
 	}
 	elsif ($@) {
-	    print "not ok $test$todo $input => error `$err'\n$code\n$@\n"; next TEST;
+	    print "not ok $test$todo $input => error `$err'\n", _comment("$code\n$@\n"); next TEST;
 	}
 	elsif ($result =~ /^n/) {
 	    if ($match) { print "not ok $test$todo ($study) $input => false positive\n"; next TEST }
@@ -184,12 +189,12 @@ EOFCODE
 	    if (!$match || $got ne $expect) {
 	        eval { require Data::Dumper };
 		if ($@) {
-		    print "not ok $test$todo ($study) $input => `$got', match=$match\n$code\n";
+		    print "not ok $test$todo ($study) $input => `$got', match=$match\n", _comment("$code\n");
 		}
 		else { # better diagnostics
 		    my $s = Data::Dumper->new([$subject],['subject'])->Useqq(1)->Dump;
 		    my $g = Data::Dumper->new([$got],['got'])->Useqq(1)->Dump;
-		    print "not ok $test$todo ($study) $input => `$got', match=$match\n$s\n$g\n$code\n";
+		    print "not ok $test$todo ($study) $input => `$got', match=$match\n", _comment("$s\n$g\n$code\n");
 		}
 		next TEST;
 	    }



But I'm confused as that was 3 days before the date of your bug report.

Nicholas Clark

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant