I am trying to package GitHub - sctplab/usrsctp: A portable SCTP userland stack with SPM to use it as a dependency in my swift library. What I get is:
Sources/usrsctp/src/user_inpcb.h:106:8 type 'struct inpcb' has incompatible definitions in different translation units
It seems like the compiler things the system struct inpcb
exists even though it has never been included anywhere and so won't allow the local definition to be created.
I can solve this under swift build
by adding
CXXSetting.unsafeFlags(["-fno-modules"]),
however this is ignored by Xcode so it won't work for Xcode builds.
Any thought to supported a C target that builds not in module mode?