[MacPorts] #66119: gnucash @4.11_1: gnc-main-window.c:80:10: fatal error: 'gtkmacintegration/gtkosxapplication.h' file not found

MacPorts noreply at macports.org
Tue May 27 13:10:28 UTC 2025


#66119: gnucash @4.11_1: gnc-main-window.c:80:10: fatal error:
'gtkmacintegration/gtkosxapplication.h' file not found
----------------------+--------------------
  Reporter:  JDLH     |      Owner:  drkp
      Type:  defect   |     Status:  closed
  Priority:  Normal   |  Milestone:
 Component:  ports    |    Version:  2.8.0
Resolution:  fixed    |   Keywords:
      Port:  gnucash  |
----------------------+--------------------
Changes (by Jim DeLaHunt <from+github@…>):

 * status:  assigned => closed
 * resolution:   => fixed


Comment:

 In [changeset:"92ba307caf7207f0f90a6efa1ad9b761cdb87f1d/macports-ports"
 92ba307caf7207f0f90a6efa1ad9b761cdb87f1d/macports-ports] (master):
 {{{
 #!ConfigurableCommitTicketReference repository="macports-ports"
 revision="92ba307caf7207f0f90a6efa1ad9b761cdb87f1d"
 gnucash: fix 66119, build failure when +quartz (#28546)

 * Fix gnucash @5.11_0 build failure when +quartz (ticket 66119
 gtkmacintegration)

 Make gnucash compatible with port gtk-osx-application-common-gtk3 (subport
 of gtk-osx-application).
 The errors came because three GnuCash source files had an import like:
 #include <gtkmacintegration/gtkosxapplication.h>
 but the include path delivered by port gtk-osx-application-common-gtk3
 included the
 .../gtkmacintegration/ part. The correct import is:
 #include <gtkosxapplication.h>
 The affected source files are:
  • gnucash/gnome-utils/gnc-main-window.cpp
  • gnucash/gnome/window-reconcile.cpp
  • libgnucash/core-utils/binreloc.c

 Also, gnucash/gnome/CMakeLists.txt did not propagate the include path
 properly.
 CMakeLists.txt must contain a directive like:
 target_include_directories(... ${GTK_MAC_INCLUDE_DIRS} )
 ...to pick up the include dirs discovered by ./CMakeLists.txt:464,
 `pkg_check_modules(GTK_MAC IMPORTED_TARGET gtk-mac-integration-gtk3)`.

 Fixes ticket 66119 "gnucash @4.11_1: gnc-main-window.c:80:10: fatal error:
 'gtkmacintegration/
 gtkosxapplication.h' file not found"
 <https://trac.macports.org/ticket/66119>.
 The problem only occurs when port gtk3 has the +quartz variant, because
 that causes
 the GnuCash sources to compile in optional "MAC_INTEGRATION" code.

 Also, no reinplace of `if (WIN32 OR APPLE)` necessary

 The `reinplace "s|if (WIN32 OR APPLE)|if (WIN32)|"` in
 `${worksrcpath}/CMakeLists.txt` didn't change anything.
 The corresponding change was made upstream in
 gnucash/commit/1915dfb0cb255fe26dcd7810c96e855defbc747f
 on 2020-10-17.

 * Delete obsolete commented-out line from Gnucash portfile.

 Closes: https://trac.macports.org/ticket/66119
 }}}

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


More information about the macports-tickets mailing list