build: teach osv-version.sh not to pick up random tags

Otherwise the build blows up when some regex doesn't match.

Signed-off-by: Avi Kivity <avi@cloudius-systems.com>
Signed-off-by: Avi Kivity <avi@cloudius-systems.com>