From 2fc808840b0931c2c6d5021bc88b439d4e3d86a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Fri, 1 Dec 2017 16:00:36 +0100 Subject: [PATCH] Android: the native app glue needs C language enabled. This was not caught by Travis CI, because there an older CMake version is used and in that version I'm enabling C because otherwise nothing works at all. Sorry. --- CMakeLists.txt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 3805198e1..f2e221968 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -44,8 +44,9 @@ if(POLICY CMP0054) endif() # Configuration fails on < 3.4 if only C++ is enabled (CheckFunctionExists -# macro called from FindX11) -if(NOT CMAKE_VERSION VERSION_LESS 3.4.0) +# macro called from FindX11). Also, Android needs C for compiling some glue +# code. +if(NOT CMAKE_VERSION VERSION_LESS 3.4.0 AND NOT CMAKE_SYSTEM_NAME STREQUAL "Android") set(LANG CXX) endif() project(Magnum ${LANG})