Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 18 Apr 2018 08:16:45 +0200
From:      Stefan Esser <se@freebsd.org>
To:        freebsd-ports@freebsd.org
Cc:        "Tobias C. Berner" <tcberner@freebsd.org>, Andriy Gapon <avg@freebsd.org>, "kde@FreeBSD.org" <kde@freebsd.org>, Adriaan de Groot <adridg@freebsd.org>
Subject:   Re: Conflicts due to renamed KDE4 ports
Message-ID:  <ed1132ce-b14c-831b-2f42-170bd5670e13@freebsd.org>
In-Reply-To: <CAOshKtdTR0Ub-tssDD82%2BPWjbEawXZgSzP76rXTyj4oFfYFNfw@mail.gmail.com>
References:  <a9ce1576-a254-4e79-3e50-b90d49827a1e@freebsd.org> <b3297fd4-05a4-f824-4fdd-21227531fc57@freebsd.org> <20180416211329.52e4c0dc@kalimero.tijl.coosemans.org> <18601817.syqV60Bg9A@beastie.bionicmutton.org> <1172371d-ce51-d13b-b421-ff06363ac49e@FreeBSD.org> <CAOshKte2mrETdLA71v0NVQ2KR8UgAy4xZvksihPeeLX0W4mw2A@mail.gmail.com> <20180417174352.797247c9@kalimero.tijl.coosemans.org> <CAOshKtdTR0Ub-tssDD82%2BPWjbEawXZgSzP76rXTyj4oFfYFNfw@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Am 17.04.18 um 20:29 schrieb Tobias C. Berner:
> Moin moin
> 
> Here's a script which should automatically fix the origin for the
> kde4-versioned ports (based on the MOVED entries of r465345):
>    http://people.freebsd.org/~tcberner/scripts/fix_kde4_origins.sh
> 
> It //should// set the origins properly for the moved ports, and the output
> should be on the lines of
> # ./fix_kde4_origins.sh
> [...]
> - sysutils/baloo-widgets [sysutils/baloo-widgets-kde4] is not installed.
> + Changing origin of nepomuk-core-4.14.3_14 from sysutils/nepomuk-core to
> sysutils/nepomuk-core-kde4.
> - sysutils/kfloppy [sysutils/kfloppy-kde4] is not installed.
> - sysutils/ksystemlog [sysutils/ksystemlog-kde4] is not installed.
> + Changing origin of baloo-4.14.3_5 from sysutils/baloo to sysutils/baloo-kde4.
> + Changing origin of kfilemetadata-4.14.3_13 from sysutils/kfilemetadata to
> sysutils/kfilemetadata-kde4.
> [...]
> 
> 
> Please let me know if that works for you, or how I could improve it.

My suggested version (that does not depend on any hard-coded version
strings in the script) is:

#!/bin/sh

cd /usr/ports
for origin in */*-kde4; do
        origin_old=$(dirname $origin)/$(basename $origin -kde4)
        pkgname=$(make -C $origin -V PKGNAME)
        pkg_glob="${pkgname%%.*}.*"
        package=$(pkg query -g "%n-%v" "$pkg_glob")
        pkg set -y -o $origin_old:$origin $package
done

Regards, STefan



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?ed1132ce-b14c-831b-2f42-170bd5670e13>