Bug 285674 - editors/emacs: 30.1,3 clashes with gcc13-devel
Summary: editors/emacs: 30.1,3 clashes with gcc13-devel
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: emacs@FreeBSD.org (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-03-26 13:31 UTC by martin
Modified: 2025-04-22 20:32 UTC (History)
4 users (show)

See Also:
bugzilla: maintainer-feedback? (emacs)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description martin 2025-03-26 13:31:54 UTC
After upgrading pkgs from emacs-29.4,3 to emacs-30.1,3, it is impossible to install gcc13-devel without uninstalling emacs:

$ pkg install gcc13-devel
Updating FreeBSD repository catalogue...
FreeBSD repository is up to date.
All repositories are up to date.
Checking integrity... done (2 conflicting)
  - gcc13-devel-13.3.1.s20241227 conflicts with gcc13-13.3.0 on /usr/local/bin/i386-portbld-freebsd13.4-c++13
  - gcc13-devel-13.3.1.s20241227 conflicts with gcc13-13.3.0 on /usr/local/bin/i386-portbld-freebsd13.4-c++13
Checking integrity... done (0 conflicting)
The following 3 package(s) will be affected (of 0 checked):

Installed packages to be REMOVED:
	emacs: 30.1,3
	gcc13: 13.3.0

New packages to be INSTALLED:
	gcc13-devel: 13.3.1.s20241227

Number of packages to be removed: 2
Number of packages to be installed: 1

This worked with emacs-29.4,3.  It looks like a new runtime dependency on gcc13 was added to emacs-30.1.
Comment 1 Herbert J. Skuhra 2025-03-26 20:27:04 UTC
(In reply to martin from comment #0)
Native compilation is now ON by default. It requires gcc and default gcc version is 13. gcc13 conflicts with gcc13-devel. This is not a bug.
Comment 2 Joseph Mingrone freebsd_committer freebsd_triage 2025-03-26 21:05:45 UTC
What Herbert said.

The only quick workaround is to disable the NATIVECOMP option and build your own package.  With NATIVECOMP off, Emacs won't pull in GCC. 

I'm CCing salvadore@, the maintainer of the GCC ports. sSalvadore@, have you considered allowing different GCC versions to be installed simultaneously?"
Comment 3 martin 2025-03-27 12:29:18 UTC
OK, I see there was an attempt to announce this by adding files/pkg-message.in, but I didn't see that.  Nothing was printed when I upgraded, and pkg info -D emacs displays this:

emacs-30.1,3:
On upgrade from emacs<27.1,3:
The major version of editors/emacs was bumped from 26 to 27.  To upgrade
dependent packages, run these commands with superuser privileges:

    # sh
    # for i in $(pkg query -g %n '*-emacs26*'); do \
        nn=$(echo "$i" | sed -e 's/emacs26/emacs27/'); \
        pkg set -yn "$i":"$nn"; \
      done;
    # pkg upgrade

which is the contents of pkg-message.  Possibly having both files causes problems in the build?

I am using the pkg from pkg+http://pkg.FreeBSD.org/${ABI}/quarterly:

Annotations    :
	FreeBSD_version: 1304000
	build_timestamp:2 025-02-27T01:52:57+0000
	built_by       : poudriere-git-3.4.2
	cpe            : cpe:2.3:a:gnu:emacs:30.1:::::freebsd13:x86
	flavor         : full
	port_checkout_unclean: no
	port_git_hash  : f415fceb0
	ports_top_checkout_unclean: no
	ports_top_git_hash: e86ab40be
	repo_type      : binary
	repository     : FreeBSD
Comment 4 martin 2025-03-27 12:30:08 UTC
Maybe a message about native compilation should also be added to the ports UPDATING file?
Comment 5 Joseph Mingrone freebsd_committer freebsd_triage 2025-03-27 17:09:00 UTC
(In reply to martin from comment #3)

Thanks for pointing out the pkg-message issues.  A fix is pending.

https://reviews.freebsd.org/D49539
Comment 6 commit-hook freebsd_committer freebsd_triage 2025-04-04 20:21:37 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=8209af7d187b6b2c2d4553f575510e4ff39311e7

commit 8209af7d187b6b2c2d4553f575510e4ff39311e7
Author:     Joseph Mingrone <jrm@FreeBSD.org>
AuthorDate: 2025-03-27 12:53:06 +0000
Commit:     Joseph Mingrone <jrm@FreeBSD.org>
CommitDate: 2025-04-04 20:18:14 +0000

    editors/emacs: Add pkg-message to SUB_FILES

    While here, remove old pkg-message and redundancy in
    files/pkg-message.in.

    PR:             285674
    Reported by:    martin@lispworks.com
    Differential Revision:  https://reviews.freebsd.org/D49539

 editors/emacs/Makefile             |  2 +-
 editors/emacs/files/pkg-message.in | 45 +-------------------------------------
 editors/emacs/pkg-message (gone)   | 16 --------------
 3 files changed, 2 insertions(+), 61 deletions(-)