Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
90dcd460
Commit
90dcd460
authored
Mar 04, 2012
by
Andrey Kamaev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Android: fixed cmake try_compile() for case of STL features detection
parent
631f72d8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
2 deletions
+15
-2
android.toolchain.cmake
android/android.toolchain.cmake
+15
-2
No files found.
android/android.toolchain.cmake
View file @
90dcd460
...
...
@@ -169,8 +169,7 @@
cmake_minimum_required
(
VERSION 2.6.3
)
if
(
PROJECT_NAME STREQUAL
"CMAKE_TRY_COMPILE"
)
# all needed flags and variables are already inherited from the parent project
return
()
include
(
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/../android.toolchain.config.cmake"
OPTIONAL
)
endif
()
# this one is important
...
...
@@ -942,6 +941,20 @@ macro( ANDROID_GET_ABI_RAWNAME TOOLCHAIN_FLAG VAR )
endmacro
()
# export toolchain settings for the try_compile() command
if
(
NOT PROJECT_NAME STREQUAL
"CMAKE_TRY_COMPILE"
)
set
(
__toolchain_config
""
)
foreach
(
__var ANDROID_ABI ANDROID_FORCE_ARM_BUILD ANDROID_NATIVE_API_LEVEL ANDROID_NO_UNDEFINED ANDROID_SO_UNDEFINED ANDROID_SET_OBSOLETE_VARIABLES LIBRARY_OUTPUT_PATH_ROOT ANDROID_USE_STLPORT ANDROID_FORBID_SYGWIN ANDROID_NDK ANDROID_STANDALONE_TOOLCHAIN
)
if
(
DEFINED
${
__var
}
)
set
(
__toolchain_config
"
${
__toolchain_config
}
set(
${
__var
}
\"
${${
__var
}}
\"
)
\n
"
)
endif
()
endforeach
()
file
(
WRITE
"
${
CMAKE_CURRENT_BINARY_DIR
}
/CMakeFiles/android.toolchain.config.cmake"
"
${
__toolchain_config
}
"
)
unset
(
__toolchain_config
)
endif
()
# set some obsolete variables for backward compatibility
set
(
ANDROID_SET_OBSOLETE_VARIABLES ON CACHE BOOL
"Define obsolete Andrid-specific cmake variables"
)
mark_as_advanced
(
ANDROID_SET_OBSOLETE_VARIABLES
)
if
(
ANDROID_SET_OBSOLETE_VARIABLES
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment