Commit 6d428118 authored by Ghislain MARY's avatar Ghislain MARY

Fix in Android toolchain to find the tools.

parent 556a30df
......@@ -30,20 +30,23 @@ set(CMAKE_POSITION_INDEPENDENT_CODE YES)
set(CMAKE_SYSTEM_NAME "Linux")
set(ANDROID True)
find_path(ANDROID_NDK_PATH ndk-build)
if(NOT ANDROID_NDK_PATH)
find_program(ANDROID_NDK_BUILD_PROGRAM ndk-build)
if(NOT ANDROID_NDK_BUILD_PROGRAM)
message(FATAL_ERROR "Cannot find 'ndk-build', make sure you installed the NDK and added it to your PATH")
endif()
get_filename_component(ANDROID_NDK_PATH "${ANDROID_NDK_BUILD_PROGRAM}" DIRECTORY)
find_path(ANDROID_SDK_PATH android)
if(NOT ANDROID_SDK_PATH)
find_program(ANDROID_ANDROID_PROGRAM android)
if(NOT ANDROID_ANDROID_PROGRAM)
message(FATAL_ERROR "Cannot find 'android', make sure you installed the SDK and added it to your PATH")
endif()
get_filename_component(ANDROID_SDK_PATH "${ANDROID_ANDROID_PROGRAM}" DIRECTORY)
find_path(ANDROID_SDK_PLATFORM_TOOLS_PATH adb)
if(NOT ANDROID_SDK_PLATFORM_TOOLS_PATH)
find_program(ANDROID_ADB_PROGRAM adb)
if(NOT ANDROID_ADB_PROGRAM)
message(FATAL_ERROR "Cannot find 'adb', make sure you installed the SDK platform tools and added it to your PATH")
endif()
get_filename_component(ANDROID_SDK_PLATFORM_TOOLS_PATH "${ANDROID_ADB_PROGRAM}" DIRECTORY)
find_file(CLANG_EXECUTABLE "clang"
PATHS
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment