Home Home > GIT Browse
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiroslav Benes <mbenes@suse.cz>2014-11-04 16:23:50 +0100
committerMiroslav Benes <mbenes@suse.cz>2014-11-04 16:23:50 +0100
commit51fd9ddd24922402823cd898702e30a466769d03 (patch)
tree1f78af7f5db9f12f3530308a2221bea586088dfc
parentfeab4f1daae515aa3358a3bde83accc066646741 (diff)
Replace @@RELEASE@@ in kgr_patch->name with @@RPMRELEASE@@
We need to replace @@RELEASE@@ in kgr_patch->name with @@RPMRELEASE@@ due to sysfs tree. @@RELEASE@@ changes with each new version of package. Signed-off-by: Miroslav Benes <mbenes@suse.cz>
-rw-r--r--kgr_patch_main.c2
-rw-r--r--rpm/kgraft-patch.spec1
-rwxr-xr-xscripts/tar-up.sh3
3 files changed, 3 insertions, 3 deletions
diff --git a/kgr_patch_main.c b/kgr_patch_main.c
index 9511ac3..cff817c 100644
--- a/kgr_patch_main.c
+++ b/kgr_patch_main.c
@@ -5,7 +5,7 @@
#include "uname_patch/kgr_patch_uname.h"
static struct kgr_patch patch = {
- .name = "kgraft-patch-@@RELEASE@@",
+ .name = "kgraft-patch-@@RPMRELEASE@@",
.owner = THIS_MODULE,
.patches = {
KGR_PATCH(SyS_newuname, kgr_sys_newuname, true),
diff --git a/rpm/kgraft-patch.spec b/rpm/kgraft-patch.spec
index f42d56a..f3c0988 100644
--- a/rpm/kgraft-patch.spec
+++ b/rpm/kgraft-patch.spec
@@ -44,6 +44,7 @@ cp %_sourcedir/Makefile .
%build
set -- *
sed -i 's/@@RPMRELEASE@@/%module_num/g' Makefile
+sed -i 's/@@RPMRELEASE@@/%module_num/g' kgr_patch_main.c
for flavor in %flavors_to_build; do
mkdir -p "obj/$flavor"
cp -r "$@" "obj/$flavor"
diff --git a/scripts/tar-up.sh b/scripts/tar-up.sh
index cd0d683..8ae0cb2 100755
--- a/scripts/tar-up.sh
+++ b/scripts/tar-up.sh
@@ -52,8 +52,7 @@ install -m 644 rpm/kgraft-patch.spec $build_dir/kgraft-patch-"$RELEASE".spec
install -m 644 rpm/kgraft-patch.changes $build_dir/kgraft-patch-"$RELEASE".changes
install -m 644 rpm/config.sh $build_dir/config.sh
-sed -i "s/@@RELEASE@@/$RELEASE/g" $build_dir/kgr_patch_main.c \
- $build_dir/kgraft-patch-"$RELEASE".spec
+sed -i "s/@@RELEASE@@/$RELEASE/g" $build_dir/kgraft-patch-"$RELEASE".spec
tsfile=source-timestamp
ts=$(git show --pretty=format:%ct HEAD | head -n 1)