.ia-secondary-container
Use the following instructions to build the C endpoint SDK for iOS.
First, ensure the following components are installed on your machine.
Then, proceed as follows:
Run the following commands.
mkdir build cd build
Run the following iOS-specific commands.
cmake -DKAA_PLATFORM=ios -DCMAKE_TOOLCHAIN_FILE=../toolchains/iOS.cmake -GXcode .. xcodebuild
To configure the C endpoint SDK build, you can optionally specify the following parameters for the cmake command.
Parameter | Description | Values | Usage example |
---|---|---|---|
KAA_DEBUG_ENABLED | Build type | Accepted:
Default: 0 | cmake -DKAA_DEBUG_ENABLED=1 |
KAA_MAX_LOG_LEVEL | Maximum log level used by the SDK | Accepted:
Default:
| cmake -DKAA_MAX_LOG_LEVEL=4 |
KAA_WITHOUT_<MODULE> | Kaa module to be omitted during the build | Accepted:
Default: All modules are present in the build | cmake -DKAA_WITHOUT_EVENTS=1 |
KAA_PLATFORM | SDK target platform
NOTE: Before running the cmake command with the KAA_PLATFORM parameter for a platform other than supported, do the following: 1. Create a folder in $KAA_HOME/listfiles/platform/ and name it using [a-zA-z_-] symbols. You will be able to use the folder name as a value for the KAA_PLATFORM parameter. 2. Put the CMakeLists.txt file into the created folder. This file may contain specific compilation/linking flags, platform-dependent source files, third-party library dependencies, that is all information necessary for building the C endpoint SDK for this platform. 3. Optionally, specify the following parameters in the CMakeLists.txt file.
| Accepted: x86-64 ios Default: x86-64 | cmake -DKAA_PLATFORM=x86-64 In the CMakeLists.txt file: set(KAA_INCLUDE_PATHS ${KAA_INCLUDE_PATHS} path_to_folder_1_with_header_files path_to_folder_2_with_header_files ) set(KAA_SOURCE_FILES ${KAA_SOURCE_FILES} path_to_source_file_1 path_to_source_file_2 ) set(KAA_THIRDPARTY_LIBRARIES ${KAA_THIRDPARTY_LIBRARIES} some_library_1 some_library_2 ) |
To configure iOS-specific options, specify the following parameters for the cmake command.
Parameter | Description | Values | Usage example |
---|---|---|---|
IOS_PLATFORM | Applicable for the iOS build (KAA_PLATFORM=ios). It specifies the target iOS platform(armv7/arm64 - for mobile devices, i386 - for the simulator).
| Accepted: OS - build for the mobile device (armv7/arm64) Default: OS | cmake -DKAA_PLATFORM=ios -DCMAKE_TOOLCHAIN_FILE=../toolchains/iOS.cmake -DIOS_PLATFORM=SIMULATOR -GXcode .. |
The following example illustrates the C SDK build procedure for the iOS simulator with the maximum log level.
mkdir build cd build cmake -DKAA_PLATFORM=ios -DCMAKE_TOOLCHAIN_FILE=../toolchains/iOS.cmake -DIOS_PLATFORM=SIMULATOR -DKAA_MAX_LOG_LEVEL=6 -GXcode .. xcodebuild
Copyright © 2014-2015, CyberVision, Inc.