[Perl] How to fix the Net::Amazon::S3 and Class::MethodMaker installation

And not die trying

[Perl] How to fix the Net::Amazon::S3 and Class::MethodMaker installation

I have a docker container with a Perl app that requires several modules, and Net::Amazon::S3 is one of those modules.

Several days ago, the Net::Amazon::S3 started failing during the installation process so, I tried to install it manually, and I figured out there was an issue with the DateTimeX::Easy (a dependency).

I took a look at the DateTimeX::Easy, and I found the DateTime-Format-Flexible (a dependency) was updated recently, and it broke the build and tests.

So, there are two ways to fix it:

  • Use the force tag to install: cpan> force install DateTimeX::Easy

Or:

  • Install version 0.33 of DateTime-Format-Flexible cpan> install DateTime-Format-Flexible@0.33

Alright, now Net::Amazon::S3 should install, right?.... well, nope.

(Sigh) Now the Class::MethodMaker is returning an error, and for any weird reason, it is not installing all the dependencies that it requires, so you must install them:

  • cpan> install Env
  • cpan> install Fatal
  • cpan> install JSON::PP

And... it worked!

It took me two days to figured out how to fix it, and this post helped a lot: morgajel.net/2015/05/20/1676

65116195.jpg