Item13403: no copytree() method in debian package or tarball
Priority: Normal
Current State: Closed
Released In: 2.0.0
Target Release: minor
Applies To: Engine
Component: Configure
Branches:
--
VMcIntyre - 14 May 2015
I installed foswiki-1.1.9 from your debian repository.
When I run localhost/foswiki/bin/configure I am rewarded with this error message.
Can't locate object method "copytree" via package "Foswiki::Configure::Checkers::WorkingDir" at /var/lib/foswiki/lib/Foswiki/Configure/Checkers/WorkingDir.pm line 78.
This is because there is no file that implements copytree().
% grep -rci copytree /var/lib/foswiki |grep -v :0$
/var/lib/foswiki/lib/Foswiki/Configure/Checkers/WorkingDir.pm:1
The same goes for the tarball which I downloaded from the link to sourceforge on your packages page.
It's not provided by Perl's File::Util.
I got things unstuck again by getting the file from git
$ git clone https://github.com/foswiki/distro.git; cd distro
$ cp core/lib/Foswiki/Configure/FileUtil.pm /var/lib/foswiki/lib/Foswiki/Configure/FileUtil.pm
# vi var/lib/foswiki/lib/Foswiki/Configure/Checkers/WorkingDir.pm
The patch I made was;
--- /var/lib/foswiki/lib/Foswiki/Configure/Checkers/WorkingDir.pm.orig 2015-05-14 10:50:18.000000000 +1000
+++ /var/lib/foswiki/lib/Foswiki/Configure/Checkers/WorkingDir.pm 2015-05-14 10:49:05.000000000 +1000
@@ -5,6 +5,7 @@
use warnings;
use Foswiki::Configure::Checker ();
+use Foswiki::Configure::Checker::FileUtil ();
our @ISA = ('Foswiki::Configure::Checker');
sub untaint {
--
VMcIntyre - 14 May 2015
Wow, That's been broken since 1.1.0, it appears some cleanup early in 1.1 removed that routine from
lib/Foswiki/Configure/Checker.pm
. Your fix is good, as the code has been added back into the upcoming 1.2.0. So this can be marked as fixed in 1.2., once 1.2 is released.
--
GeorgeClark - 14 May 2015