build issue: manual build works; dpkg-buildpackage doesn't
Hi,
I'm trying to build the latest version of XML::LibXML from CVS, but it
won't pass the tests. At least, that depends on how I ran them:
- perl Mekefile.PL; make; make test = no problem
- fakeroot debian/rules clean; debian/rules build = again no problem
- fakeroot dpkg-buildpackage = still no problem
- sudo dpkg-buildpackage = again still no problem
but
- dpkg-buildpackage -rfakeroot = t/13dtd fails
- dpkg-buildpackage -rsudo = t/13dtd still fails
- cvs-buildpackage = t/13dtd fails some more
In this particular test the following happens:
use Test;
BEGIN { plan tests => 17 }
use XML::LibXML;
ok(1);
my $dtdstr;
{
local $/; local *DTD;
open(DTD, 'example/test.dtd') || die $!;
$dtdstr = <DTD>;
$dtdstr =~ s/\r//g;
$dtdstr =~ s/[\r\n]*$//;
close DTD;
}
ok($dtdstr);
{
# parse a DTD from a SYSTEM ID
my $dtd = XML::LibXML::Dtd->new('ignore', 'example/test.dtd');
ok($dtd);
my $newstr = $dtd->toString;
$newstr =~ s/\r//g;
$newstr =~ s/^.*?\n//;
$newstr =~ s/\n^.*\Z//m;
ok($newstr, $dtdstr);
}
The last 'ok' doesn't pass unless ran manually. Using dpkg-buildpackage
it simply doesn't want to work (and then the remaining 14 tests also fail).
The tests are run as follows:
PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
The package also has a separate test script (tester.sh) and if I run
./tester.sh 13dtd
it also fails. The script is
#! /bin/sh
make
MEMORY_TEST=1 \
PERL_DL_NONLAZY=1 \
/usr/bin/perl \
-Iblib/arch \
-Iblib/lib \
-e 'use Test::Harness qw(&runtests $verbose); $verbose=1; runtests @ARGV;' \
t/$1*.t
Note that I'm running this in a chroot environment (I've got several of these
for the different type of packages I maintain and have had no problem so far).
Also in a pbuilder it fails (which is also a chroot environment).
I've no idea what's going on here, nor where to look for a possible solution.
Any help in solving this mystery is really appreciated.
Thanks,
Ardo
--
Ardo van Rangelrooij
home email: ardo@debian.org
home page: http://people.debian.org/~ardo
GnuPG fp: 3B 1F 21 72 00 5C 3A 73 7F 72 DF D9 90 78 47 F9
Reply to: