Blame SOURCES/0003-specfile-Fix-version-issue.patch

5a9c2e
From 9f7b7b9edf686b6312a9e72cdc5281c62ddabfac Mon Sep 17 00:00:00 2001
5a9c2e
From: Mamatha Inamdar <mamatha4@linux.vnet.ibm.com>
5a9c2e
Date: Tue, 30 Apr 2019 17:29:07 +0530
5a9c2e
Subject: [PATCH] specfile: Fix version issue
5a9c2e
5a9c2e
Current code uses `git describe` to get package version. But we missed
5a9c2e
to update specfile. So if we build rpm then `lshw -version` shows
5a9c2e
"unknown".
5a9c2e
5a9c2e
This patch adds "VERSION" compilation flag in specfile. So that we
5a9c2e
get proper output.
5a9c2e
5a9c2e
Signed-off-by: Mamatha Inamdar <mamatha4@linux.vnet.ibm.com>
5a9c2e
[Updated description and updated "without_gui" section - Vasant]
5a9c2e
Signed-off-by: Vasant Hegde <hegdevasant@linux.vnet.ibm.com>
5a9c2e
Signed-off-by: Lianbo Jiang <lijiang@redhat.com>
5a9c2e
---
5a9c2e
 lshw.spec.in | 2 ++
5a9c2e
 1 file changed, 2 insertions(+)
5a9c2e
5a9c2e
diff --git a/lshw.spec.in b/lshw.spec.in
5a9c2e
index f7f88b323ce9..0e4797baab56 100644
5a9c2e
--- a/lshw.spec.in
5a9c2e
+++ b/lshw.spec.in
5a9c2e
@@ -57,6 +57,7 @@ http://lshw.ezix.org/
5a9c2e
   SBINDIR="%{_sbindir}" \
5a9c2e
   MANDIR="%{_mandir}" \
5a9c2e
   DATADIR="%{_datadir}" \
5a9c2e
+  VERSION="%{version}" \
5a9c2e
   all
5a9c2e
 %if %{!?_without_gui:1}0
5a9c2e
 %{__make} %{?_smp_mflags} \
5a9c2e
@@ -64,6 +65,7 @@ http://lshw.ezix.org/
5a9c2e
   SBINDIR="%{_sbindir}" \
5a9c2e
   MANDIR="%{_mandir}" \
5a9c2e
   DATADIR="%{_datadir}" \
5a9c2e
+  VERSION="%{version}" \
5a9c2e
   gui
5a9c2e
 %endif
5a9c2e
 
5a9c2e
-- 
5a9c2e
2.17.1
5a9c2e