yonaskolb / SwagGen

OpenAPI/Swagger 3.0 Parser and Swift code generator

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Linking error with Xcode 10.2 toolchain

PatrickNLT opened this issue · comments

I'm unable to build SwagGen with the Xcode 10.2 toolchain. There is a linking issue. Reproduced on another computer, so it's not limited to my setup.

$make install

swift build --disable-sandbox -c release -Xswiftc -static-stdlib
ld: warning: directory not found for option '-L/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift_static/macosx'
ld: warning: Could not find auto-linked library 'swiftFoundation'
ld: warning: Could not find auto-linked library 'swiftDarwin'
ld: warning: Could not find auto-linked library 'swiftCoreFoundation'
ld: warning: Could not find auto-linked library 'swiftIOKit'
ld: warning: Could not find auto-linked library 'swiftCore'
ld: warning: Could not find auto-linked library 'swiftCoreGraphics'
ld: warning: Could not find auto-linked library 'swiftObjectiveC'
ld: warning: Could not find auto-linked library 'swiftDispatch'
Undefined symbols for architecture x86_64:
  "_$s10Foundation10NSNotFoundSivg", referenced from:
      _$s10Foundation4DateV4YamsE9construct4fromACSgAD4NodeO6ScalarV_tFZ in Constructor.swift.o
      _$s4Yams8ResolverC10resolveTag2ofAA0D0C4NameVAA4NodeO_tF in Resolver.swift.o
      _$s4Yams3TagC8resolved4withACx_tAA0B10ResolvableRzlFAA4NodeO6ScalarV_Tg5Tf4xn_g in Tag.swift.o
  "_$s10Foundation12CharacterSetV11whitespacesACvgZ", referenced from:
      _$s15StencilSwiftKit7FiltersO7StringsO14removeNewlines_9argumentsypSgAH_SayAHGtKFZ in Filters+Strings.swift.o
      _$sSlsE4drop5while11SubSequenceQzSb7ElementQzKXE_tKFSS17UnicodeScalarViewV_Tg504$ss7f2O6g160VSbs5Error_pIgydzo_ADSbsAE_pIegndzo_TR0116$s15StencilSwiftKit7FiltersO7StringsO24removeLeadingWhitespaces33_BA19D16811ACAA4D0FD5CFE410EC1D8FLL4fromS2S_tFZSbs7a2J16B6VXEfU_Tf3npf_nTf1cn_nTf4gX_n in Filters+Strings.swift.o
      _$s7SwagGen15GenerateCommandC7executeyyKF in main.swift.o
  "_$s10Foundation12CharacterSetV12charactersInACSSh_tcfC", referenced from:
      _globalinit_33_2FABBAEE59BCC804A805D0C499A932AF_func15 in Representer.swift.o
  "_$s10Foundation12CharacterSetV13alphanumericsACvgZ", referenced from:
      _globalinit_33_CB635B249A4735A920030995EC03E33E_func3 in Parameters.swift.o
      _$s10SwagGenKit13CodeFormatterC12escapeStringyS2SFTf4nd_nTf4x_n in CodeFormatter.swift.o
 
...

_$s13JSONUtilities7KeyPathOSayypGypSDySSypGs5Error_pIegggnrzo_AcDypAEsAF_pIegggnozo_TRTA in Dictionary+JSONKey.swift.o
      _$s13JSONUtilities7KeyPathOSayypGypSDySSypGs5Error_pIgggnozo_AcDypAEsAF_pIegggnrzo_TRTA in Dictionary+JSONKey.swift.o
NUtilitiesAA7JSONKeyRzrlE4json9atKeyPath20invalidItemBehaviourSayqd__GAA0eF0O_AA07InvalidhI0Oyqd__GtKSYRd__AA11JSONRawType8RawValueRpd__lFqd__AH_SayypGyptKXEfU_ in Dictionary+JSONKey.swift.o
      ...
ld: symbol(s) not found for architecture x86_64
<unknown>:0: error: link command failed with exit code 1 (use -v to see invocation)

make: *** [build] Error 1