# Install the SDK

This guide walks you through adding the Get Mini SDK static library to your Xcode project. You'll configure the build settings, link required frameworks, and verify the installation is working correctly.

## Requirements

Before you begin, ensure you have:

- **Xcode 12.0** or later installed on your Mac
- **iOS 11.0** or later set as your minimum deployment target
- **SDK package** from Get Mini containing `libTPVPC-SDK.a` and header files (`.h`)
- **Basic familiarity** with Xcode build settings

<Callout type="note">

The SDK does not support CocoaPods or Swift Package Manager. Manual integration is required.

</Callout>

## Installation Steps

Follow these steps to integrate the SDK into your Xcode project.

### Step 1: Add Library Files to Your Project

Create a dedicated folder for the SDK files and add them to your Xcode project:

1. Create a folder named `mPOS-SDK` in your project directory
2. Copy `libTPVPC-SDK.a` and all header files (`.h`) into this folder
3. Drag the `mPOS-SDK` folder into your Xcode project navigator
4. When prompted, check **Copy items if needed** and select your app target

### Step 2: Configure Header Search Paths

Tell Xcode where to find the SDK header files:

1. Select your project in the Project Navigator
2. Choose your **App Target** and go to **Build Settings**
3. Search for **Header Search Paths**
4. Add `$(SRCROOT)/mPOS-SDK` and set it to **recursive**

### Step 3: Add Required Linker Flags

The SDK requires specific linker flags to load correctly. In **Build Settings**, search for **Other Linker Flags** and add all three flags:

| Flag | Purpose |
| :---- | :---- |
| `-ObjC` | Loads Objective-C categories from the static library |
| `-lstdc++` | Links C++ standard library for internal SDK logic |
| `-lsqlite3` | Enables local data persistence (SDK v3.4+) |

<Callout type="warning">

Missing linker flags will cause "Selector not recognized" or "Symbol not found" crashes.

</Callout>

### Step 4: Link System Frameworks

Add the required iOS frameworks in **General > Frameworks, Libraries, and Embedded Content**:

- `ExternalAccessory.framework` - For PIN pad communication via Bluetooth
- `CoreBluetooth.framework` - For device discovery and connection
- `Security.framework` - For cryptographic operations
- `UIKit.framework` - For UI components

### Step 5: Verify Installation

Test that the SDK is properly integrated by importing the headers in your code.

**For Objective-C projects**, add the imports to your implementation file:

```
#import "CommonUtils.h"
#import "RedsysPinpadManager.h"
```

**For Swift projects**, create or update your **Bridging Header** (`ProjectName-Bridging-Header.h`) with the same imports, then verify in Swift:

```
func checkSDKInstallation() {
    print("SDK Version: \(CommonUtils.getVersion())")
}
```

Build your project (⌘+B) to confirm the import succeeds without errors.

## Troubleshooting

**Headers Not Found**

Verify **Header Search Paths** in Build Settings includes `$(SRCROOT)/mPOS-SDK` set to **recursive**.

**Undefined Symbol Errors**

Check that all three linker flags (`-ObjC`, `-lstdc++`, `-lsqlite3`) are present in **Other Linker Flags**.

**Crash During Device Scan**

Missing External Accessory protocols in Info.plist. See [Configure iOS Permissions](/en/get-mini/ios-sdk/first-steps/configure-ios-permissions) for required protocol strings.

## Next Steps

Now that the library is linked, configure your app's permissions to allow hardware communication:

* [Configure iOS Permissions](/en/get-mini/ios-sdk/first-steps/configure-ios-permissions) - Set up mandatory protocol strings and Bluetooth permissions
* [Quickstart: Your First Sale](/en/get-mini/ios-sdk/first-steps/ios-sdk-quickstart) - Initialize the manager and start testing