* [PR PATCH] build-style/go: use glob instead of find
@ 2019-11-11 7:01 voidlinux-github
2019-11-11 7:49 ` [PR PATCH] [Updated] " voidlinux-github
0 siblings, 1 reply; 2+ messages in thread
From: voidlinux-github @ 2019-11-11 7:01 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 341 bytes --]
There is a new pull request by zdtcd against master on the void-packages repository
https://github.com/zdtcd/void-packages build-style-go
https://github.com/void-linux/void-packages/pull/16354
build-style/go: use glob instead of find
Close #12442
A patch file from https://github.com/void-linux/void-packages/pull/16354.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-build-style-go-16354.patch --]
[-- Type: text/x-diff, Size: 1837 bytes --]
From 302432dcdfac352d45a3fbd475bd3a83d40e3eb4 Mon Sep 17 00:00:00 2001
From: Doan Tran Cong Danh <congdanhqx@gmail.com>
Date: Mon, 11 Nov 2019 13:49:02 +0700
Subject: [PATCH 1/2] build-style/go: use glob instead of find
---
common/build-style/go.sh | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/common/build-style/go.sh b/common/build-style/go.sh
index 97412843b20..d19598cf3a9 100644
--- a/common/build-style/go.sh
+++ b/common/build-style/go.sh
@@ -41,8 +41,9 @@ do_build() {
}
do_install() {
- find "${GOPATH}/bin" -type f -executable | while read line
- do
- vbin "${line}"
+ for f in ${GOPATH}/bin/*; do
+ if [ -x "$f" ]; then
+ vbin "$f"
+ fi
done
}
From 323032bd7844d20a8b28102ceea0c8f83b67d081 Mon Sep 17 00:00:00 2001
From: Doan Tran Cong Danh <congdanhqx@gmail.com>
Date: Mon, 11 Nov 2019 13:59:12 +0700
Subject: [PATCH 2/2] doctl: don't use go get
---
srcpkgs/doctl/template | 11 ++++-------
1 file changed, 4 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/doctl/template b/srcpkgs/doctl/template
index 1ed77fc2a35..733ea20e279 100644
--- a/srcpkgs/doctl/template
+++ b/srcpkgs/doctl/template
@@ -1,17 +1,14 @@
# Template file for 'doctl'
pkgname=doctl
version=1.21.1
-revision=1
+revision=2
build_style=go
go_import_path="github.com/digitalocean/doctl/cmd/doctl"
go_build_tags="v${version}"
-go_get="yes"
-hostmakedepends="git"
+go_get="no"
short_desc="Command line tool for DigitalOcean services"
maintainer="Noah Huppert <contact@noahh.io>"
license="Apache-2.0"
homepage="https://github.com/digitalocean/doctl"
-
-post_install() {
- vlicense "$GOPATH/src/github.com/digitalocean/doctl/LICENSE.txt"
-}
+distfiles="https://github.com/digitalocean/doctl/archive/v${version}.tar.gz"
+checksum=8c1e60930e913ace562511b6a7ee8f0d3f4d08d4ba48148f26e12b6d2eb95f2b
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PR PATCH] [Updated] build-style/go: use glob instead of find
2019-11-11 7:01 [PR PATCH] build-style/go: use glob instead of find voidlinux-github
@ 2019-11-11 7:49 ` voidlinux-github
0 siblings, 0 replies; 2+ messages in thread
From: voidlinux-github @ 2019-11-11 7:49 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 463 bytes --]
There is an updated pull request by zdtcd against master on the void-packages repository
https://github.com/zdtcd/void-packages build-style-go
https://github.com/void-linux/void-packages/pull/16354
build-style/go: use glob instead of find
Close #12442
---
The second commit is more or less a showcase.
Anyway, cloning a whole repository for dist build isn't nice.
A patch file from https://github.com/void-linux/void-packages/pull/16354.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-build-style-go-16354.patch --]
[-- Type: text/x-diff, Size: 1871 bytes --]
From da0344e19b1f9e0bfe19398c3d15e18f5423b390 Mon Sep 17 00:00:00 2001
From: Doan Tran Cong Danh <congdanhqx@gmail.com>
Date: Mon, 11 Nov 2019 13:49:02 +0700
Subject: [PATCH 1/2] build-style/go: use glob instead of find
---
common/build-style/go.sh | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/common/build-style/go.sh b/common/build-style/go.sh
index 97412843b20..c9f476b95c7 100644
--- a/common/build-style/go.sh
+++ b/common/build-style/go.sh
@@ -41,8 +41,9 @@ do_build() {
}
do_install() {
- find "${GOPATH}/bin" -type f -executable | while read line
- do
- vbin "${line}"
+ for f in ${GOPATH}/bin/* ${GOPATH}/bin/**/*; do
+ if [ -f "$f" ] && [ -x "$f" ]; then
+ vbin "$f"
+ fi
done
}
From 839f05e5a0b59ef501b4a5d2f7b21d7e37d2417c Mon Sep 17 00:00:00 2001
From: Doan Tran Cong Danh <congdanhqx@gmail.com>
Date: Mon, 11 Nov 2019 13:59:12 +0700
Subject: [PATCH 2/2] doctl: don't use go get
---
srcpkgs/doctl/template | 11 ++++-------
1 file changed, 4 insertions(+), 7 deletions(-)
diff --git a/srcpkgs/doctl/template b/srcpkgs/doctl/template
index 1ed77fc2a35..733ea20e279 100644
--- a/srcpkgs/doctl/template
+++ b/srcpkgs/doctl/template
@@ -1,17 +1,14 @@
# Template file for 'doctl'
pkgname=doctl
version=1.21.1
-revision=1
+revision=2
build_style=go
go_import_path="github.com/digitalocean/doctl/cmd/doctl"
go_build_tags="v${version}"
-go_get="yes"
-hostmakedepends="git"
+go_get="no"
short_desc="Command line tool for DigitalOcean services"
maintainer="Noah Huppert <contact@noahh.io>"
license="Apache-2.0"
homepage="https://github.com/digitalocean/doctl"
-
-post_install() {
- vlicense "$GOPATH/src/github.com/digitalocean/doctl/LICENSE.txt"
-}
+distfiles="https://github.com/digitalocean/doctl/archive/v${version}.tar.gz"
+checksum=8c1e60930e913ace562511b6a7ee8f0d3f4d08d4ba48148f26e12b6d2eb95f2b
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-11-11 7:49 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-11 7:01 [PR PATCH] build-style/go: use glob instead of find voidlinux-github
2019-11-11 7:49 ` [PR PATCH] [Updated] " voidlinux-github
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).