From 9aeb3c953a7253c15509566a80fa25aab7f628c9 Mon Sep 17 00:00:00 2001 From: JIHUN Date: Wed, 18 Mar 2020 17:52:58 +0900 Subject: [PATCH] Fix version number to use script Change-Id: Ic7b7e4523d1fe5d89f7d46028f16fe98ffe5190a Signed-off-by: JIHUN --- .gitignore | 1 - .version | 3 +++ bin/gendesc | 2 +- bin/get_version.sh | 2 +- packaging/lcov.spec | 4 ++-- 5 files changed, 7 insertions(+), 5 deletions(-) create mode 100644 .version diff --git a/.gitignore b/.gitignore index 51f9520..ac604f1 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,3 @@ -.version *.gcda *.gcno *.info diff --git a/.version b/.version new file mode 100644 index 0000000..41d672d --- /dev/null +++ b/.version @@ -0,0 +1,3 @@ +VERSION=1.14 +RELEASE=1.14 +FULL=1.14 diff --git a/bin/gendesc b/bin/gendesc index 775f8fe..97cde00 100755 --- a/bin/gendesc +++ b/bin/gendesc @@ -44,7 +44,7 @@ use Cwd qw/abs_path/; # Constants our $tool_dir = abs_path(dirname($0)); -our $lcov_version = "LCOV version 1.14"; +our $lcov_version = 'LCOV version '.`$tool_dir/get_version.sh --full`; our $lcov_url = "http://ltp.sourceforge.net/coverage/lcov.php"; our $tool_name = basename($0); diff --git a/bin/get_version.sh b/bin/get_version.sh index b6d5de9..ac5a363 100755 --- a/bin/get_version.sh +++ b/bin/get_version.sh @@ -25,7 +25,7 @@ else fi # Fallback -[ -z "$VERSION" ] && VERSION="1.14" +[ -z "$VERSION" ] && VERSION="1.0" [ -z "$RELEASE" ] && RELEASE="1" [ -z "$FULL" ] && FULL="$VERSION" diff --git a/packaging/lcov.spec b/packaging/lcov.spec index ff3d26f..753cd38 100644 --- a/packaging/lcov.spec +++ b/packaging/lcov.spec @@ -5,8 +5,8 @@ Release: 1 License: GPLv2+ Group: Development/Tools URL: http://ltp.sourceforge.net/coverage/lcov.php -Source0: http://downloads.sourceforge.net/ltp/lcov-%{version}.tar.gz -BuildRoot: var/tmp/%{name}-%{version}-root +Source0: http://downloads.sourceforge.net/ltp/%{name}-%{version}.tar.gz +BuildRoot: %{_tmppath}/%{name}-%{version}-root BuildArch: noarch Requires: perl >= 5.8.8 Requires: perl-PerlIO-gzip -- 2.7.4