summaryrefslogtreecommitdiffstats
blob: e310ca117dd10183408b8cef4b6e3492454cc5a2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
Prerequisites
------------
- XCode
- Python
- Other requirements that are obtained during this guide
  - OpenSSL

Supported Components
--------------------
- Swiften
  Note: File-transfer support has not been tested on iOS. Link-local features are not supported under iOS.
- Swift/Controllers

Preparation of Build Environment
--------------------------------
1. Fetch 3rd-party dependencies

1.1 OpenSSL
    cd 3rdParty/OpenSSL
    curl -O http://www.openssl.org/source/openssl-1.0.1j.tar.gz
    tar -xf openssl-1.0.1j.tar.gz
    mv openssl-1.0.1j openssl

Building
--------
1. Switch to iOS directory
  cd BuildTools/IOS

2. Look up installed SDKs
  xcodebuild -showsdks

  Note: Here the iOS SDKs and iOS Simulator SDKs are of interest.

3. Build Swiften (adjust the sdk parameter to one of the installed SDKs)
  xcodebuild build -arch i386 -sdk iphonesimulator8.1

  Note: When not specifying the architecture (-arch flag) XCode will try an universal build which is not supported.
        Only specify one architecture at a time and if you require a universal lib you can create one using the lipo tool.

4. The final libSwiften.a is located at $SWIFT/build/current/Swiften/libSwiften.a.

Testing
-------
Integration and unit tests are not supported on iOS.