summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxuhy <huayong.xu@samsung.com>2024-06-24 09:23:08 +0800
committerxuhy <huayong.xu@samsung.com>2024-06-27 17:02:25 +0800
commitffdf07d4257ce32d71d7e3f335ff43b198a80ee6 (patch)
tree62d9193af395dda4ec10825ccd827a783d5be6f3
parent1590a66f07c5d06bb5d500757f4e10d5399a03d4 (diff)
downloadbuild-sandbox/xuhy/devel-riscv-py3.tar.gz
build-sandbox/xuhy/devel-riscv-py3.tar.bz2
build-sandbox/xuhy/devel-riscv-py3.zip
Remove dpatch dependency.sandbox/xuhy/devel-riscv-py3
dpatch package is not available on ubuntu 24.04. Change-Id: I604ee04561203fa7b2b69f6f7621a47524d2a553
-rw-r--r--debian/control2
-rwxr-xr-xinit_buildsystem6
2 files changed, 6 insertions, 2 deletions
diff --git a/debian/control b/debian/control
index 831940b..ec1ba0b 100644
--- a/debian/control
+++ b/debian/control
@@ -2,7 +2,7 @@ Source: build
Section: devel
Priority: optional
Maintainer: Adrian Schroeter <adrian@suse.de>
-Build-Depends: debhelper (>= 4), dpatch, cdbs,libc6,
+Build-Depends: debhelper (>= 4), cdbs, libc6
Standards-Version: 3.7.2
Package: build
diff --git a/init_buildsystem b/init_buildsystem
index 3e4a892..aa3a072 100755
--- a/init_buildsystem
+++ b/init_buildsystem
@@ -462,7 +462,11 @@ downloadpkg() {
;;
esac
# if there is such package, didn't mv.
- mv -n "$destfile" "$SRC" || cleanup_and_exit 1
+ if [ ! -f "$SRC" ]; then
+ # avoid race condition in multi-thread cases,
+ # and skip errors if $SRC exists, because nothing is moved in this case.
+ ln -PT "$destfile" "$SRC" && rm "$destfile" || true || cleanup_and_exit 1
+ fi
rm -rf $destdir
}