Hello Ellies,

yes, downloading 
https://cpan.metacpan.org/authors/id/M/MC/MCAST/Test-Unit-0.25.tar.gz , 
unpacking, applying the patches from 
https://sources.debian.org/patches/libtest-unit-perl/0.25-7/ , «perl 
Makefile.PL» , «make install», and eventually running  «make -Ccassandane», 
made all the tests pass.

Greetings
  Дилян

-----Original Message-----
From: ellie timoney <el...@fastmail.com>
Reply-To: Devel <devel@cyrus.topicbox.com>
To: Cyrus Developers (Public List) <devel@cyrus.topicbox.com>
Subject: Re: Does Cassandane run with Perl 5.38.2?
Date: 04/03/2024 01:36:21 AM

Hi Дилян ,

Apparently, support for "defined(@array)" was removed from perl way back in 
2015...

Turns out the reason Test::Unit has been continuing to work all this time for 
us with recent perls (I have 5.36.0) is because we've been using the Debian 
libtest-unit-perl package rather than getting it direct from CPAN, and Debian 
have been patching it to keep it working -- 
https://sources.debian.org/patches/libtest-unit-perl/0.25-7/

I imagine other distros have probably been doing the same, so you might be able 
to get Test::Unit working if you install it from a distro package rather than 
CPAN.  If your distro doesn't have a package for it, you might be able to 
manually apply Debian's patches to the CPAN sources.

Cheers,

ellie

On Wed, 3 Apr 2024, at 6:34 AM, Дилян Палаузов wrote:
> Hello Ellie,
> 
> > Did you upgrade to perl 5.38.2 yourself, or is it being shipped by one of 
> > the distros these days?
> 
> I upgraded myself.
> 
> Greetings
>   Дилян
> 
> -----Original Message-----
> From: ellie timoney <el...@fastmail.com>
> Reply-To: Devel <devel@cyrus.topicbox.com>
> To: cyrus devel <devel@cyrus.topicbox.com>
> Subject: Re: Does Cassandane run with Perl 5.38.2?
> Date: 04/01/2024 11:49:49 PM
> 
> On Mon, 1 Apr 2024, at 10:49 PM, Дилян Палаузов wrote:
> > t/all_tests.t ..... Can't use 'defined(@array)' (Maybe you should just 
> > omit the defined()?) at /root/.cpan/build/Test-Unit-0.25-2/blib/l
> > ib/Test/Unit/TestCase.pm line 106.                                      
> >                                                                 
> > Compilation failed in require at 
> > /root/.cpan/build/Test-Unit-0.25-2/blib/lib/Test/Unit/TestSuite.pm line 
> > 15.                            
> > BEGIN failed--compilation aborted at 
> > /root/.cpan/build/Test-Unit-0.25-2/blib/lib/Test/Unit/TestSuite.pm line 
> > 15.                        
> > 
> > [...]
> > 
> > Test-Unit-0.25 was released in 2005. Is the problem that I am using too 
> > new version of Perl, and for this reason I cannot install 
> > Test-Unit-0.25, or I do not need Test::Unit::TestRunner (to solve the 
> > base empty package), or is it something different?
> 
> That looks to me like Test::Unit's own test suite is using an old
> experimental perl feature that I guess 5.38.2 no longer supports
> ("defined(@array)"), and since its tests can't be run, cpan won't
> install it.
> 
> I think cpan has an argument to bypass the testing, so you might be
> able to use that to get it installed.  Though if the tests use that
> feature, the library itself probably does too, in which case it won't
> work even if it does install okay.
> 
> Interesting problem...  we might need to package up our own version of
> Test::Unit that fixes it to not use language features that don't exist
> anymore.  I don't see us being able to remove it from Cassandane easily.
> 
> Did you upgrade to perl 5.38.2 yourself, or is it being shipped by one
> of the distros these days?
> 
> Cheers,
> 
> ellie
> 

------------------------------------------
Cyrus: Devel
Permalink: 
https://cyrus.topicbox.com/groups/devel/T5ac61e0683eda69a-M1d3d023c39e843c16b842e09
Delivery options: https://cyrus.topicbox.com/groups/devel/subscription

Reply via email to