[Bug 259259] Mk/Uses/emacs.mk: Remove Emacs major version from EMACS_PKGNAMESUFFIX

From: <bugzilla-noreply_at_freebsd.org>
Date: Thu, 21 Oct 2021 15:40:51 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=259259

--- Comment #6 from Yasuhiro Kimura <yasu@freebsd.org> ---
(In reply to Joseph Mingrone from comment #3)

> 2. It looks like the transition won't be smooth.  This doesn't happen without the patch.  Maybe we just need to bump PORTVERSION?

Certainly it is the hurdle that need to be overcome.

At first PORTVERSION of all dependent ports need to be bump to rebuild packages
with new EMACS_PKGNAMESUFFIX. Based on it, for portmaster user it is properly
handled with `portmaster -a`.  But for binary packages user it isn't so easy to
handle it. Since package name of dependent ports change, `pkg` command regards
them as orphaned. And unfortunately I can't find the way to upgrading orphaned
package without once removing and reinstalling them. So following steps are
probably easiest and most reliable.

1. Execute `pkg query -a '%a %o' | awk '$1==0 {print $2}' | sort >
/tmp/package-origin-list.txt`. This command creates the list of origin of
packages manually installed by user.
2. Remove Emacs and dependent packages with `pkg remove -g 'emacs*'`.
3. Execute `pkg query -a '%a %o' | awk '$1==0 {print $2}' | sort | diff
/tmp/package-origin-list.txt -`. This command shows manually installed packages
removed by step 2.
4. Install each package showed by step 3 with `pkg install`.

-- 
You are receiving this mail because:
You are on the CC list for the bug.