1

I would like to write something like import SignalProtocol at the top of one of my Swift files and then be able to call the C functions from libsignal-protocol-c.

libsignal-protocol-c's README says: "When integrating into actual applications, you should not need anything beyond CMake. Alternatively, you may integrate the code using a build system of your choice."

I think I'd like to use the Swift Package Manager to integrate libsignal-protocol-c into my Swift iOS app. Is there a way to automatically generate a manifest file, ie, Package.swift, and a module map, ie, a module.modulemap file, from libsignal-protocol-c's CMake files? Or if I need to create these files manually, what should they include? Otherwise, how would I do this with CMake?

How to import and use libsignal-protocol-c in an existing .xcodeProj? is a similar question but for Objective-C projects.

ma11hew28
  • 121,420
  • 116
  • 450
  • 651

1 Answers1

0

I'm not sure its an answer but I'm going to start using https://github.com/christophhagen/LibSignalProtocolSwift. Seems like a good start.

Denis
  • 570
  • 9
  • 23
  • 1
    Thanks. I've seen that project before, but I chose not to use it because its README says: "This Swift library is intended for educational purposes only". Plus that project is also not a [Swift package](https://developer.apple.com/documentation/swift_packages). – ma11hew28 Apr 28 '20 at 10:23
  • Hello, are you able to find a solution regarding it ? – Ankit Khanna Feb 01 '21 at 04:42