FindPython: enhance robustness of version extraction from library name

Fixes: #21105
38 jobs for !5135 with bug-fixes in 56 minutes and 17 seconds (queued for 3 seconds)
latest detached
Status Job ID Name Coverage
  Build
passed #5140552
linux docker cmake build manual
build:centos6-release

00:03:04

passed #5140549
linux docker cmake build
build:debian10-iwyu

00:10:31

passed #5140553
linux docker cmake build linux-3.17 manual
build:fedora31-ninja

00:02:06

passed #5140551
linux docker cmake build linux-3.17
build:fedora31-sphinx

00:04:51

passed #5140550
linux docker cmake build linux-3.17
build:fedora31-tidy

00:04:13

passed #5140555
cmake macos shell xcode-11.5 nonconcurrent manual
build:macos-makefiles

00:02:49

passed #5140554
cmake macos shell xcode-11.5 nonconcurrent manual
build:macos-ninja

00:02:40

passed #5140556
msvc-19.25 windows cmake shell vs2019 nonconcurrent manual
build:windows-vs2019-x64-ninja

00:06:48

 
  Test
passed #5140557
linux docker cmake build linux-3.17
test:fedora31-ninja

00:04:17

passed #5140559
cmake macos shell xcode-11.5 nonconcurrent
test:macos-makefiles

00:11:05

passed #5140558
cmake macos shell xcode-11.5 nonconcurrent
test:macos-ninja

00:08:28

passed #5140560
msvc-19.25 windows cmake shell vs2019 nonconcurrent
test:windows-vs2019-x64-ninja

00:14:26

 
  Test Ext
passed #5140562
linux docker cmake cuda-rt
test:cuda10.2-nvidia

00:00:52

passed #5140561
linux docker cmake build linux-3.17
test:fedora31-makefiles

00:02:35

passed #5140563
linux docker cmake build linux-3.17
test:fedora31-ninja-multi

00:12:38

passed #5140564
cmake macos shell xcode-11.5 concurrent
test:macos-xcode

00:28:18

passed #5140565
msvc-19.25 windows cmake shell vs2019 concurrent
test:windows-vs2019-x64

00:24:26

 
  External
passed cdash

passed ghostflow-check-master

passed ghostflow-check-release

passed ghostflow-stager

passed cdash

passed cdash

passed cdash

passed cdash

passed cdash

passed cdash

passed cdash

passed cdash

passed ghostflow-check-master

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager

passed ghostflow-stager