From owner-freebsd-ports@FreeBSD.ORG Tue Aug 25 23:40:19 2009 Return-Path: Delivered-To: ports@freebsd.org Received: from straylight.ringlet.net (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by hub.freebsd.org (Postfix) with SMTP id 292431065690 for ; Tue, 25 Aug 2009 23:40:17 +0000 (UTC) (envelope-from roam@ringlet.net) Received: (qmail 2229 invoked by uid 1000); 25 Aug 2009 23:40:16 -0000 Date: Wed, 26 Aug 2009 02:40:16 +0300 From: Peter Pentchev To: Kevin Oberman Message-ID: <20090825234016.GC1087@straylight.m.ringlet.net> References: <20090825225001.GA1087@straylight.m.ringlet.net> <20090825231551.3A3131CC09@ptavv.es.net> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="uh9ZiVrAOUUm9fzH" Content-Disposition: inline In-Reply-To: <20090825231551.3A3131CC09@ptavv.es.net> User-Agent: Mutt/1.5.20 (2009-06-14) Cc: ports@freebsd.org, ahze@freebsd.org Subject: Re: serpentine port forces dependency on muine X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 25 Aug 2009 23:40:19 -0000 --uh9ZiVrAOUUm9fzH Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Aug 25, 2009 at 04:15:51PM -0700, Kevin Oberman wrote: > > Date: Wed, 26 Aug 2009 01:50:01 +0300 > > From: Peter Pentchev > >=20 > > On Tue, Aug 25, 2009 at 11:06:18AM -0700, Kevin Oberman wrote: > > > I have been trying to remove all dependencies on the broken muine port > > > and discovered that an error in the serpentine port Makefile causes > > > serpentine to always depend on muine. > > >=20 > > > The Makefile uses the config option MUINE to indicate whether to build > > > the muine plugin, but the script then checks "WITH_MUINE" and always > > > build the muine plugin and creates a dependency on muine. > > >=20 > > > I have opened PR ports/138179. > > >=20 > > > I patched the Makefile with: > > > --- sysutils/serpentine/Makefile.orig 2009-08-25 10:45:24.000000000 -= 0700 > > > +++ sysutils/serpentine/Makefile 2009-08-25 10:07:00.000000000 -0700 > > > @@ -29,7 +29,7 @@ > > > =20 > > > .include > > > =20 > > > -.if (defined(WITH_MUINE) || exists(${LOCALBASE}/bin/muine)) && ${ARC= H}=3D=3D"i386" > > > +.if (defined(MUINE) || exists(${LOCALBASE}/bin/muine)) && ${ARCH}=3D= =3D"i386" > > > BUILD_DEPENDS+=3D muine:${PORTSDIR}/audio/muine > > > RUN_DEPENDS+=3D muine:${PORTSDIR}/audio/muine > > > PLIST_SUB+=3D MUINE=3D"" > >=20 > > Errrr... > >=20 > > I strongly doubt that this is the reason for your problems. > >=20 > > Actually, this is exactly how the Ports Collection's "options" framework > > is supposed to work: the OPTIONS variable lists just the names of > > the options, then bsd.port.mk prompts the user through a dialog > > (or just uses the options' default values) and sets either WITH_name > > or WITHOUT_name. The port then checks for WITH_name or WITHOUT_name, > > just as it does in this case. The option is named "MUINE", but > > the bsd.port.mk framework will set "WITH_MUINE" if the user wants it, > > or WITHOUT_MUINE if she doesn't (or building in batch mode, since > > the option defaults to Off). > >=20 > > So the Makefile check is actually correct. > >=20 > > I find it a little bit hard to believe that it is exactly this change > > to the Makefile that helped you get a serpentine build without muine. > > Could it be that, in the meantime, you had also removed the muine > > port itself? The Makefile check will be satisfied if the MUINE option > > is enabled *or* if the "muine" executable is present in /usr/local/bin. > > This is most probably because the serpentine configure script looks for > > muine itself and uses it unconditionally if it finds it. > >=20 > > So... maybe you just had a /usr/local/bin/muine, and that made > > the serpentine port always build with it? Because the Makefile check > > is actually correct as per the ports options framework :/ >=20 > Ack. You are correct. >=20 > If muine found in /usr/local/bin/, it will be built with the plug-in, > regardless of which way the MUINE configure option is set because: > .if (defined(MUINE) || exists(${LOCALBASE}/bin/muine)) && ${ARCH}=3D=3D"i= 386" >=20 > As a result, you can't deinstall muine as serpentine depends on it, but > you can't build serpentine without a dependency on muine until you > deinstall muine. I am confused as to the whole point of this structure. > If muine is installed, serpentine will be built with the plugin...end of > story. The configuration option does nothing. The only effect it has is > to force the installation of muine on the initial install muine is not > already installed. This structure is probably targeted at the case of the port being built on a clean system (or at least a clean-ish system). From your explanations, it seems to me that you are considering the case of the port being built while a previous version of serpentine is still installed on the system. While this is, indeed, convenient, and maybe it is the way it's done by some port building helper tools, IMHO it's a bit risky: I always prefer to build ports without having another instance of the port installed to avoid the danger of the port picking up some of "its own" pieces from the older, currently installed version. I've had trouble in the past with ftp/curl - for some reason or other, the test suite sometimes picked up the libcurl.so from /usr/local/lib/ and not the one it was *supposed* to use (its own, in its own build directory) - thus the tests for *newer* features failed. There could be other ways in which this could pose problems. Of course, this is merely my humble opinion, and I do realize the convenience of still having the port installed while you build its newer version - the old-fashioned way I do things leaves me X-less and Firefox-less for hours at a time on big upgrades :) Still, I'm saying this in the hope that you will see the case that the port maintainer had in mind when writing the Makefile :) (it's valid for the automated package build systems, too) > I guess the right way is to change the statement to read: > .if defined(MUINE) && ${ARCH}=3D=3D"i386" "MUINE" is never defined, or at least not by the Ports Options framework. It's either WITH_MUINE or nothing. In this particular case, removing the check could work. In my previous message I mentioned the possibility of serpentine unconditionally using muine if found; from a quick look at the serpentine's configure script, it doesn't do that. I've known pieces of software that do (yes, gtkpod, I'm looking at you now, with a malicious gleam in my eye). > Or, since muine looks to be dead, just rip out the muine stuff. I believe that's for the maintainer to decide :) G'luck, Peter --=20 Peter Pentchev roam@ringlet.net roam@space.bg roam@FreeBSD.org PGP key: http://people.FreeBSD.org/~roam/roam.key.asc Key fingerprint FDBA FD79 C26F 3C51 C95E DF9E ED18 B68D 1619 4553 "yields falsehood, when appended to its quotation." yields falsehood, when = appended to its quotation. --uh9ZiVrAOUUm9fzH Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.12 (FreeBSD) iEYEARECAAYFAkqUdmAACgkQ7Ri2jRYZRVNfdACeM2NnV3pCQzsEUsTmTNliWK0Z 5eYAnR7ht9n0aUZzx7L8bAU0gpUqqRlm =yEZj -----END PGP SIGNATURE----- --uh9ZiVrAOUUm9fzH--