Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 6 May 2019 18:03:32 -0700
From:      Kevin Oberman <rkoberman@gmail.com>
To:        Bob Willcox <bob@immure.com>
Cc:        "Matthew D. Fuller" <fullermd@over-yonder.net>, FreeBSD Ports ML <freebsd-ports@freebsd.org>,  Stefan Esser <se@freebsd.org>
Subject:   Re: portupgrade + FLAVORS
Message-ID:  <CAN6yY1t4wtdrV6gfcwqrQOWrQuoz54_d=w=8UU-fNvzVR9fOTQ@mail.gmail.com>
In-Reply-To: <20190506181756.GK44790@rancor.immure.com>
References:  <20190408015157.GE6019@over-yonder.net> <20190506181756.GK44790@rancor.immure.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Looks like the maintainer should be on the CC, so I added Stefan.
--
Kevin Oberman, Part time kid herder and retired Network Engineer
E-mail: rkoberman@gmail.com
PGP Fingerprint: D03FB98AFA78E3B78C1694B318AB39EF1B055683


On Mon, May 6, 2019 at 11:35 AM Bob Willcox <bob@immure.com> wrote:

> On Sun, Apr 07, 2019 at 08:51:57PM -0500, Matthew D. Fuller wrote:
> > For any portupgrade users still out there wishing for FLAVOR support,
> > I have patches to add it.  I've been running them here locally for a
> > few weeks without incident (apart from an extra upgrade or two
> > actually working without manual intervention/resort to portmaster,
> > that is).  Dropping the attached patch into
> > $PORTS/ports-mgmt/portupgrade/files/patch-flavors and rebuilding it is
> > a simple shortcut to getting it in place.
> >
> > I haven't done any testing of using portupgrade with pre-built
> > packages (is there even any reason to post-pkg?), or using portinstall
> > (never saw the point), but it seems to handle the upgrading path just
> > fine.
> >
> >
> > Also sitting in a PR upstream at
> > https://github.com/freebsd/portupgrade/pull/72
> >
> >
> > --
> > Matthew Fuller     (MF4839)   |  fullermd@over-yonder.net
> > Systems/Network Administrator |  http://www.over-yonder.net/~fullermd/
> >            On the Internet, nobody can hear you scream.
>
> > --- bin/portupgrade.orig      2018-03-09 18:59:29 UTC
> > +++ bin/portupgrade
> > @@ -1147,6 +1147,11 @@ def get_make_args(origin, pkgname = nil)
> >    else
> >      args = $make_args.split(' ')
> >    end
> > +
> > +  if flavor = origin[/@(.+)$/, 1]
> > +    args << 'FLAVOR=' + flavor
> > +  end
> > +
> >    quoted = 0
> >    n = 0
> >    is_quoted = false
> > --- lib/pkgtools/pkgdb.rb.orig        2018-03-09 18:59:29 UTC
> > +++ lib/pkgtools/pkgdb.rb
> > @@ -425,10 +425,20 @@ class PkgDB
> >        @installed_pkgs = []
> >        @installed_ports = []
> >        @db = {}
> > +
> > +      flavors = {}
> > +      pkg_flavors = xbackquote(PkgDB::command(:pkg), 'annotate', '-Sa',
> > +                               'flavor').split("\n")
> > +      pkg_flavors.each do |line|
> > +        pkg, flavor = line.sub(/: Tag: flavor Value: /, ':').split(':')
> > +        flavors[pkg] = flavor
> > +      end
> > +
> >        pkg_origins = xbackquote(PkgDB::command(:pkg), 'query', '%n-%v
> %o').split("\n")
> >        pkg_origins.each do |line|
> >          pkg, origin = line.split(' ')
> >          @installed_pkgs << pkg
> > +        origin << '@' + flavors[pkg] if flavors[pkg]
> >          add_origin(pkg, origin)
> >        end
> >        @installed_pkgs.freeze
> > --- lib/pkgtools/portsdb.rb.orig      2018-03-09 18:59:29 UTC
> > +++ lib/pkgtools/portsdb.rb
> > @@ -325,6 +325,7 @@ class PortsDB
> >    end
> >
> >    def portdir(port)
> > +    port = port.sub(/@.*$/, '')
> >      File.join(ports_dir, port)
> >    end
> >
>
> > _______________________________________________
> > freebsd-ports@freebsd.org mailing list
> > https://lists.freebsd.org/mailman/listinfo/freebsd-ports
> > To unsubscribe, send any mail to "freebsd-ports-unsubscribe@freebsd.org"
>
> Hi Mathew,
>
> Thanks for the flavors patch to portupgrade. As with some others here it is
> still my preferred tool for keeping my ports up-to-date.
>
> Any word on when/if your patch will be integraded into the port proper?
>
> Thanks again,
> Bob
>
>
> --
> Bob Willcox    | "The only way to get rid of temptation is to yield to
> it...
> bob@immure.com | I can resist everything but temptation."
> Austin, TX     |     - Oscar Wilde
> _______________________________________________
> freebsd-ports@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-ports
> To unsubscribe, send any mail to "freebsd-ports-unsubscribe@freebsd.org"
>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAN6yY1t4wtdrV6gfcwqrQOWrQuoz54_d=w=8UU-fNvzVR9fOTQ>