From owner-freebsd-ports@FreeBSD.ORG Wed Jan 22 07:06:29 2014 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id A4C6C892 for ; Wed, 22 Jan 2014 07:06:29 +0000 (UTC) Received: from mail-ig0-x22e.google.com (mail-ig0-x22e.google.com [IPv6:2607:f8b0:4001:c05::22e]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 737741647 for ; Wed, 22 Jan 2014 07:06:29 +0000 (UTC) Received: by mail-ig0-f174.google.com with SMTP id hl1so13130998igb.1 for ; Tue, 21 Jan 2014 23:06:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=Gp7FAu2nDX29j/d5MW8OnegS2WVc7hXs3MoUgi7IyJo=; b=a6lBJ6QRFJ3IQoRD24G9A7L18bFgVJ2efnzAwVmN1TbGt3o20MdeFMvkv1WPIxiMqD 0F1vIYOV7N2uiYasGAMrSSLx/rTDs85MnWxlRejcLbhce1X2GtqXj7wTb4j4M9vehvWQ 1DbSt91x7jUJ5IiY3CkU5GAaa069O2s33jzXNY+dRIob0Xe/R+U0Za7VePlxWkmwVF+Y KnHeHKRIuudsi9RoaZQeb8toC458fu/SElenokfrb6uyZM7Zyhyt5gWt1AJS224ybpQ/ LcQN+lPXe/nKezJGdrVAhSQ61a3e8HkkBQaM/VEUEe3zvXrG3s1ueDA4yKQVp3C3WTl8 OIUA== MIME-Version: 1.0 X-Received: by 10.42.144.201 with SMTP id c9mr21420996icv.16.1390374388631; Tue, 21 Jan 2014 23:06:28 -0800 (PST) Received: by 10.50.67.84 with HTTP; Tue, 21 Jan 2014 23:06:28 -0800 (PST) In-Reply-To: <52DE3FA5.6040407@gmail.com> References: <92E0B243-3705-437A-80C8-DB9AAF938A3D@conundrum.com> <52DE3FA5.6040407@gmail.com> Date: Wed, 22 Jan 2014 01:06:28 -0600 Message-ID: Subject: Re: per-port make.conf options and hyphenated port names From: Scot Hetzel To: Volodymyr Kostyrko Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable Cc: Matthew Pounsett , FreeBSD Ports X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 Jan 2014 07:06:29 -0000 On Tue, Jan 21, 2014 at 3:36 AM, Volodymyr Kostyrko wro= te: > 21.01.2014 03:01, Matthew Pounsett wrote: >> >> >> At some point in the last couple of weeks I was pointed at >> as what has been >> implemented to deprecate make.conf settings such as =93WITHOUT_X11=3Dyes= =94. >> That document says it has been committed, but the porters handbook secti= on >> on OPTIONS doesn=92t discuss the ${port}_SET/${port}_UNSET syntax, and I= can=92t >> find mention of it in /usr/ports/KNOBS either. >> >> I=92m trying to find specifics on the implementation because I=92ve run = into a >> case that document doesn=92t seem to plan for: trying to set per-port o= ptions >> for a hyphenated port name. >> >> Specifically, I=92m trying to do this: >> virtualbox-ose-additions_UNSET=3DX11 >> >> Hyphenated variable names don=92t work in most shells. I think some old= er >> versions of csh could set them, but couldn't reference them, and tinderb= ox=92s >> sh scripts blow right up when they encounter that. >> >> Digging through /usr/ports/Mk/ I can=92t find anywhere that $UNIQUENAME = is >> modified to guarantee that it references a safe variable name (i.e. I do= n=92t >> see anywhere that $UNIQUENAME has reserved characters removed from it be= fore >> use). So, given that a lot of times $UNIQUENAME is just the name of the >> port, and a lot of ports have hyphens in their names, how is this meant = to >> be dealt with? >> >> Thanks for any pointers or help! > > > Excuse me hijacking the thread but doesn't ports-mgmt/portconf do almost = the > same? > With the change to the new Options frame work, most of the WITH/WITHOUT_ variables were changed to SET/UNSET values: WITH_X11 WITH_JPEG WITHOUT_DOCS New way: SET=3D X11 JPEG UNSET=3D DOCS The old way to set port specific variables was by using ports-mgmt/portconf. But with the change to using SET/UNSET, port specific options are now: ${UNIQUENAME}_SET=3D MYSQL ${UNIQUENAME}_UNSET=3D PGSQL BDB Which can be added directly to the /etc/make.conf. There may still be uses for portconf, as it can still assign values to port specific variables.