Github messages for voidlinux
 help / color / mirror / Atom feed
From: Shanduur <Shanduur@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: [RFC] add support for CGO_ENABLED parameter for Go build style
Date: Fri, 16 Sep 2022 16:01:39 +0200	[thread overview]
Message-ID: <20220916140139.8NSRdUprytwGjpdyPUEBJY7glTTYbwCOqcJ1z8nRx_I@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-39315@inbox.vuxu.org>

[-- Attachment #1: Type: text/plain, Size: 2885 bytes --]

New comment by Shanduur on void-packages repository

https://github.com/void-linux/void-packages/issues/39315#issuecomment-1249403203

Comment:
@paper42 I don't think so, [here is commit](https://github.com/void-linux/void-packages/compare/master...Shanduur:void-packages:new-package-promtail):
```
[void@freepc void-packages]$ cat srcpkgs/promtail/template
# Template file for 'promtail'
pkgname=promtail
version=2.6.1
revision=1
wrksrc="loki-${version}"
build_style=go
go_import_path="github.com/grafana/loki"
go_package="${go_import_path}/clients/cmd/promtail"
short_desc="Like Prometheus, but for logs"
maintainer="Mateusz Urbanek <murbanek@shanduur.com>"
license="Apache-2.0"
homepage="https://grafana.com/oss/loki/"
distfiles="https://github.com/grafana/loki/archive/v${version}.tar.gz"
checksum=4b41175e552dd198bb9cae213df3c0d9ca8cacd0b673f79d26419cea7cfb2df7

export CGO_ENABLED=0

pre_build() {
	msg_warn "CGO_ENABLED: got: $(go env CGO_ENABLED), wanted: $(CGO_ENABLED=0 go env CGO_ENABLED)\n"
}
[void@freepc void-packages]$ ./xbps-src pkg promtail
=> xbps-src: updating repositories for host (x86_64-musl)...
[*] Updating repository `https://repo-default.voidlinux.org/current/musl/x86_64-musl-repodata' ...
[*] Updating repository `https://repo-default.voidlinux.org/current/musl/nonfree/x86_64-musl-repodata' ...
[*] Updating repository `https://repo-default.voidlinux.org/current/musl/debug/x86_64-musl-repodata' ...
=> xbps-src: updating software in / masterdir...
=> xbps-src: cleaning up / masterdir...
=> promtail-2.6.1_1: removing autodeps, please wait...
=> promtail-2.6.1_1: building [go] for x86_64-musl...
   [host] go-1.19_1: found (/host/binpkgs/add-grafana-loki)
=> promtail-2.6.1_1: installing host dependencies: go-1.19_1 ...
=> promtail-2.6.1_1: running pre-build hook: 02-script-wrapper ...
=> promtail-2.6.1_1: running pre_build ...
=> WARNING: CGO_ENABLED: got: 1, wanted: 0
=> promtail-2.6.1_1: running do_build ...
=> Using vendor dir for promtail Go dependencies.
WORK=/tmp/go-build987700878
mkdir -p $WORK/b1062/
cd /builddir/loki-2.6.1/vendor/github.com/coreos/go-systemd/sdjournal
TERM='dumb' /usr/lib/go/pkg/tool/linux_amd64/cgo -objdir $WORK/b1062/ -importpath github.com/coreos/go-systemd/sdjournal -- -I $WORK/b1062/ -mtune=generic -O2 -pipe ./journal.go
# github.com/coreos/go-systemd/sdjournal
vendor/github.com/coreos/go-systemd/sdjournal/journal.go:27:11: fatal error: systemd/sd-journal.h: No such file or directory
   27 | // #include <systemd/sd-journal.h>
      |           ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
=> ERROR: promtail-2.6.1_1: do_build: 'go install -p "$XBPS_MAKEJOBS" -mod="${go_mod_mode}" -x -tags "${go_build_tags}" -ldflags "${go_ldflags}" ${go_package}' exited with 2
=> ERROR:   in do_build() at common/build-style/go.sh:43
[void@freepc void-packages]$
```

  parent reply	other threads:[~2022-09-16 14:01 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-16 13:33 [ISSUE] " Shanduur
2022-09-16 13:37 ` paper42
2022-09-16 14:01 ` Shanduur [this message]
2022-09-16 14:30 ` Shanduur
2022-09-16 14:31 ` Shanduur
2022-09-16 14:31 ` Shanduur
2022-09-16 14:46 ` Duncaen
2022-09-16 14:49 ` Duncaen
2022-09-16 14:53 ` [ISSUE] [CLOSED] " Shanduur
2022-09-16 14:53 ` Shanduur

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220916140139.8NSRdUprytwGjpdyPUEBJY7glTTYbwCOqcJ1z8nRx_I@z \
    --to=shanduur@users.noreply.github.com \
    --cc=ml@inbox.vuxu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).