X-Original-To: alpine-devel@lists.alpinelinux.org Received: from mx1.tetrasec.net (mx1.tetrasec.net [74.117.190.25]) by lists.alpinelinux.org (Postfix) with ESMTP id F02935C4EEE for ; Fri, 30 Jun 2017 05:52:40 +0000 (GMT) Received: from mx1.tetrasec.net (mail.local [127.0.0.1]) by mx1.tetrasec.net (Postfix) with ESMTP id 93B699E22CD; Fri, 30 Jun 2017 05:52:40 +0000 (GMT) Received: from ncopa-desktop.copa.dup.pw (15.63.200.37.customer.cdi.no [37.200.63.15]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: n@tanael.org) by mx1.tetrasec.net (Postfix) with ESMTPSA id B9F8A9E20AC; Fri, 30 Jun 2017 05:52:39 +0000 (GMT) Date: Fri, 30 Jun 2017 07:52:33 +0200 From: Natanael Copa To: "A. Wilcox" Cc: alpine-devel@lists.alpinelinux.org Subject: Re: [alpine-devel] RFC: Distribution variables for abuild Message-ID: <20170630075233.47637483@ncopa-desktop.copa.dup.pw> In-Reply-To: <594F59F5.5000104@adelielinux.org> References: <594F59F5.5000104@adelielinux.org> X-Mailer: Claws Mail 3.15.0-dirty (GTK+ 2.24.31; x86_64-alpine-linux-musl) X-Mailinglist: alpine-devel Precedence: list List-Id: Alpine Development List-Unsubscribe: List-Post: List-Help: List-Subscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On Sun, 25 Jun 2017 01:36:37 -0500 "A. Wilcox" wrote: ... > I hereby propose adding the following four variables to abuild.conf, > with the default values in abuild being appropriate for Alpine. >=20 > :``${DISTRO_NAME}``: > The name of the distribution, such as "Alpine Linux" or > "Ad=E9lie Linux". >=20 > :``${DISTRO_SHORT_NAME}``: > A single word describing the distribution, such as "Alpine" or > "Adelie". >=20 > :``${DISTRO_URL}``: > The home page of the distribution, i.e. "https://alpinelinux.org". >=20 > :``${DISTRO_BUG_URL}``: > The URL to use to report bugs with software on the distribution. > This would be set to "https://bugs.alpinelinux.org" by default. I think this is a good idea. It is trivial to implement and does not cause any maintenance burden. ... > Roadmap > - ------- >=20 > Since the shell environment is flexible, this change can be > implemented almost immediately; the defaults specified ensure that at > worst, nothing will change. As forks and spins change the environment > variables in their ``abuild.conf`` files, all updated packages will > immediately reflect those changes. How much code is needed in abuild? I think we could start with the APKBUILD= s: ${DISTRO_URL:-https://alpinelinux.org} That way you can override the default and we are still backwards compatible. No code changes in abuild required to get started. This makes it also possible backport security and bug fixes to stable branches if needed. > If there is interest, I would be happy to work on the abuild code and > adding the variables in relevant APKBUILDs. There are a few packages > that don't specify bug report URLs where they could; I could > additionally add support there, if desired. Yes. This would be great! > One alternative is sourcing this information from ``/etc/os-release`` > instead of ``abuild.conf``, or using os-release when abuild.conf does > not have anything set. Nah, I like your proposal better. =20 > Thank you for your time in reviewing this proposal. If you have any > questions or concerns or changes, I would love to discuss them. I'm > open to any comments the community has. Are you ok with using the style ${DISTRO_NAME:-Alpine Linux} in the APKBUILDs? Something like: diff --git a/main/alpine-base/APKBUILD b/main/alpine-base/APKBUILD index e5cfeba83f..58980b5273 100644 --- a/main/alpine-base/APKBUILD +++ b/main/alpine-base/APKBUILD @@ -26,7 +26,7 @@ package() { =20 # create /etc/issue cat >"$pkgdir"/etc/issue<"$pkgdir"/etc/os-release<