[PATCH 6.9 142/143] kbuild: Make ld-version.sh more robust against version string changes