On Mon, Jul 04, 2005 at 03:59:23PM -0400, James E Keenan wrote:
> I've only developed in 5.6+ environments.  Can anyone provide a link to 
> what I would have to do to make my modules compatible with 5.4 and/or 5.5?

Step one:  Install 5.4.5 and 5.5.4.

Step two:  Try out your module with them.

Step three:  Curse, scream and yell as you work around all sorts of long
fixed bugs.

One could attempt to code for the differences but to really make sure your
module works with on old version you have to try it with the older version.

That said, here's the main differences:

* No qr//.  Even if you target 5.5.4 qr// still has lots of bugs.
* No warnings.pm.  Use $^W instead.
* No our().  Use vars.pm instead.
* No CORE::GLOBAL in 5.4.
* Many modules are not core or use old, broken versions.  I always run into
  problems with File::Spec and consider 0.8 to be the minimum version for
  sanity.  
* No Test::More so you either have to use Test.pm, list Test::More
  as a dependency or ship it with your module in t/lib.
* No Unicode.  If you need to support Unicode you're probably best off 
  dropping 5.4 and 5.5 and even consider dropping 5.6.
* No (remotely sane) threads.
* No attributes.
* No "open my $fh".  Use "local FH; open FH" instead.
* No lvalue subroutines.
* Older, more insane MakeMaker for those who do MakeMaker hackery.
* No x.y.z versions.
* All sorts of XS differences.
* Different warning and error diagnostics.

Once you go through the initial pain of backporting its not too big a deal
to keep things working as long as you're not doing XS.  qr// is the only 
thing I really miss.


-- 
Michael G Schwern     [EMAIL PROTECTED]     http://www.pobox.com/~schwern
ROCKS FALL! EVERYONE DIES!
        http://www.somethingpositive.net/sp05032002.shtml

Reply via email to