Linker Issue with Xcode 15

193 views
Skip to first unread message

Wyatt P

unread,
Oct 25, 2023, 1:15:26 PM10/25/23
to j2objc-discuss
Hi there,

I was told by a colleague about this group for developers working with j2objc. I'm tasked with upgrading our codebase to work with Xcode 15 (moving from 14.1). I worked through most of the syntax changes in Swift but am finding myself stuck with a linker issue. Interestingly enough, the symbols that are undefined here are related to Java enumerators that are translated over.

ld: Undefined symbols:
  _PAPFoo_Bar_initialize, referenced from:
      @objc MyProduct.MySwiftClass.mySwiftMethod(with: __C.PCOMyConfiguration?) -> () in AnotherSwiftClass.o

In this case, this is not a problem when Swift optimization is turned off, as it builds successfully. When comparing the symbol tables between the same object files, the compiler in Xcode 15 adds on a new symbol, _PAPFoo_Bar_initialize. We currently are using j2objc-2.5 and perhaps upgrading to the latest may help. I'm also not as well versed with objective-c, so apologies in advance. Let me know If I can provide any additional information, thanks.
Reply all
Reply to author
Forward
0 new messages