File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -8,12 +8,14 @@ option(CGE_USE_VIDEO_MODULE "boolean option to enable video module" OFF)
88
99if (NOT DEFINED ANDROID_GRADLE OR NOT ANDROID_GRADLE)
1010 if (NOT DEFINED ENV{NDK})
11- execute_process (COMMAND which ndk-build OUTPUT_VARIABLE CGE_NDK_DIR )
11+ execute_process (COMMAND which ndk-build OUTPUT_VARIABLE CGE_NDK_BUILD_PATH OUTPUT_STRIP_TRAILING_WHITESPACE )
1212
13- if ("${CGE_NDK_DIR } " STREQUAL "" )
13+ if ("${CGE_NDK_BUILD_PATH } " STREQUAL "" )
1414 message (FATAL_ERROR "You should define the NDK variable!" )
1515 else ()
16- execute_process (COMMAND export NDK=$(dirname `which ndk-build `))
16+ get_filename_component (CGE_NDK_DIR "${CGE_NDK_BUILD_PATH} " DIRECTORY )
17+ set (ENV{NDK} "${CGE_NDK_DIR} " )
18+ message (STATUS "Auto-detected NDK path: ${CGE_NDK_DIR} " )
1719 endif ()
1820 endif ()
1921
You can’t perform that action at this time.
0 commit comments