[MacPorts] #44395: glib2, glib2-devel: don't add -I${prefix}/include to glib-2.0.pc

MacPorts noreply at macports.org
Fri Feb 16 11:33:29 UTC 2018


#44395: glib2, glib2-devel: don't add -I${prefix}/include to glib-2.0.pc
--------------------------------+------------------------
  Reporter:  ryandesign         |      Owner:  ryandesign
      Type:  defect             |     Status:  closed
  Priority:  Normal             |  Milestone:
 Component:  ports              |    Version:  2.3.1
Resolution:  fixed              |   Keywords:
      Port:  glib2 glib2-devel  |
--------------------------------+------------------------
Changes (by ryandesign):

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


Comment:

 In [changeset:"e302b20bdd71e9e16b142c525d8d809ee56ffd05/macports-ports"
 e302b20bdd71e9e16b142c525d8d809ee56ffd05/macports-ports]:
 {{{
 #!ConfigurableCommitTicketReference repository="macports-ports"
 revision="e302b20bdd71e9e16b142c525d8d809ee56ffd05"
 glib2, glib2-devel: No longer add -I/opt/local/include to glib-2.0.pc

 This had originally been added so that other software could include
 gi18n.h without error, since gi18n.h uses #include <libintl.h> so
 the path to libintl.h needs to be among the include paths.

 MacPorts already puts -I/opt/local/include into CPPFLAGS during the
 configure phase so I expected this change not to affect most ports, and
 to merely help the very few ports that either ignore CPPFLAGS or don't
 use a configure script but do use pkg-config.

 See: https://trac.macports.org/ticket/9937

 But some build systems do not put the -I flags into the correct order,
 and are so complicated that fixing that is nearly impossible (e.g. Qt).
 If -I/opt/local/include appears in the compiler flags, such ports may
 fail to upgrade to a new version if the previous version is active, as
 old include files from the old version are mistakenly used instead of
 the new versions. Such ports may clear the automatically-added CPPFLAGS
 to avoid the appearance of -I/opt/local/include, but if they depend on
 glib2, that flag would reappear.

 Therefore, don't add -I/opt/local/include to glib-2.0.pc, and instead
 patch the files that #include <libintl.h> to do so by absolute path.

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

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


More information about the macports-tickets mailing list