Skip to content

Commit

Permalink
Merge pull request #5 from OSVR/setCmakeSysroot
Browse files Browse the repository at this point in the history
Set CMAKE_SYSROOT on CMake 3.0.0 and later
  • Loading branch information
rpavlik authored Jun 21, 2016
2 parents 44e5409 + 8011401 commit 213c6df
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion android.toolchain.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -1161,7 +1161,9 @@ endforeach()
remove_definitions( -DANDROID )
add_definitions( -DANDROID )

if( ANDROID_SYSROOT MATCHES "[ ;\"]" )
if( CMAKE_VERSION VERSION_GREATER "3.0.0" )
set( CMAKE_SYSROOT ${ANDROID_SYSROOT} )
elseif( ANDROID_SYSROOT MATCHES "[ ;\"]" )
if( CMAKE_HOST_WIN32 )
# try to convert path to 8.3 form
file( WRITE "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/cvt83.cmd" "@echo %~s1" )
Expand Down

0 comments on commit 213c6df

Please sign in to comment.