From 6db5b7046f816474614ba5cd6e0f38c4287df730 Mon Sep 17 00:00:00 2001 From: tellypresence Date: Wed, 9 Dec 2020 20:21:43 +0900 Subject: [PATCH] Provide option for rapidjson no-member-iterator define Originally added to fix warning on MSVC but breaks android build --- code/CMakeLists.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/code/CMakeLists.txt b/code/CMakeLists.txt index a0bad4e10..bb83a5f97 100644 --- a/code/CMakeLists.txt +++ b/code/CMakeLists.txt @@ -1033,7 +1033,10 @@ ELSE() INCLUDE_DIRECTORIES( "../contrib" ) INCLUDE_DIRECTORIES( "../contrib/pugixml/src" ) ADD_DEFINITIONS( -DRAPIDJSON_HAS_STDSTRING=1 ) - ADD_DEFINITIONS( -DRAPIDJSON_NOMEMBERITERATORCLASS ) + option( ASSIMP_RAPIDJSON_NO_MEMBER_ITERATOR "Suppress rapidjson warning on MSVC (NOTE: breaks android build)" ON ) + if(ASSIMP_RAPIDJSON_NO_MEMBER_ITERATOR) + ADD_DEFINITIONS( -DRAPIDJSON_NOMEMBERITERATORCLASS ) + endif() ENDIF() # VC2010 fixes