From nobody Sat May 28 00:03:38 2022 X-Original-To: freebsd-ports@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id C9C4B1B3F700 for ; Sat, 28 May 2022 00:03:41 +0000 (UTC) (envelope-from dmgk@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4L922P55scz4Txq; Sat, 28 May 2022 00:03:41 +0000 (UTC) (envelope-from dmgk@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1653696221; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=nc3j7pi217lONzs2jZUz5mOrPK1hdWk+jOt0yW6Vg0I=; b=hmyMJSpNgsDH3EPAtgxt/hkVV18MFSkCojdTLEO8Fbb0lt0/MNMijyTHZszO5wCuLgl4Yj iys9YhCSqZVEfJAwcG2WCgr2abpOM635fr2RlIK9LvMNqzMb9OPlOIoTX8K2lslRH+wBf4 T1t4Vv2zfsnPFqEEsdXnZCTNLr5t5uy9NhGC/6R4lzWFDN05R/V/Z8lljRE9zvPUHZfgQX bEMld0CaeOm97klAyj15FQuxg6EHSTMkxK5pBni+sHQrWm8D0vH5CyxMTHd7wftbs4MBYu mgRC09Bb5aasq2lOiE6v8yeIg1qkefjKPDwHAJDwYQGxX+kg/Wf6JhBtA3b2cg== Received: from mail.syrec.org (mail.syrec.org [167.172.159.90]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) (Authenticated sender: dmgk/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 89C57CD5B; Sat, 28 May 2022 00:03:41 +0000 (UTC) (envelope-from dmgk@freebsd.org) Received: from xombo.localdomain (38.200-55-228.etapanet.net [200.55.228.38]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.syrec.org (Postfix) with ESMTPSA id 0D4174D427; Fri, 27 May 2022 19:03:40 -0500 (-05) Date: Fri, 27 May 2022 19:03:38 -0500 From: Dmitri Goutnik To: Ben Lavery-Griffiths Cc: freebsd-ports@freebsd.org Subject: Re: Golang debug/buildinfo Message-ID: Mail-Followup-To: Ben Lavery-Griffiths , freebsd-ports@freebsd.org References: <61959b1c-8075-4f47-9642-15d28115bfd5@www.fastmail.com> List-Id: Porting software to FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-ports List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-ports@freebsd.org X-BeenThere: freebsd-ports@freebsd.org MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="D0fp/AkkLvNf8KFO" Content-Disposition: inline In-Reply-To: <61959b1c-8075-4f47-9642-15d28115bfd5@www.fastmail.com> ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1653696221; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=nc3j7pi217lONzs2jZUz5mOrPK1hdWk+jOt0yW6Vg0I=; b=X5xgAt5IFHFSXmDC1ZWFuF3WlPRBV4sbZ5bQAZcntMAryafLWfyA4G60NOpct9fHxNY+X4 DZ30i64S282M+iO2B2iEJ9rpTbvhm55MFeCpol927phsIGugI1yU11qpGX87bzo9WCGI6o AobVbJHetpiUHCUApSYvTS1PPw0K1NgIg79L3o44D0xDpRHWUue+1DO8EFcypgQ20KfAog ro237LPBzcQMOpTzf0aRCHbGF9o+Qh5vGoXm0YftQ3jkuSvta7gYzgohrg0gjQhxdiL4wX 3Vhlm+Mh9CGaV56chR9AhmnD3ZNVjHt2TQVp4IYehNURA7DY4iUlw+kjKdENSQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1653696221; a=rsa-sha256; cv=none; b=WjJ5ZKV97OO+boZgph6F1BtUJhMQA9RhagBR1J01GH95masyN2yxJB6bQ0bAvt46GTvwxi s9rkMYQ2qbEynA9yYvr8VWrI9Iw+qS7dZbQLPErZIoaQc5FubD30ymsa4/OLM2GM0oYUn+ n2iMhICT5FO/o2jaGe1xXcdFSH0G3xAaieKaX8fMQD5As1/5fEapwDiLQb6kPfgwqRg+7m 91n0EuJ5YzgrYwZXSLtr9MbIrH52bOV/MDQm02xeWFMYbR/W6cR60L/eiDkjIcFFCEUaiJ aQj8h9fqFyH1eAEL5FT+8F4+UDnicLqkLyYkF9iZnOlPIi8iWHtBqVDfMZkEUw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N --D0fp/AkkLvNf8KFO Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Ben, On 22-05-27 22:31:52, Ben Lavery-Griffiths wrote: > Hey all, >=20 > I maintain the www/gohugo port, with the upgrade to Go 1.18 they project = has switched to using debug/buildinfo (https://pkg.go.dev/runtime/debug#Bui= ldInfo), this gets certain information from VCS, as opposed to passing the = values in via ldflags. >=20 > Presuming more and more Go projects will use this mechanism, does anyone = know how we will be dealing with this for building ports? Currently, go.mk explicitly disables embedding VCS information in binaries = by=20 passing -buildvcs=3Dfalse flag. Embedding VCS info will not work for port b= uilds=20 because it required git (or other VCS, depending on the repository [1]), wh= ich=20 is not available in clean build environments. Other BuildInfo data (compile= r=20 version, settings etc) should be available. In cases when upstream code is not able to handle missing VCS info, it will= =20 probably need to be patched. I'd consider this situation an upstream bug as= it=20 effectively prevents packaging. [2] provides more background on this issue. [1] https://tip.golang.org/doc/go1.18#go-version [2] https://github.com/golang/go/issues/51748 > Many thanks, > Ben >=20 Best regards, --=20 Dmitri Goutnik dg@syrec.org / dmgk@FreeBSD.org --D0fp/AkkLvNf8KFO Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEElV1urwzdJVGXSG3dwZe2fOviDs0FAmKRZtQACgkQwZe2fOvi Ds0CXA/8DO6E5+KogJC8Mdc2XAqyHuKKVlfSZWByrqfuVwjCS3+QW6nXj0MOLW3j ZyaCqsam1iXvgRwpAeL4srrLSP+2VlTzNSX5WSu/IcWKWlQvzXCFpmWkhn68/pO/ KBcEGO2Vie+k5qjmMNOvkuzHS7uBaHqaULHy7rU+3TgVJjLD26XIUT6apKyaFwqD rWCejVeOnQYUQUIOikQRQ7h3SEF8p92tULsI7rD12jIMFq5ExMk6eASnswf+H7vl NHitTU8sV9E2XUJ6r6HrOxpuHcLBbCvdLAYsON6D+5q6NrNgmqsVLkumq/rboklZ by97wKF4s6ZYpj5TkP4Xe/AHdqqfmFvyUWXkYII/oBPNiNIs/SJaibOV2+cPxsqh aY+Oq4+3sSlo9ZNIx5Fy5Zgyeds87ZHCjE6cn+wlU2HnUf4zt0u6dXfg5LWHJ4E6 aYJaneY1GmD0Rv2nsCLP6h/Ykwk8EiePYtR8Kgo13atcWSt4gu56j/b7tJy7YYg+ lrKg1D0ReQaDAFpILB5BnhQpBSSzQ30fYMkgUHQQ8xHPvkMED5nCyjC5NK9pJLkh h1V3BuoEkEuorLFExxAolQm0FtmjL9truRtST+P1QMel1jFByxKnSlyFOjpTHPu4 uMpHX8t9Bf/HVHMXwg4qzHggrREbCGbrJPEA3Rx17P3faOHc4uk= =L888 -----END PGP SIGNATURE----- --D0fp/AkkLvNf8KFO--