From nobody Mon Sep 6 13:40:47 2021 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 87B9217A1C53 for ; Mon, 6 Sep 2021 13:40:50 +0000 (UTC) (envelope-from bapt@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 4H38g63NVRz3Hbc; Mon, 6 Sep 2021 13:40:50 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from aniel.nours.eu (nours.eu [176.31.115.77]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) (Authenticated sender: bapt) by smtp.freebsd.org (Postfix) with ESMTPSA id 3D83C22D42; Mon, 6 Sep 2021 13:40:50 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: by aniel.nours.eu (Postfix, from userid 1001) id EEFFDAF01B; Mon, 6 Sep 2021 15:40:47 +0200 (CEST) Date: Mon, 6 Sep 2021 15:40:47 +0200 From: Baptiste Daroussin To: Mel Pilgrim Cc: freebsd-ports@freebsd.org Subject: Re: Why no flavor_USES helper? Message-ID: <20210906134047.vs2jfg5dsz7c3jm2@aniel.nours.eu> References: <8982e300-8b04-f31a-9c49-43d0dd428b38@bluerosetech.com> <20210906081612.rxo2os7dvx5mkvz6@aniel.nours.eu> <1f0f9a6c-09a6-86f9-625f-e9e482dc0e83@bluerosetech.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: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1f0f9a6c-09a6-86f9-625f-e9e482dc0e83@bluerosetech.com> X-Spam: Yes X-ThisMailContainsUnwantedMimeParts: N On Mon, Sep 06, 2021 at 06:33:29AM -0700, Mel Pilgrim wrote: > On 2021-09-06 1:16, Baptiste Daroussin wrote: > > On Sun, Sep 05, 2021 at 10:39:29AM -0700, Mel Pilgrim wrote: > > > The flavors helpers like flavor_RUN_DEPENDS are super useful, but I need to > > > modify USES based on flavor, and find that there is no helper for it. > > > > Besause USES are loader 100 lines earlier, meaning only USES are already > > processed when we expand the helper. > > > > Without getting to far in the technical details, USES and FLAVORS are basically > > expanded at the moment, in pre and post section, meaning one had to decide > > either we should allow USES to define flavors, or we should allow USES helpers. > > Is this why there odd race conditions between USES and FLAVORS where, for > example, if I have a FLAVOR that does USES+=pgsql and WANT_PGSQL, the > corresponding postgresqlN-* ports aren't added to *_DEPENDS? I don't know, neither heard of that specific case, but it could be, if so, that sound like a bug in pgsql.mk, I am interesting in an example that show this behaviour. Best regards, Bapt