Received: from out0.migadu.com (out0.migadu.com [94.23.1.103]) by nld3-dev1.alpinelinux.org (Postfix) with ESMTPS id 0DBA2782CF0 for <~alpine/aports@lists.alpinelinux.org>; Thu, 17 Dec 2020 02:42:53 +0000 (UTC) X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cmpwn.com; s=key1; t=1608172971; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=UcHfgsgSrNWzzYyubDX8taMq9yq8JNASI186J+5wR2c=; b=N4615+CJYljQ3/98T9Ib+2TlRSRToP0/1kaCezmr1x1J8NDe18cGRFQb2PBFz7vPYFACgL WBrjJwFUZ6a9ikPhPoLLQBZc5h15i1y9z4Jkv1I1Ygu5r0hXdY0GSkDEvAOot3/FawUxO/ ZemvtjpYY/0VikmpQIFz89/HKmVNUED+qTxW9L0GG3C4LqCNAIY9azjVyJJPfrG3k+3bAb nm7OxyrhX6AM5iWEigelqgglheizAtJMnJHVZhXfXYcrHBEUXQmtwumG3oz0Otqrd+07JF E5Z9qx8CTqVpIr0nn0ZuDH1JWFMO2nwbZl77Zv6R0z/uKpxzaSc255Qm3mZ70Q== From: Drew DeVault To: ~alpine/aports@lists.alpinelinux.org Cc: Drew DeVault Subject: [PATCH] main/samurai: upgrade to 1.2 Message-Id: <20201217024222.29579-1-sir@cmpwn.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT X-Migadu-Auth-User: sir@cmpwn.com Date: Thu, 17 Dec 2020 02:42:51 GMT --- main/samurai/20-query-tool.patch | 86 -------------------------------- main/samurai/APKBUILD | 10 ++-- 2 files changed, 4 insertions(+), 92 deletions(-) delete mode 100644 main/samurai/20-query-tool.patch diff --git a/main/samurai/20-query-tool.patch b/main/samurai/20-query-tool.patch deleted file mode 100644 index 441453fa7b..0000000000 --- a/main/samurai/20-query-tool.patch +++ /dev/null @@ -1,86 +0,0 @@ -From: Paolo Bonzini -Subject: [PATCH] Implement "query" tool - -The query tool allows to print the incoming and outgoing edges for -a given node. - -Upstream commit 0727b7c7d08e857a836b8cc7c630fe7a66385c92. - -diff --git a/samu.1 b/samu.1 -index 1bcc181..62c4cdb 100644 ---- a/samu.1 -+++ b/samu.1 -@@ -29,6 +29,11 @@ - .Nm - .Op Fl C Ar dir - .Op Fl f Ar buildfile -+.Fl t Cm query -+.Op Ar target... -+.Nm -+.Op Fl C Ar dir -+.Op Fl f Ar buildfile - .Fl t Cm targets - .Op Cm depth Op Ar maxdepth - .Nm -@@ -78,6 +83,10 @@ tool is used, a compilation database - is printed instead. - .Pp - If the -+.Cm query -+tool is used, the inputs and outputs of the targets are printed instead. -+.Pp -+If the - .Cm targets - tool is used, a list of targets will be displayed, either by rule or by depth. - The first argument determines how the targets will be displayed: -diff --git a/tool.c b/tool.c -index 1eaabfd..5e777cd 100644 ---- a/tool.c -+++ b/tool.c -@@ -298,9 +298,46 @@ targets(int argc, char *argv[]) - return 0; - } - -+static int -+query(int argc, char *argv[]) -+{ -+ struct node *n; -+ struct edge *e; -+ char *path; -+ int i; -+ size_t j, k; -+ -+ if (argc == 1) { -+ fprintf(stderr, "usage: %s ... -t query target...\n", argv0); -+ exit(2); -+ } -+ for (i = 1; i < argc; ++i) { -+ path = argv[i]; -+ n = nodeget(path, 0); -+ if (!n) -+ fatal("unknown target '%s'", path); -+ printf("%s:\n", argv[i]); -+ e = n->gen; -+ if (e) { -+ printf(" input: %s\n", e->rule->name); -+ for (j = 0; j < e->nin; ++j) -+ printf(" %s\n", e->in[j]->path->s); -+ } -+ puts(" outputs:"); -+ for (j = 0; j < n->nuse; ++j) { -+ e = n->use[j]; -+ for (k = 0; k < e->nout; ++k) -+ printf(" %s\n", e->out[k]->path->s); -+ } -+ } -+ -+ return 0; -+} -+ - static const struct tool tools[] = { - {"clean", clean}, - {"compdb", compdb}, -+ {"query", query}, - {"targets", targets}, - }; - diff --git a/main/samurai/APKBUILD b/main/samurai/APKBUILD index 8c3cf969ac..0162ee16e0 100644 --- a/main/samurai/APKBUILD +++ b/main/samurai/APKBUILD @@ -1,16 +1,15 @@ # Contributor: Drew DeVault # Maintainer: Drew DeVault pkgname=samurai -pkgver=1.1 -pkgrel=1 +pkgver=1.2 +pkgrel=0 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="https://github.com/michaelforney/samurai/releases/download/$pkgver/samurai-$pkgver.tar.gz - 20-query-tool.patch" +source="https://github.com/michaelforney/samurai/releases/download/$pkgver/samurai-$pkgver.tar.gz" provides="ninja" replaces="ninja" @@ -23,5 +22,4 @@ package() { ln -s samu "$pkgdir"/usr/bin/ninja } -sha512sums="b27302c34d736f483909e57c8b162609eaa4c86571c1167b71a5564b521cc3af2861307a16bb6dca55e80952088989e9526b103160d2ea054d15f4ed85b1cedb samurai-1.1.tar.gz -54f5159ed71e5e0d4bcc3e9c7534411225b1ad8b90ac5ac917114dbae619fed74b74a91dea4d99246304d0e7017f2600a06dd54f899a7b7852a858189e12608d 20-query-tool.patch" +sha512sums="bbe6a582c34b04f1df53b76c1647aa3e03c4698ebf7591a203935f11ffa05971bbcb86dc1a8c06aeb904cdc741abb08918122810fc47216fed0a6d9f87fd1225 samurai-1.2.tar.gz" -- 2.29.2