Patches by Paul Johnson, to make Perl build again.