diff options
Diffstat (limited to 'platform')
-rw-r--r-- | platform/android/MapboxGLAndroidSDK/build.gradle | 8 | ||||
-rw-r--r-- | platform/android/src/geojson/feature.cpp | 2 | ||||
-rw-r--r-- | platform/linux/src/headless_backend_egl.cpp | 3 |
3 files changed, 11 insertions, 2 deletions
diff --git a/platform/android/MapboxGLAndroidSDK/build.gradle b/platform/android/MapboxGLAndroidSDK/build.gradle index e796c35cee..d122687823 100644 --- a/platform/android/MapboxGLAndroidSDK/build.gradle +++ b/platform/android/MapboxGLAndroidSDK/build.gradle @@ -59,12 +59,18 @@ android { } } + // Allow determining the C++ STL we're using when building Mapbox GL. + def stl = 'c++_static' + if (project.hasProperty("mapbox.stl")) { + stl = project.getProperty("mapbox.stl") + } + defaultConfig { if (abi != 'none') { externalNativeBuild { cmake { arguments "-DANDROID_TOOLCHAIN=clang" - arguments "-DANDROID_STL=c++_static" + arguments "-DANDROID_STL=" + stl arguments "-DANDROID_CPP_FEATURES=rtti;exceptions" arguments "-DMBGL_PLATFORM=android" arguments "-DMASON_PLATFORM=android" diff --git a/platform/android/src/geojson/feature.cpp b/platform/android/src/geojson/feature.cpp index e79c238864..f0ed097842 100644 --- a/platform/android/src/geojson/feature.cpp +++ b/platform/android/src/geojson/feature.cpp @@ -2,6 +2,8 @@ #include "geometry.hpp" #include "../gson/json_object.hpp" +#include <mbgl/util/string.hpp> + namespace mbgl { namespace android { namespace geojson { diff --git a/platform/linux/src/headless_backend_egl.cpp b/platform/linux/src/headless_backend_egl.cpp index 089e344987..d72fbbfdea 100644 --- a/platform/linux/src/headless_backend_egl.cpp +++ b/platform/linux/src/headless_backend_egl.cpp @@ -1,5 +1,6 @@ #include <mbgl/gl/headless_backend.hpp> +#include <mbgl/util/string.hpp> #include <mbgl/util/logging.hpp> #include <EGL/egl.h> @@ -98,7 +99,7 @@ public: eglSurface = eglCreatePbufferSurface(eglDisplay->display, eglDisplay->config, surfAttribs); if (eglSurface == EGL_NO_SURFACE) { - throw std::runtime_error("Could not create surface: " + std::to_string(eglGetError())); + throw std::runtime_error("Could not create surface: " + util::toString(eglGetError())); } } |