Manual Integration
Here you will learn how to integrate the Group Link iOS SDK inside your library without any dependency manager.
Before starting, download the framework to add it to your project.
Step 1 - Installing the Group Link Library
To start you need to create a folder named "Frameworks" inside your project root directory, this is the folder where you will put the GroupLink.xcframework file.
Frameworks folder inside the Project folder
Step 2 - Importing to the Project
Next, you will need to import the Group Link xcframework to your project, just go to your project file on the Xcode sidebar and add it to the Framework, Libraries, and Embedded Content, click on the plus sign, and search for the GroupLink.xcframework to add. Alternatively, you can drag the file to the list.
Group Link SDK inside the project
Step 3 - Implementing the SDK Functions
To import the GroupLink module into your framework code, use the import attribute with the @_implementationOnly tag as shown below. Then, proceed with the iOS Initialization process.
import Foundation
@_implementationOnly import GroupLinkStatic
public class TestFrameworkSDK {
public static func printVersion() {
print("Test Version: 1.0.0")
}
public static func startTestFramework() {
print("Starting Test Framework")
// ...
GroupLinkSDK.start(withToken: "")
GroupLinkSDK.startBluetooth()
}
}
Step 4 - Distributing the Framework
Once you've added all the code, ensure that your framework includes the GroupLink.xcframework file in your build. You can verify this information within your project file's Build Phases.
The finalized framework folder structure should resemble the following format.
Solving Known Problems
In case of any type of errors while including the SDK in your framework. There is the possibility to add the following configuration:
- Always Embed Swift Standard Libraries