Tip

For the best development experience and compatibility, always use the latest version of Xcode.

You can integrate the SDK in two ways:

  • CocoaPods (recommended) — simplest; CocoaPods links everything for you.

  • Manual ZIP (advanced) — if you can’t use CocoaPods.

Manual ZIP (advanced)#

ZIP layout

LICENSE
RaveSocial/
  XCFrameworks/
    RaveSocial.xcframework
    RaveDemoScenePack.xcframework      (optional)
  Resources/
    RaveSocial.bundle
    RaveDemoScenePack.bundle           (optional)

Add to Xcode

  • Drag RaveSocial/XCFrameworks/RaveSocial.xcframework into your project and your app target.

  • Drag RaveSocial/Resources/RaveSocial.bundle into your project and ensure it appears under Build Phases → Copy Bundle Resources for the app target.

  • (Optional) also add RaveSocial/XCFrameworks/RaveDemoScenePack.xcframework and RaveSocial/Resources/RaveDemoScenePack.bundle if using the demo pack.

  • When prompted, we recommend enabling Copy items if needed so teammates and CI don’t depend on your local folder layout.

  • If Xcode shows an Embed option for the framework, set Embed & Sign (dynamic). If it only offers Do Not Embed, it’s a static framework—leave it as is.

If the linker complains

  • Add Other Linker Flags-ObjC.

  • If symbols are still missing, add these to the app target:

    • Frameworks: UIKit, CoreData, SafariServices, WebKit, Security, GameKit

    • Libraries: libz, libsqlite3, libxml2

Runtime sanity check

// During testing, verify the resource bundle is present:
NSString *path = [[NSBundle mainBundle] pathForResource:@"RaveSocial" ofType:@"bundle"];
NSLog(@"RaveSocial.bundle present: %@", path ? @"YES" : @"NO");

Required App Configuration#

Add the following keys and URL schemes to your app. These must match the apps you created on Facebook and Google.

Important

Incorrect App IDs or URL schemes will break login flows at runtime (silent failures or failed app switch).

Info.plist (keys)

  • FacebookAppID — your Facebook App ID (numeric).

  • FacebookClientToken — from Facebook → SettingsAdvancedClient Token.

URL Schemes (Info.plist → CFBundleURLTypes)

You need three schemes:

  1. Facebookfb<FacebookAppID> (prefix fb + your App ID)

  2. Google — the reverse of your Google client ID

  3. Your app — your bundle identifier (used by some flows)

Example Info.plist snippet:

<!-- Facebook -->
<key>FacebookAppID</key>
<string>123456789012345</string>
<key>FacebookClientToken</key>
<string>YOUR_FACEBOOK_CLIENT_TOKEN</string>

<!-- URL Schemes -->
<key>CFBundleURLTypes</key>
<array>
  <!-- Facebook: fb + FacebookAppID -->
  <dict>
    <key>CFBundleURLName</key>
    <string>facebook</string>
    <key>CFBundleURLSchemes</key>
    <array>
      <string>fb123456789012345</string>
    </array>
  </dict>

  <!-- Google: reversed client ID -->
  <dict>
    <key>CFBundleURLName</key>
    <string>google</string>
    <key>CFBundleURLSchemes</key>
    <array>
      <string>com.googleusercontent.apps.XXXXXXXXXXXX-XXXXXXXXXXXX</string>
    </array>
  </dict>

  <!-- App bundle ID -->
  <dict>
    <key>CFBundleURLName</key>
    <string>app</string>
    <key>CFBundleURLSchemes</key>
    <array>
      <string>com.yourcompany.yourapp</string>
    </array>
  </dict>
</array>

Note

If you use Google’s GoogleService-Info.plist (Firebase), the reversed client ID is listed there.

iOS Privacy Strings (as applicable)

Add user-facing reasons for any capabilities you use:

  • NSContactsUsageDescription — e.g., “Contacts are used to find in-game friends.”

  • NSCameraUsageDescription — e.g., “Camera is used for a profile picture.”

  • NSPhotoLibraryUsageDescription — e.g., “Photo library is used for profile pictures.”

Cross-App Login (optional)

  • RaveSettings.IOS.ApplicationGroupIdentifier — your App Group identifier when enabling cross-app login.

(Optional) Import via PCH / Bridging Header#

If your project uses a Precompiled Header (PCH), you can import Rave Social once and have it available project-wide.

Objective-C PCH

  1. If you already have a PCH (e.g. ProjectName-Prefix.pch), open it. If not, create a new header (e.g. ProjectName-Prefix.pch), add it to your app target, then set:

    • Build Settings → Prefix Header to the file path (e.g. $(SRCROOT)/ProjectName/ProjectName-Prefix.pch)

    • (Optional) Precompile Prefix Header = Yes

  2. Add this to the PCH:

    #ifdef __OBJC__
    #import <RaveSocial/RaveSocial.h>
    #endif
    

Swift projects (no PCH)

  1. Create or use your Objective-C Bridging Header (<ProductName>-Bridging-Header.h).

    • If you don’t have one, add any Objective-C file to the target and let Xcode create the bridging header, or set Build Settings → Objective-C Bridging Header to the header path.

  2. In the bridging header:

    #import <RaveSocial/RaveSocial.h>
    
  3. In Swift files, import the module as usual:

    import RaveSocial
    

Upgrading from older “Libs/” layout#

  • Old zips had: Libs/ with RaveSocial.framework/.bundle (and optional scene pack) plus a separate demo folder.

  • New zips have: RaveSocial/XCFrameworks and RaveSocial/Resources. Re-add the .xcframework and .bundle from the new paths, and remove the old references.

  • If you move to CocoaPods, you no longer drag files; just add the pod(s) and run pod install --repo-update.

Troubleshooting#

  • Pod not found / stale index: pod install --repo-update

  • Missing UI at runtime (manual): ensure the corresponding .bundle is in Copy Bundle Resources.

  • Linker “undefined symbols” (manual): add -ObjC and the frameworks/libraries listed above.

  • Using demo scenes (Pods): include the RaveSocial/DemoScenePack subspec.