aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorlloyd <[email protected]>2013-07-26 15:18:21 +0000
committerlloyd <[email protected]>2013-07-26 15:18:21 +0000
commitf10165e4008e113ef99fdc8649a02bf5d018a482 (patch)
treebd1563009dd0fbe3bc6c1c0318827b3242c33499 /doc
parent5bdde16c6010d4eac1314b2d56b42fbecc4d6dda (diff)
Add build instructions for iOS, sent by Jeffery Walton.
Diffstat (limited to 'doc')
-rw-r--r--doc/building.rst41
1 files changed, 40 insertions, 1 deletions
diff --git a/doc/building.rst b/doc/building.rst
index 3e31fd779..4ec543409 100644
--- a/doc/building.rst
+++ b/doc/building.rst
@@ -156,7 +156,6 @@ in the section marked `<mach_abi_linking>` in
$ ./configure.py --cpu=universalbinary [other options here]
-
On MS Windows
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -189,6 +188,46 @@ compiler to look for both include files and library files in
place where they will be in the default compiler search paths (consult
your documentation and/or local expert for details).
+
+For iOS using XCode
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+To cross compile for iOS, configure with::
+
+ $ ./configure.py --cpu=armv7 --cc=clang --cc-bin="clang++ -arch armv7 -arch armv7s --sysroot=$(IOS_SYSROOT)"
+
+Along with any additional configuration arguments. Using
+``--no-autoload`` might be helpful as can substantially reduce code
+size.
+
+Edit the makefile and change AR (around line 30) to::
+
+ AR = libtool -static -o
+
+You may also want to edit LIB_OPT to use -Os to optimize for size.
+
+Now build as normal with ``make check``. Confirm the binary is
+compiled for both architectures with::
+
+ $ xcrun -sdk iphoneos lipo -info check
+ Architectures in the fat file: check are: armv7 armv7s
+
+Now sign the test application with::
+
+ $ codesign -fs "Your Name" check
+
+which should allow you to run the library self tests on a jailbroken
+device.
+
+For Android
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+It has been reported several times that the library can be built for
+Android using the NDK, but precise instructions of what was required
+have not been provided. If you successfully build the library for
+Android, please report the exact sequence of steps needed so this
+documentation can be updated.
+
Other Build-Related Tasks
----------------------------------------