problem with Makefile.PL in Catalyst

1.7k Views Asked by At

i am trying to deploy an Catalyst application. I have put all includes in the Makefile.PL file an thought that should be enough to install in on the target machine. However, when I try to build the Makefile I get the following:

$ perl Makefile.PL
Bareword "WriteAll" not allowed while "strict subs" in use at Makefile.PL line 47.
Execution of Makefile.PL aborted due to compilation errors.

Can anyone tell what I am doing wrong? I have installed - Module::Install - Local::lib - Catalyst::Runtime (and later also Catalyst::Devel to be sure)

I thought the whole idea of managing a good Makefile.PL was easy installation to the production machine??

3

There are 3 best solutions below

0
On BEST ANSWER

Well the Makefile.PL is good perl code, I am talking about The out of the box Makefile.PL for Catalyst apps (WriteAll is standard in Catalyst Makefile)

Apparently you have to 'make dist' on the development machine that makes a tarball of the application. That tarball contains a Makefile.PL that does work on the production machine. I overlooked the Catalyst comment in the development Makefile.PL that states that it should 'complain loudly and die' when it was deployed without a 'make dist'...

Strange that Catalyst does not provide a somewhat more informative error in this case... And a pity that nobody recognized the default Makefile setup. Thanks for your comment though, mob.

0
On

I was getting error, it was because I didn't have Module::Install installed. I had changed to a newer version of perl (5.14 -> 5.16), and the newer version simply didn't have the library.

  • cpanm Module::Install

done.

2
On

I had the same problem.

I found out that removing inc/ solved it. YMMV