Build an Objective-C bindings library with Objective Sharpie - IOS451

Exercise 1: Initiate the binding process on an existing Xcode project (IOS451)

The primary goal of this lab is to initiate the binding process on an existing Xcode project using Objective Sharpie.

To complete the exercise, you will need to work on a machine running macOS 10.10 or newer for compatibility with Objective Sharpie.

Download Objective Sharpie

If you haven't already, download Objective Sharpie. It will be required to complete this exercise.


Clone target library

As a first step, you are going to clone the Pop animation library.

  1. Create a folder for you exercise content.
  2. Open Terminal and navigate to your exercise folder.
  3. Type the following command to clone the Pop library from GitHub.
git clone https://github.com/facebook/pop.git

Process library into an API definition

Now, we'll process the downloaded library into the API definition files using Objective Sharpie.

  1. Navigate your command-prompt to the newly Git-created pop folder.
  2. Run the following command.
sharpie bind pop.xcodeproj -sdk iphoneos11.4

The Objective Sharpie run will complete with the creation of two files:

You may need to adjust the -sdk parameter to match an installed SDK version on your PC. If you are unsure what SDKs you have installed, you can list available Xcode SDKs with sharpie xcode -sdks.

Exercise summary

In this exercise you have seen how to initiate the binding process on an existing Xcode project using Objective-Sharpie.

Go Back