[Scummvm-git-logs] scummvm branch-2-7-0-android -> 969f41ab9333292cf172ffa9159e48fc9c70925f
lephilousophe
noreply at scummvm.org
Sun Apr 2 10:39:23 UTC 2023
This automated email contains information about 3 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
6d4268261c ANDROID: Don't set DATA_DIR and PLUGIN_DIRECTORY
dd2c020cb2 ANDROID: Bundle cacert.pem and don't disable certificate checks
969f41ab93 ANDROID: Remove ANDROID_PLAIN_PORT defines
Commit: 6d4268261c20548d4b208cb727462f0c8b5035ca
https://github.com/scummvm/scummvm/commit/6d4268261c20548d4b208cb727462f0c8b5035ca
Author: Le Philousophe (lephilousophe at users.noreply.github.com)
Date: 2023-04-02T12:37:15+02:00
Commit Message:
ANDROID: Don't set DATA_DIR and PLUGIN_DIRECTORY
Android doesn't have the concept of prefix so these pointed to something
invalid
Changed paths:
configure
diff --git a/configure b/configure
index 6f44008abdb..911ea545dc5 100755
--- a/configure
+++ b/configure
@@ -6268,7 +6268,8 @@ test "x$prefix" = xNONE && prefix=/usr/local
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
case $_host_os in
- ds | mingw*)
+ android | ds | mingw*)
+ # Android don't have a fixed prefix
# Windows stores all the external data files in executable file.
;;
*)
@@ -6280,6 +6281,9 @@ case $_host in
3ds)
append_var DEFINES "-DPLUGIN_DIRECTORY=\\\"$datadir/plugins\\\""
;;
+ android-*)
+ # Android don't have a fixed prefix
+ ;;
ds)
;;
openpandora)
Commit: dd2c020cb20920bd06724e3407484f8a08e0e8b2
https://github.com/scummvm/scummvm/commit/dd2c020cb20920bd06724e3407484f8a08e0e8b2
Author: Le Philousophe (lephilousophe at users.noreply.github.com)
Date: 2023-04-02T12:37:15+02:00
Commit Message:
ANDROID: Bundle cacert.pem and don't disable certificate checks
Changed paths:
backends/networking/curl/connectionmanager.cpp
backends/networking/curl/networkreadstream.cpp
backends/platform/android/android.mk
diff --git a/backends/networking/curl/connectionmanager.cpp b/backends/networking/curl/connectionmanager.cpp
index 2091e71de51..230d6a007ef 100644
--- a/backends/networking/curl/connectionmanager.cpp
+++ b/backends/networking/curl/connectionmanager.cpp
@@ -99,7 +99,15 @@ uint32 ConnectionManager::getCloudRequestsPeriodInMicroseconds() {
}
const char *ConnectionManager::getCaCertPath() {
-#if defined(DATA_PATH)
+#if defined(__ANDROID__)
+ Common::ArchiveMemberPtr member = SearchMan.getMember("cacert.pem");
+ Common::FSNode *node = dynamic_cast<Common::FSNode *>(member.get());
+ if (!node) {
+ return nullptr;
+ }
+
+ return node->getPath().c_str();
+#elif defined(DATA_PATH)
static enum {
kNotInitialized,
kFileNotFound,
diff --git a/backends/networking/curl/networkreadstream.cpp b/backends/networking/curl/networkreadstream.cpp
index c7ae1ee9142..9b470787b56 100644
--- a/backends/networking/curl/networkreadstream.cpp
+++ b/backends/networking/curl/networkreadstream.cpp
@@ -92,7 +92,7 @@ void NetworkReadStream::initCurl(const char *url, curl_slist *headersList) {
curl_easy_setopt(_easy, CURLOPT_NOPROGRESS, 0L);
curl_easy_setopt(_easy, CURLOPT_PROGRESSFUNCTION, curlProgressCallbackOlder);
curl_easy_setopt(_easy, CURLOPT_PROGRESSDATA, this);
-#if defined NINTENDO_SWITCH || defined ANDROID_PLAIN_PORT || defined PSP2
+#if defined NINTENDO_SWITCH || defined PSP2
curl_easy_setopt(_easy, CURLOPT_SSL_VERIFYPEER, 0);
#endif
diff --git a/backends/platform/android/android.mk b/backends/platform/android/android.mk
index 4e045e94688..8a1294990f4 100644
--- a/backends/platform/android/android.mk
+++ b/backends/platform/android/android.mk
@@ -34,15 +34,28 @@ ifneq ($(DIST_FILES_SHADERS),)
$(INSTALL) -c -m 644 $(DIST_FILES_SHADERS) $(PATH_BUILD_ASSETS)/shaders
endif
+ifdef DIST_ANDROID_CACERT_PEM
+$(PATH_BUILD_ASSETS)/cacert.pem: $(DIST_ANDROID_CACERT_PEM) | $(PATH_BUILD_ASSETS)
+ $(INSTALL) -c -m 644 $(DIST_ANDROID_CACERT_PEM) $(PATH_BUILD_ASSETS)/cacert.pem
+else
+ifdef USE_CURL
+$(PATH_BUILD_ASSETS)/cacert.pem: | $(PATH_BUILD_ASSETS)
+ $(QUIET_CURL)$(CURL) -s https://curl.se/ca/cacert.pem --time-cond $(PATH_BUILD_ASSETS)/cacert.pem --output $(PATH_BUILD_ASSETS)/cacert.pem
+androidcacert: | $(PATH_BUILD_ASSETS)
+ $(QUIET_CURL)$(CURL) -s https://curl.se/ca/cacert.pem --time-cond $(PATH_BUILD_ASSETS)/cacert.pem --output $(PATH_BUILD_ASSETS)/cacert.pem
+.PHONY: androidcacert
+endif
+endif
+
$(PATH_BUILD_LIBSCUMMVM): libscummvm.so | $(PATH_BUILD)
$(INSTALL) -d $(PATH_BUILD_LIB)
$(INSTALL) -c -m 644 libscummvm.so $(PATH_BUILD_LIBSCUMMVM)
-$(APK_MAIN): $(PATH_BUILD_GRADLE) $(PATH_BUILD_ASSETS) $(PATH_BUILD_LIBSCUMMVM) | $(PATH_BUILD)
+$(APK_MAIN): $(PATH_BUILD_GRADLE) $(PATH_BUILD_ASSETS) $(PATH_BUILD_ASSETS)/cacert.pem $(PATH_BUILD_LIBSCUMMVM) | $(PATH_BUILD)
(cd $(PATH_BUILD); ./gradlew assembleDebug)
$(CP) $(PATH_BUILD)/build/outputs/apk/debug/$(APK_MAIN) $@
-$(APK_MAIN_RELEASE): $(PATH_BUILD_GRADLE) $(PATH_BUILD_ASSETS) $(PATH_BUILD_LIBSCUMMVM) | $(PATH_BUILD)
+$(APK_MAIN_RELEASE): $(PATH_BUILD_GRADLE) $(PATH_BUILD_ASSETS) $(PATH_BUILD_ASSETS)/cacert.pem $(PATH_BUILD_LIBSCUMMVM) | $(PATH_BUILD)
(cd $(PATH_BUILD); ./gradlew assembleRelease)
$(CP) $(PATH_BUILD)/build/outputs/apk/release/$(APK_MAIN_RELEASE) $@
Commit: 969f41ab9333292cf172ffa9159e48fc9c70925f
https://github.com/scummvm/scummvm/commit/969f41ab9333292cf172ffa9159e48fc9c70925f
Author: Le Philousophe (lephilousophe at users.noreply.github.com)
Date: 2023-04-02T12:37:15+02:00
Commit Message:
ANDROID: Remove ANDROID_PLAIN_PORT defines
They are not used anymore and we don't have any other kind of port
anymore
Changed paths:
configure
diff --git a/configure b/configure
index 911ea545dc5..e4629ee30c4 100755
--- a/configure
+++ b/configure
@@ -3260,8 +3260,7 @@ if test -n "$_host"; then
_port_mk="backends/platform/3ds/3ds.mk"
;;
android-arm-v7a | android-arm64-v8a | android-x86 | android-x86_64 | ouya)
- # also __ANDROID__ is defined by Clang in the NDK
- DEFINES="$DEFINES -D__ANDROID_PLAIN_PORT__ -DANDROID_PLAIN_PORT"
+ # __ANDROID__ is defined by Clang in the NDK
# we link a .so as default
append_var LDFLAGS "-shared"
append_var LDFLAGS "-Wl,-Bsymbolic,--no-undefined"
More information about the Scummvm-git-logs
mailing list