[MacPorts] #73965: glib2 upgrade fails: "Error: GLib: identifier not found on the first line"

MacPorts noreply at macports.org
Mon May 4 11:37:10 UTC 2026


#73965: glib2 upgrade fails: "Error: GLib: identifier not found on the first line"
-----------------------+----------------------
  Reporter:  kwolcott  |      Owner:  mascguy
      Type:  defect    |     Status:  assigned
  Priority:  Normal    |  Milestone:
 Component:  ports     |    Version:
Resolution:            |   Keywords:
      Port:  glib2     |
-----------------------+----------------------

Comment (by neverpanic):

 Replying to [comment:9 reneeotten]:
 > It should be using the {{{gobject-intospection-bootstrap}}} port to
 build {{{glib2}}} but perhaps something from the old {{{gobject-
 introspection}}} port is picked up. Could you try to deactivate that port
 and try again?
 >
 > If that works we should probable add a deactivate-hack.

 I think you need the deactivate hack regardless, since things break now
 without it:

 {{{
 --->  Upgrading glib2 (17/37)
 --->  Computing dependencies for glib2
 --->  Fetching archive for glib2
 --->  Archive not available for glib2, building locally
 --->  Fetching distfiles for glib2
 --->  Verifying checksums for glib2
 --->  Extracting glib2
 Warning: The following existing files were hidden from the build system by
 trace mode:
   /opt/dports/.git/HEAD
   /private/var/select/sh
 Warning: The following file inside the MacPorts prefix not installed by a
 port was accessed:
   /opt/local/etc/gitconfig
 --->  Applying patches to glib2
 Warning: The following existing file was hidden from the build system by
 trace mode:
   /private/var/select/sh
 --->  Configuring glib2
 Warning: The following existing files were hidden from the build system by
 trace mode:
 /opt/local/Library/Frameworks/Python.framework/Versions/3.14/lib/python3.14
 /site-packages/packaging/__init__.py
   /opt/local/bin/ar
   /opt/local/bin/bash
   /opt/local/bin/cmake
   /opt/local/bin/git
   /opt/local/bin/ld
   /opt/local/bin/xmllint
   /opt/local/lib/pkgconfig/dbus-1.pc
   /opt/local/share/pkgconfig/bash-completion.pc
   /private/var/select/sh
 Warning: Configuration logfiles contain indications of -Wimplicit-
 function-declaration; check that features were not accidentally disabled:
   statx: found in build/meson-logs/meson-log.txt
   ppoll: found in build/meson-logs/meson-log.txt
 Warning: Configuration logfiles contain indications of -Wincompatible-
 function-pointer-types; check that features were not accidentally
 disabled:
   found in build/meson-logs/meson-log.txt
 --->  Building glib2
 Warning: The following existing files were hidden from the build system by
 trace mode:
 /opt/local/Library/Frameworks/Python.framework/Versions/3.14/lib/python3.14
 /site-packages/packaging/__init__.py
   /opt/local/bin/ar
   /opt/local/bin/gdk-pixbuf-pixdata
   /opt/local/bin/git
   /opt/local/bin/nm
   /opt/local/bin/otool
   /opt/local/bin/ranlib
   /opt/local/bin/xmllint
   /opt/local/lib/libgirepository-1.0.dylib
   /private/var/select/sh
 Warning: The following file inside the MacPorts prefix not installed by a
 port was accessed:
   /opt/local/lib/gio/modules/giomodule.cache
 --->  Staging glib2 into destroot
 Warning: The following existing files were hidden from the build system by
 trace mode:
   /opt/local/bin/git
   /opt/local/bin/otool
   /private/var/select/sh
   /var/root/.CFUserTextEncoding
 --->  Installing glib2 @2.88.0_0+quartz
 --->  Cleaning glib2
 --->  Computing dependencies for glib2
 --->  Deactivating glib2 @2.78.4_3+quartz
 --->  Cleaning glib2
 --->  Activating glib2 @2.88.0_0+quartz
 Error: Failed to activate glib2: The following ports have active files
 that conflict with glib2's:
 gobject-introspection @1.78.1_8
   /opt/local/lib/girepository-1.0/GLib-2.0.typelib
   /opt/local/lib/girepository-1.0/GModule-2.0.typelib
   /opt/local/lib/girepository-1.0/GObject-2.0.typelib
   (... 5 more not shown)
 Image error: Conflicting file(s) present. Please deactivate the
 conflicting port(s) first, or use 'port -f activate glib2' to force the
 activation.
     while executing
 "throw registry::image-error $msg"
     ("foreach" body line 35)
     invoked from within
 "foreach file $imagefiles {
                 incr progress_step
                 _progress update $progress_step $progress_total_steps
                 se..."
     invoked from within
 "registry::read {
             foreach file $imagefiles {
                 incr progress_step
                 _progress update $progress_step $progress_t..."
 Error: See
 /opt/local/var/macports/logs/_opt_dports_devel_glib2/glib2/main.log for
 details.
 Error: Couldn't activate glib2 @2.88.0_0+quartz: 1
 Error: Follow https://guide.macports.org/#project.tickets if you believe
 there is a bug.
 }}}

-- 
Ticket URL: <https://trac.macports.org/ticket/73965#comment:10>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list