From owner-freebsd-ports@freebsd.org Tue Oct 18 13:52:49 2016 Return-Path: Delivered-To: freebsd-ports@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E2DBFC16EE4 for ; Tue, 18 Oct 2016 13:52:49 +0000 (UTC) (envelope-from matthew@FreeBSD.org) Received: from smtp.infracaninophile.co.uk (smtp.infracaninophile.co.uk [81.2.117.100]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "smtp.infracaninophile.co.uk", Issuer "infracaninophile.co.uk" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 8266C13B for ; Tue, 18 Oct 2016 13:52:49 +0000 (UTC) (envelope-from matthew@FreeBSD.org) Received: from ox-dell39.ox.adestra.com (unknown [85.199.232.226]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: m.seaman@infracaninophile.co.uk) by smtp.infracaninophile.co.uk (Postfix) with ESMTPSA id E09A74F61; Tue, 18 Oct 2016 13:52:41 +0000 (UTC) Authentication-Results: smtp.infracaninophile.co.uk; dmarc=none header.from=FreeBSD.org Authentication-Results: smtp.infracaninophile.co.uk/E09A74F61; dkim=none; dkim-atps=neutral Subject: Re: private ports and pkgs versioning To: Mark Linimon References: <1cba6ef9-89af-c3b8-48df-0cbdc8499b6c@freebsd.org> <20161018125414.GA18517@lonesome.com> Cc: freebsd-ports@freebsd.org From: Matthew Seaman Message-ID: Date: Tue, 18 Oct 2016 14:52:34 +0100 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: <20161018125414.GA18517@lonesome.com> Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="c3mG4b8Vqs55urubdw8LqKbN8qTgxAVhj" X-Spam-Status: No, score=-0.4 required=5.0 tests=BAYES_00,RDNS_NONE, SPF_SOFTFAIL autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on smtp.infracaninophile.co.uk X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Oct 2016 13:52:50 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --c3mG4b8Vqs55urubdw8LqKbN8qTgxAVhj Content-Type: multipart/mixed; boundary="6WUJBtrV9EED5DE67qffHCWqwIqNmTke6"; protected-headers="v1" From: Matthew Seaman To: Mark Linimon Cc: freebsd-ports@freebsd.org Message-ID: Subject: Re: private ports and pkgs versioning References: <1cba6ef9-89af-c3b8-48df-0cbdc8499b6c@freebsd.org> <20161018125414.GA18517@lonesome.com> In-Reply-To: <20161018125414.GA18517@lonesome.com> --6WUJBtrV9EED5DE67qffHCWqwIqNmTke6 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 10/18/16 13:54, Mark Linimon wrote: > On Tue, Oct 18, 2016 at 08:49:06AM +0100, Matthew Seaman wrote: >> Yes, there is a lot of useful stuff in the ports tree to support local= >> ports or even whole local categories of ports. I can't recall now how= I >> learned about all this stuff -- it may well have been just be a >> combination of reading Makefiles and hints dropped on mailing lists. = I >> cannot recall a document describing this stuff anywhere. >=20 > I don't believe that there is one. >=20 > I'm sure there are N locally-grown solutions out in the wild. >=20 > We ought to work together to poll people on what they use. >=20 > As for adding the category, I think there's a quick fix, if you don't > care about building INDEX. Add USE_LOCAL_MK=3Dyes to your Makefile > invocations, and use the patch below. >=20 > Note: I haven't tried this yet, so adding the category to ports/Makefil= e > may also be necessary to pacify ports/Mk/bsd.port.subdir.mk (e.g. INDEX= =2E) >=20 > Index: ports/Mk/bsd.local.mk > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > --- ports/Mk/bsd.local.mk (revision 423944) > +++ ports/Mk/bsd.local.mk (working copy) > @@ -14,6 +14,8 @@ > # time should live. > # > =20 > +VALID_CATEGORIES+=3D local > + > .endif # !defined(_POSTMKINCLUDED) && !defined(Local_Pre_Include) > =20 > .if defined(_POSTMKINCLUDED) && !defined(Local_Post_Include) >=20 > mcl >=20 In many places in the ports you can drop in a Makefile.local that gets unconditionally included into the existing Makefile at that level. There are several names that get treated similarly -- so you can have (I think) Makefile.amd64 which is only included when compiling for that architecture. The idea being if you add a whole new file, you won't get merge conflicts when updating from SVN. There's a Makefile.inc that goes one level above that gets included similarly. Unfortunately it looks like this doesn't apply at the very top level of the ports, otherwise this would be a really easy way of adding a custom category. Hmmm... looks like this is handled in the 30 or so lines starting at line 1179 of bsd.port.mk Cheers, Matthew --6WUJBtrV9EED5DE67qffHCWqwIqNmTke6-- --c3mG4b8Vqs55urubdw8LqKbN8qTgxAVhj Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQIcBAEBCgAGBQJYBikiAAoJEABRPxDgqeTn8qMQALGseBCozFHSDqA81uiae7/Y 7d9Er+AH/I7LRNBv8FqNs960TGyYyLKG5QXZ0lLxliZv/+jrV+BTtZQ7Z04wiaiH kQIYcuVaPF+BLsxDv2MrKJYLlibCbx3sRGzlDncRqTOaTsyeK//2TYO1s0OUNI3T ek6sO76t0T+WYt2OKsHEgURmytE/XewT62299eYBOvIRsxJFF3DVQ7h0Bg8AkAyL Xcb6iJwwpebLyOnT20yGmaFBdGi5CUbhmsweVOZEq0fTunrF+6dZ4lUna2fTBkzP 4Nts+qOAY0I2FnvjOqJZf0KFVt1l3RW4d1uhoUcUWelGrUehtYP5n4MGAtzcpi89 VhPogI0kQYE1xhZj4YPvXDpYzecPO8xbQh2MpZFhjVR9BByq9IXx1degINFaleUE WVw7tHVeUIu1GmREO8c3035ESCTca2wqB7dMbJxJuDhYkQHkNvc0arwX5vdHKcEC lhFe6bDwXnA1uDmOGMYoyJNG22NgP3MkSXQySX4a4ORP1/pU3L+wmSm5B/f89Mv7 az0z5AKbNAWD2rfrI6HYz80k3voNlSvWAufG9MpGXcDxYnGPE2psiFuHIkLEzl/+ pI/QMLf2JQOiZLgOTHytAQELLP8QQreBqayt3M7VBPGreymafBZUx/cFO8SAt9U4 l4LqalpNb7gwzNgPBist =hLNx -----END PGP SIGNATURE----- --c3mG4b8Vqs55urubdw8LqKbN8qTgxAVhj--