Commit 1b18665c authored by Sören Tempel's avatar Sören Tempel

main/abuild: backport fix for ignoring exit status of git-describe(1)

parent 59dd9322
From 720a2c185e792b289ce52a56aa15857faa8fa35a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?S=C3=B6ren=20Tempel?= <soeren+git@soeren-tempel.net>
Date: Sun, 22 Apr 2018 16:17:23 +0200
Subject: [PATCH] abuild.in: don't fail if git describe fails
`git describe` by default looks for tags, but `git clone` does not clone
tags by default which causes failures on travis currently.
Also redirect `git describe` errors to /dev/null while being here.
---
abuild.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/abuild.in b/abuild.in
index 67a596f..2c6feb4 100644
--- a/abuild.in
+++ b/abuild.in
@@ -1548,7 +1548,7 @@ update_abuildrepo_index() {
subpkg_unset
if [ -z "$DESCRIPTION" ]; then
- DESCRIPTION="$repo $(cd $startdir && $git describe)"
+ DESCRIPTION="$repo $(cd $startdir && $git describe 2>/dev/null || true)"
fi
for i in $allarch; do
--
2.17.0
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
pkgname=abuild pkgname=abuild
pkgver=3.2.0_rc1 pkgver=3.2.0_rc1
_ver=${pkgver%_git*} _ver=${pkgver%_git*}
pkgrel=0 pkgrel=1
pkgdesc="Script to build Alpine Packages" pkgdesc="Script to build Alpine Packages"
url="https://git.alpinelinux.org/cgit/abuild/" url="https://git.alpinelinux.org/cgit/abuild/"
arch="all" arch="all"
...@@ -21,7 +21,7 @@ subpackages="apkbuild-cpan:cpan:noarch apkbuild-gem-resolver:gems:noarch ...@@ -21,7 +21,7 @@ subpackages="apkbuild-cpan:cpan:noarch apkbuild-gem-resolver:gems:noarch
options="suid !check" options="suid !check"
pkggroups="abuild" pkggroups="abuild"
source="http://dev.alpinelinux.org/archive/abuild/abuild-$_ver.tar.xz source="http://dev.alpinelinux.org/archive/abuild/abuild-$_ver.tar.xz
" 0001-abuild.in-don-t-fail-if-git-describe-fails.patch"
builddir="$srcdir/$pkgname-$_ver" builddir="$srcdir/$pkgname-$_ver"
prepare() { prepare() {
...@@ -67,4 +67,5 @@ _rootbld() { ...@@ -67,4 +67,5 @@ _rootbld() {
mkdir -p "$subpkgdir" mkdir -p "$subpkgdir"
} }
sha512sums="97f5ca9e2c36d06e0201ad3c31330378b57b760ece63e96c2db01b665e260d7201030fdb827399f5a046d13c68367b4c8a9bc1a04575df07915184fc3b129cbf abuild-3.2.0_rc1.tar.xz" sha512sums="97f5ca9e2c36d06e0201ad3c31330378b57b760ece63e96c2db01b665e260d7201030fdb827399f5a046d13c68367b4c8a9bc1a04575df07915184fc3b129cbf abuild-3.2.0_rc1.tar.xz
d6b63feb43f534ad7f12f32b4b973453c4485163845743e3314d99011309245405bab1d28adef72c315d8ba5083cf9e0e456d8ee2edbdef150437a7c21753219 0001-abuild.in-don-t-fail-if-git-describe-fails.patch"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment