bootstrap: fix handling of various perl --version formats