[MacPorts] #69524: rawstudio does not build again: error: unknown type name 'xmlDocPtr' etc.

MacPorts noreply at macports.org
Sun Mar 17 09:27:50 UTC 2024


#69524: rawstudio does not build again: error: unknown type name 'xmlDocPtr' etc.
---------------------------+--------------------------
  Reporter:  barracuda156  |      Owner:  barracuda156
      Type:  defect        |     Status:  assigned
  Priority:  Normal        |  Milestone:
 Component:  ports         |    Version:  2.9.1
Resolution:                |   Keywords:
      Port:  rawstudio     |
---------------------------+--------------------------

Comment (by ryandesign):

 My observations about this are:

 `rs_detect_cpu_features` is defined in librawstudio, which is a C library,
 so the symbol in the library is `_rs_detect_cpu_features`.

 denoise.so doesn't link with librawstudio; none of the plugins do. Maybe
 that's not required if they're loaded by the main rawstudio program since
 rawstudio does link with librawstudio.

 Of the 5 plugins that use `rs_detect_cpu_features`, denoise is the only
 one written in C++. All the others are C and correctly reference the
 `_rs_detect_cpu_features` symbol. denoise, being a C++ library, references
 the name-mangled symbol, `__Z22rs_detect_cpu_featuresv`, which doesn't
 exist.

 rawstudio.h uses the correct trick to tell any C++ code including it that
 the library's functions are C functions that should not be name-mangled:

 {{{#!c
 #ifdef  __cplusplus
 extern "C" {
 #endif
 }}}
 {{{#!c
 #ifdef  __cplusplus
 } /* extern "c" */
 #endif
 }}}

 There is one rawstudio header—rs-types.h—included outside of that ifdef,
 but rs-types.h doesn't include any other rawstudio headers and only
 defines datatypes so I don't think that would be the cause.

 So I'm not sure yet why denoise is using the name-mangled symbol when it
 shouldn't.

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


More information about the macports-tickets mailing list