How to Add the Library to Your Xcode Project

To create an application which uses ABBYY Mobile Capture SDK, you will need to add the library to your project, copy resource files and sign the framework. The configuring can be done mostly manually or by scripts. This is required for new projects only — packaged examples work out of the box.

Building application in manual mode

  1. Add the frameworks from the libs folder to your project:
    1. AbbyyRtrSDK.framework
    2. AbbyyZLib.framework
    3. ExtraNeoML.Dnn.framework
    4. FineMachineLearning.framework
    5. FineMachineLearningExt.framework
    6. FineObj.framework
    7. Mobile.SDK.framework
    8. NeoMathEngine.framework
    9. NeoML.framework
    10. PortLayer.framework
  2. Add the license file to your project (simply drag and drop it into your project window).
  3. Select your project in the Target group and open the Build Phases tab. In the Link Binary With Libraries section, click "+" and add the AbbyyRtrSDK.framework.
  4. Open the General tab and add all the frameworks to the section Embedded Binaries.
  5. Now you need to add the resource files and set up the copying rules. See Distribution Kit for a detailed description of the necessary resources. To add the resource files do the following:
    1. Go to Build Phases and add a new Copy Files phase.
    2. In the Destination field, specify Resources.
    3. In the Subpath field, specify bcr, dictionaries, patterns, translation and other required resource files.
  6. Finally, add framework signing:
    1. In Build Phases, add a new Run Script phase.
    2. Run the copy_frameworks.sh script that removes the frameworks for the non-active CPU architectures (the complete list depends on the project settings), and sign the resulting framework. This is a required step before uploading your application to App Store.

/bin/sh "${SRCROOT}/../libs/copy_frameworks.sh"

Building application using scripts

  1. Add the license file to your project (simply drag and drop it into your project window).
  2. Add the AbbyyRtrSDK.framework from the libs folder to your project.
  3. Select your project in the Target group and open the Build Phases tab. In the Link Binary With Libraries section, click "+" and add the AbbyyRtrSDK.framework.
  4. Add all the other frameworks to your project using script:
    1. In Build Phases, add a new Run Script phase.
    2. Run the copy_frameworks.sh script to add all the frameworks to you project. It will also remove from the frameworks the non-active CPU architectures (the complete list depends on the project settings) and sign the resulting framework. This is a required step before uploading your application to App Store.

/bin/sh "${SRCROOT}/../libs/copy_frameworks.sh"

  1. Now you need to add the resource files and set up the copying rules:
    1. In Build Phases, add a new Run Script phase.
    2. Run the copy_assets.py script to automatically copy all resource files to corresponding destinations and add necessary dictionaries. Your scenario may require only certain assets, therefor the script provides customizable settings: keys. Set the key value to copy only specified for the scenario source files. See the script file for details.

python "${SRCROOT}/../assets/copy_assets.py"  

 Important! Your application needs an Internet connection to gather the information about the current state of the library.

9/10/2020 6:34:48 PM