summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/build-compare/files/pkg-diff.sh-check_single_file-return-at-once-when-sa.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/build-compare/files/pkg-diff.sh-check_single_file-return-at-once-when-sa.patch')
-rw-r--r--meta/recipes-devtools/build-compare/files/pkg-diff.sh-check_single_file-return-at-once-when-sa.patch37
1 files changed, 0 insertions, 37 deletions
diff --git a/meta/recipes-devtools/build-compare/files/pkg-diff.sh-check_single_file-return-at-once-when-sa.patch b/meta/recipes-devtools/build-compare/files/pkg-diff.sh-check_single_file-return-at-once-when-sa.patch
deleted file mode 100644
index b42af2531d..0000000000
--- a/meta/recipes-devtools/build-compare/files/pkg-diff.sh-check_single_file-return-at-once-when-sa.patch
+++ /dev/null
@@ -1,37 +0,0 @@
1From 657983ef9ca8f8354172682e17408c4f6b5bc667 Mon Sep 17 00:00:00 2001
2From: Robert Yang <liezhi.yang@windriver.com>
3Date: Thu, 14 Jul 2016 19:46:08 -0700
4Subject: [PATCH 1/4] pkg-diff.sh: check_single_file(): return at once when
5 same
6
7If the two files are the same, return at once, this can save a lot of
8time when there are archives inside archives.
9
10Upstream-Status: Submitted [https://github.com/openSUSE/build-compare/pull/10]
11
12Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
13---
14 pkg-diff.sh | 7 +++++++
15 1 file changed, 7 insertions(+)
16
17diff --git a/pkg-diff.sh b/pkg-diff.sh
18index 3cf10aa..402d4a4 100644
19--- a/pkg-diff.sh
20+++ b/pkg-diff.sh
21@@ -293,6 +293,13 @@ check_compressed_file()
22 check_single_file()
23 {
24 local file="$1"
25+
26+ # If the two files are the same, return at once.
27+ if [ -f old/$file -a -f new/$file ]; then
28+ if cmp -s old/$file new/$file; then
29+ return 0
30+ fi
31+ fi
32 case $file in
33 *.spec)
34 sed -i -e "s,Release:.*$release1,Release: @RELEASE@," old/$file
35--
362.9.0
37