mirror of
https://gitlab.com/qemu-project/qemu
synced 2024-11-02 22:41:07 +00:00
242fb750bd
Typo introduced with the script.
Fixes: 2c273f32d3
("meson: generate qemu-version.h")
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reported-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Tested-by: Laszlo Ersek <lersek@redhat.com>
Message-Id: <20200929143654.518157-1-marcandre.lureau@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
25 lines
400 B
Bash
Executable file
25 lines
400 B
Bash
Executable file
#!/bin/sh
|
|
|
|
set -eu
|
|
|
|
dir="$1"
|
|
pkgversion="$2"
|
|
version="$3"
|
|
|
|
if [ -z "$pkgversion" ]; then
|
|
cd "$dir"
|
|
if [ -e .git ]; then
|
|
pkgversion=$(git describe --match 'v*' --dirty) || :
|
|
fi
|
|
fi
|
|
|
|
if [ -n "$pkgversion" ]; then
|
|
fullversion="$version ($pkgversion)"
|
|
else
|
|
fullversion="$version"
|
|
fi
|
|
|
|
cat <<EOF
|
|
#define QEMU_PKGVERSION "$pkgversion"
|
|
#define QEMU_FULL_VERSION "$fullversion"
|
|
EOF
|