X-Original-To: alpine-aports@lists.alpinelinux.org Received: from mail-wm0-f66.google.com (mail-wm0-f66.google.com [74.125.82.66]) by lists.alpinelinux.org (Postfix) with ESMTP id 0429C5C4553 for ; Wed, 7 Dec 2016 10:43:55 +0000 (GMT) Received: by mail-wm0-f66.google.com with SMTP id g23so27010494wme.1 for ; Wed, 07 Dec 2016 02:43:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=TYNoC/59YTzhgoBef+Q10yPIgMEBBa2cJbX9p9CW5LY=; b=waaavFhbyE6OFcBJlycPP+fqdT+3hVUuT+UREFg/WSEabU2CFnegMMESmYVnnK7Fu8 R+qVPd0uWmnxsKZteG0CnpCR/5pDQIfHQds6YjxtU4LO38iW0shEwe/pHEjBEcojfq0D UDMP8Qdce8Vy6O64khIZnbn+m5QgRwPYSO7kKepynJilJLNNVpNte9E3w9hZ2PmYqf5l xAR3I8a7zjcOmhPr0oMaPuEY1Y+beFHhiPrBIAnO8FiiDBft1c2MkSmOBNU1aub/wPhE DtN3KyH1+e1Dr2EOUraTFyXyp9pUTKuqB9hzwI6nDT2ZqjUC7GB7vGFe3wgD2cV8x+Zx NqlA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=TYNoC/59YTzhgoBef+Q10yPIgMEBBa2cJbX9p9CW5LY=; b=FxJEQDVyusPC7LX9G3+rmqkgyBpT2yTfkcLML083ACMtNWFgY7TbfW9oD/jSdv0zWg CaPigqz11NmJSQnGEs4+7mqTRIxPpSUsBLCdDUngPgULOwX0NDsho/VP2YHITdJ450ke sotWtv9IahKSb45degHHKxjJ6BNKccpxOJZI3R4H2O6tPCCNghgUhM5C3Cs00JF6ptLn KNmJTC7oPQdWnWOjIMUHkNUMv+meeePr6pu09qf4JlS8f7a/AoTe4Fs1ihxXEZI2bjN4 VsWOFxBzX7XnwSYMbntAT9WdLYtRL0mMQ0dXaoOYhzuN6zArwircIK/5lUbgHfIOixce 705w== X-Gm-Message-State: AKaTC03eDnlQ9p5C1NFSY/2RKY28FvrogRl+pJr0yAczbImROSLECHErA/cfhwADvmMRJQ== X-Received: by 10.25.216.28 with SMTP id p28mr23824862lfg.16.1481097856920; Wed, 07 Dec 2016 00:04:16 -0800 (PST) Received: from vostro (a91-152-109-3.elisa-laajakaista.fi. [91.152.109.3]) by smtp.gmail.com with ESMTPSA id 89sm4539715lja.16.2016.12.07.00.04.16 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 07 Dec 2016 00:04:16 -0800 (PST) Sender: =?UTF-8?Q?Timo_Ter=C3=A4s?= Date: Wed, 7 Dec 2016 10:04:13 +0200 From: Timo Teras To: Przemyslaw Pawelczyk Cc: ncopa@alpinelinux.org, alpine-aports@lists.alpinelinux.org Subject: [alpine-aports] Re: [PATCH v2] main/abuild: Make default_prepare() always end up in "$builddir". Message-ID: <20161207100413.42b9a59f@vostro> In-Reply-To: <20161203190616.5974-1-przemoc@zoho.com> References: <20161203174846.5345-1-przemoc@zoho.com> <20161203190616.5974-1-przemoc@zoho.com> X-Mailer: Claws Mail 3.13.2 (GTK+ 2.24.28; x86_64-alpine-linux-musl) X-Mailinglist: alpine-aports Precedence: list List-Id: Alpine Development List-Unsubscribe: List-Post: List-Help: List-Subscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Sat, 3 Dec 2016 20:06:16 +0100 Przemyslaw Pawelczyk wrote: > ...-default_prepare-always-end-up-in-builddi.patch | 30 > ++++++++++++++++++++++ > main/abuild/APKBUILD | 12 ++++++--- 2 > files changed, 38 insertions(+), 4 deletions(-) create mode 100644 > main/abuild/0004-abuild-Make-default_prepare-always-end-up-in-builddi.patch We generally want abuild patches to first go to abuild.git. > +diff --git a/abuild.in b/abuild.in > +index e49956b76d04..f56ac033f6a9 100644 > +--- a/abuild.in > ++++ b/abuild.in > +@@ -565,10 +565,10 @@ have_patches() { > + > + default_prepare() { > + local i > ++ cd "$builddir" || { error "Is \$builddir set correctly?"; > return 1; } > + if ! have_patches; then > + return 0 > + fi > +- cd "$builddir" || { error "Is \$builddir set correctly?"; > return 1; } > + for i in $source; do > + case $i in > + *.patch) The problem with this is that not abuild's are updated yet to define $builddir. This would make those fail. If it tries to cd there by default, it should at least check that $builddir is defined. This was the logic for cd:ing $builddir: - since not all (yet) set $builddir, don't do it by default - the abuilds that use $_builddir and have patches, should ship their own prepare() so it's assumed that having patches and getting to default_prepare the variable name has been fixed too I'd be ok, if in "if ! have_patches" we check if $builddir is set and cd to it. Thanks, Timo --- Unsubscribe: alpine-aports+unsubscribe@lists.alpinelinux.org Help: alpine-aports+help@lists.alpinelinux.org ---