[MacPorts] #61306: ghostscript @ 9.52_0+x11 fails to build with xcode 12: error: implicit declaration of function 'FF_free' is invalid in C99

MacPorts noreply at macports.org
Mon Oct 12 06:38:48 UTC 2020


#61306: ghostscript @ 9.52_0+x11 fails to build with xcode 12: error: implicit
declaration of function 'FF_free' is invalid in C99
--------------------------+--------------------
  Reporter:  usrluciano   |      Owner:  (none)
      Type:  defect       |     Status:  new
  Priority:  Normal       |  Milestone:
 Component:  ports        |    Version:  2.6.3
Resolution:               |   Keywords:
      Port:  ghostscript  |
--------------------------+--------------------

Comment (by chrstphrchvz):

 I agree that both build failures share a cause/possible resolution: the
 complaints are common complaints about implicit function declarations,
 which is an error in Xcode 12 and only a warning under older versions.

 Regarding the first common error:
 {{{
  ./base/fapi_ft.c:129:1: error: expected function body after function
 declarator
  FF_alloc(FT_Memory memory, long size)
  ^
 }}}

 I think this could mean it is treating the
 [http://git.ghostscript.com/?p=ghostpdl.git;a=blob;f=base/fapi_ft.c;h=60f69f64462b65857671cd8813d14140d84493a5;hb=e49830f8efdbc3a9f4e8acaf708b68a742f515aa#l128
 previous line] `FT_CALLBACK_DEF(void *)` as the declarator, and `^` is
 where it expects the opening `{`—but maybe there would be more/other
 errors instead. But if this is the case, then I think this indicates a
 missing `#include FT_CONFIG_CONFIG_H` (what Ghostscript would use to
 `#include <freetype/config/ftconfig.h>` which defines `FT_CALLBACK_DEF`).

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


More information about the macports-tickets mailing list