diff options
author | Krzysztof Adamski <k@japko.eu> | 2013-09-01 19:43:35 +0200 |
---|---|---|
committer | Krzysztof Adamski <k@japko.eu> | 2013-09-01 19:48:01 +0200 |
commit | 01cd5ae3772a32b29c6bd1cdc1cdc50d98961c1c (patch) | |
tree | 72ff596a969021625e541bf743679d923f6f2b59 | |
parent | 3b75b684a1ac32cbf726cc3d647453a769b8dfe4 (diff) | |
download | libgit2-01cd5ae3772a32b29c6bd1cdc1cdc50d98961c1c.tar.gz |
Add instructions about buiding for Android to README.md
-rw-r--r-- | README.md | 22 |
1 files changed, 22 insertions, 0 deletions
@@ -108,6 +108,28 @@ See [the wiki] (https://github.com/libgit2/libgit2/wiki/Building-libgit2-on-Windows) for more detailed instructions. +Android +------- + +Extract toolchain from NDK using, `make-standalone-toolchain.sh` script. +Optionaly, crosscompile and install OpenSSL inside of it. Then create CMake +toolchain file that configures paths to your crosscompiler (substitude `{PATH}` +with full path to the toolchain): + + SET(CMAKE_SYSTEM_NAME Linux) + SET(CMAKE_SYSTEM_VERSION Android) + + SET(CMAKE_C_COMPILER {PATH}/bin/arm-linux-androideabi-gcc) + SET(CMAKE_CXX_COMPILER {PATH}/bin/arm-linux-androideabi-g++) + SET(CMAKE_FIND_ROOT_PATH {PATH}/sysroot/) + + SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) + SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) + SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) + +Add `-DCMAKE_TOOLCHAIN_FILE={pathToToolchainFile} -DANDROID=1` to cmake command +when configuring. + Language Bindings ================================== |