Mail archive
alpine-aports

[alpine-aports] [PATCH 1/2] testing/samurai: remove check()

From: Michael Forney <mforney_at_mforney.org>
Date: Mon, 18 Mar 2019 00:05:08 -0700

There is no provided test suite. The `build.ninja` is meant to be an
alternative build mechanism and requires modification to set desired
compile and link flags.

So, running `./samu` in check() will rebuild itself before packaging,
but without the CFLAGS and LDFLAGS set by abuild, resulting in an
unoptimized binary.
---
 testing/samurai/APKBUILD | 9 ++-------
 1 file changed, 2 insertions(+), 7 deletions(-)
diff --git a/testing/samurai/APKBUILD b/testing/samurai/APKBUILD
index fa51ea9a6d..befb1c1772 100644
--- a/testing/samurai/APKBUILD
+++ b/testing/samurai/APKBUILD
_at_@ -2,11 +2,12 @@
 # Maintainer: Drew DeVault <sir_at_cmpwn.com>
 pkgname=samurai
 pkgver=0.6
-pkgrel=0
+pkgrel=1
 pkgdesc="ninja-compatible build tool written in C"
 url="https://github.com/michaelforney/samurai"
 arch="all"
 license="Apache-2.0"
+options="!check"  # No test suite.
 subpackages="$pkgname-doc"
 source="$pkgname-$pkgver.tar.gz::https://github.com/michaelforney/$pkgname/archive/$pkgver.tar.gz"
 builddir="$srcdir/$pkgname-$pkgver"
_at_@ -16,12 +17,6 @@ build() {
 	make
 }
 
-check() {
-	cd "$builddir"
-	rm *.o
-	./samu
-}
-
 package() {
 	cd "$builddir"
 	make install PREFIX="/usr" DESTDIR="$pkgdir"
-- 
2.19.1
---
Unsubscribe:  alpine-aports+unsubscribe_at_lists.alpinelinux.org
Help:         alpine-aports+help_at_lists.alpinelinux.org
---
Received on Mon Mar 18 2019 - 00:05:08 UTC