mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2024-11-27 12:14:10 +08:00
ci/deqp: split vk/gl/gles patches
All files are identical copies for now, but this allows changing one without touching the others. Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27473>
This commit is contained in:
parent
74bcb91a91
commit
e9fb4d951b
@ -44,14 +44,14 @@ vk_cts_commits_to_backport=(
|
||||
vk_cts_patch_files=(
|
||||
# Derivate subgroup fix
|
||||
# https://github.com/KhronosGroup/VK-GL-CTS/pull/442
|
||||
build-deqp_Use-subgroups-helper-in-derivate-tests.patch
|
||||
build-deqp_Add-missing-subgroup-support-checks-for-linear-derivate-tests.patch
|
||||
build-deqp-vk_Use-subgroups-helper-in-derivate-tests.patch
|
||||
build-deqp-vk_Add-missing-subgroup-support-checks-for-linear-derivate-tests.patch
|
||||
)
|
||||
|
||||
if [ "${DEQP_TARGET}" = 'android' ]; then
|
||||
vk_cts_patch_files+=(
|
||||
build-deqp_Allow-running-on-Android-from-the-command-line.patch
|
||||
build-deqp_Android-prints-to-stdout-instead-of-logcat.patch
|
||||
build-deqp-vk_Allow-running-on-Android-from-the-command-line.patch
|
||||
build-deqp-vk_Android-prints-to-stdout-instead-of-logcat.patch
|
||||
)
|
||||
fi
|
||||
|
||||
@ -65,8 +65,8 @@ gl_cts_patch_files=(
|
||||
|
||||
if [ "${DEQP_TARGET}" = 'android' ]; then
|
||||
gl_cts_patch_files+=(
|
||||
build-deqp_Allow-running-on-Android-from-the-command-line.patch
|
||||
build-deqp_Android-prints-to-stdout-instead-of-logcat.patch
|
||||
build-deqp-gl_Allow-running-on-Android-from-the-command-line.patch
|
||||
build-deqp-gl_Android-prints-to-stdout-instead-of-logcat.patch
|
||||
)
|
||||
fi
|
||||
|
||||
@ -80,8 +80,8 @@ gles_cts_patch_files=(
|
||||
|
||||
if [ "${DEQP_TARGET}" = 'android' ]; then
|
||||
gles_cts_patch_files+=(
|
||||
build-deqp_Allow-running-on-Android-from-the-command-line.patch
|
||||
build-deqp_Android-prints-to-stdout-instead-of-logcat.patch
|
||||
build-deqp-gles_Allow-running-on-Android-from-the-command-line.patch
|
||||
build-deqp-gles_Android-prints-to-stdout-instead-of-logcat.patch
|
||||
)
|
||||
fi
|
||||
|
||||
|
@ -0,0 +1,173 @@
|
||||
From dc97ee83a813f6b170079ddf2a04bbb06221a5a7 Mon Sep 17 00:00:00 2001
|
||||
From: Tomeu Vizoso <tomeu.vizoso@collabora.com>
|
||||
Date: Fri, 26 Aug 2022 18:24:27 +0200
|
||||
Subject: [PATCH 1/2] Allow running on Android from the command line
|
||||
|
||||
For testing the Android EGL platform without having to go via the
|
||||
Android activity manager, build deqp-egl.
|
||||
|
||||
Tests that render to native windows are unsupported, as command line
|
||||
programs cannot create windows on Android.
|
||||
|
||||
$ cmake -S . -B build/ -DDEQP_TARGET=android -DDEQP_TARGET_TOOLCHAIN=ndk-modern -DCMAKE_C_FLAGS=-Werror -DCMAKE_CXX_FLAGS=-Werror -DANDROID_NDK_PATH=./android-ndk-r21d -DANDROID_ABI=x86_64 -DDE_ANDROID_API=28 -DGLCTS_GTF_TARGET=gles32 -G Ninja
|
||||
$ ninja -C build modules/egl/deqp-egl
|
||||
|
||||
Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
|
||||
---
|
||||
CMakeLists.txt | 36 ++-----------------
|
||||
.../android/tcuAndroidNativeActivity.cpp | 36 ++++++++++---------
|
||||
.../platform/android/tcuAndroidPlatform.cpp | 12 ++++++-
|
||||
3 files changed, 33 insertions(+), 51 deletions(-)
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index f9c61d0db..d6ad2990b 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -272,7 +272,7 @@ include_directories(
|
||||
external/vulkancts/framework/vulkan
|
||||
)
|
||||
|
||||
-if (DE_OS_IS_ANDROID OR DE_OS_IS_IOS)
|
||||
+if (DE_OS_IS_IOS)
|
||||
# On Android deqp modules are compiled as libraries and linked into final .so
|
||||
set(DEQP_MODULE_LIBRARIES )
|
||||
set(DEQP_MODULE_ENTRY_POINTS )
|
||||
@@ -316,7 +316,7 @@ macro (add_deqp_module MODULE_NAME SRCS LIBS EXECLIBS ENTRY)
|
||||
set(DEQP_MODULE_LIBRARIES ${DEQP_MODULE_LIBRARIES} PARENT_SCOPE)
|
||||
set(DEQP_MODULE_ENTRY_POINTS ${DEQP_MODULE_ENTRY_POINTS} PARENT_SCOPE)
|
||||
|
||||
- if (NOT DE_OS_IS_ANDROID AND NOT DE_OS_IS_IOS)
|
||||
+ if (NOT DE_OS_IS_IOS)
|
||||
# Executable target
|
||||
add_executable(${MODULE_NAME} ${PROJECT_SOURCE_DIR}/framework/platform/tcuMain.cpp ${ENTRY})
|
||||
target_link_libraries(${MODULE_NAME} PUBLIC "${EXECLIBS}" "${MODULE_NAME}${MODULE_LIB_TARGET_POSTFIX}")
|
||||
@@ -390,37 +390,7 @@ add_subdirectory(external/vulkancts/vkscpc ${MAYBE_EXCLUDE_FROM_ALL})
|
||||
add_subdirectory(external/openglcts ${MAYBE_EXCLUDE_FROM_ALL})
|
||||
|
||||
# Single-binary targets
|
||||
-if (DE_OS_IS_ANDROID)
|
||||
- include_directories(executor)
|
||||
- include_directories(${PROJECT_BINARY_DIR}/external/vulkancts/framework/vulkan)
|
||||
-
|
||||
- set(DEQP_SRCS
|
||||
- framework/platform/android/tcuAndroidMain.cpp
|
||||
- framework/platform/android/tcuAndroidJNI.cpp
|
||||
- framework/platform/android/tcuAndroidPlatformCapabilityQueryJNI.cpp
|
||||
- framework/platform/android/tcuTestLogParserJNI.cpp
|
||||
- ${DEQP_MODULE_ENTRY_POINTS}
|
||||
- )
|
||||
-
|
||||
- set(DEQP_LIBS
|
||||
- tcutil-platform
|
||||
- xecore
|
||||
- ${DEQP_MODULE_LIBRARIES}
|
||||
- )
|
||||
-
|
||||
- add_library(deqp SHARED ${DEQP_SRCS})
|
||||
- target_link_libraries(deqp ${DEQP_LIBS})
|
||||
-
|
||||
- # Separate out the debug information because it's enormous
|
||||
- add_custom_command(TARGET deqp POST_BUILD
|
||||
- COMMAND ${CMAKE_STRIP} --only-keep-debug -o $<TARGET_FILE:deqp>.debug $<TARGET_FILE:deqp>
|
||||
- COMMAND ${CMAKE_STRIP} -g $<TARGET_FILE:deqp>)
|
||||
-
|
||||
- # Needed by OpenGL CTS that defines its own activity but depends on
|
||||
- # common Android support code.
|
||||
- target_include_directories(deqp PRIVATE framework/platform/android)
|
||||
-
|
||||
-elseif (DE_OS_IS_IOS)
|
||||
+if (DE_OS_IS_IOS)
|
||||
# Code sign identity
|
||||
set(DEQP_IOS_CODE_SIGN_IDENTITY "drawElements" CACHE STRING "Code sign identity for iOS build")
|
||||
|
||||
diff --git a/framework/platform/android/tcuAndroidNativeActivity.cpp b/framework/platform/android/tcuAndroidNativeActivity.cpp
|
||||
index 6f8cd8fc5..b83e30f41 100644
|
||||
--- a/framework/platform/android/tcuAndroidNativeActivity.cpp
|
||||
+++ b/framework/platform/android/tcuAndroidNativeActivity.cpp
|
||||
@@ -116,23 +116,25 @@ namespace Android
|
||||
NativeActivity::NativeActivity (ANativeActivity* activity)
|
||||
: m_activity(activity)
|
||||
{
|
||||
- activity->instance = (void*)this;
|
||||
- activity->callbacks->onStart = onStartCallback;
|
||||
- activity->callbacks->onResume = onResumeCallback;
|
||||
- activity->callbacks->onSaveInstanceState = onSaveInstanceStateCallback;
|
||||
- activity->callbacks->onPause = onPauseCallback;
|
||||
- activity->callbacks->onStop = onStopCallback;
|
||||
- activity->callbacks->onDestroy = onDestroyCallback;
|
||||
- activity->callbacks->onWindowFocusChanged = onWindowFocusChangedCallback;
|
||||
- activity->callbacks->onNativeWindowCreated = onNativeWindowCreatedCallback;
|
||||
- activity->callbacks->onNativeWindowResized = onNativeWindowResizedCallback;
|
||||
- activity->callbacks->onNativeWindowRedrawNeeded = onNativeWindowRedrawNeededCallback;
|
||||
- activity->callbacks->onNativeWindowDestroyed = onNativeWindowDestroyedCallback;
|
||||
- activity->callbacks->onInputQueueCreated = onInputQueueCreatedCallback;
|
||||
- activity->callbacks->onInputQueueDestroyed = onInputQueueDestroyedCallback;
|
||||
- activity->callbacks->onContentRectChanged = onContentRectChangedCallback;
|
||||
- activity->callbacks->onConfigurationChanged = onConfigurationChangedCallback;
|
||||
- activity->callbacks->onLowMemory = onLowMemoryCallback;
|
||||
+ if (activity) {
|
||||
+ activity->instance = (void*)this;
|
||||
+ activity->callbacks->onStart = onStartCallback;
|
||||
+ activity->callbacks->onResume = onResumeCallback;
|
||||
+ activity->callbacks->onSaveInstanceState = onSaveInstanceStateCallback;
|
||||
+ activity->callbacks->onPause = onPauseCallback;
|
||||
+ activity->callbacks->onStop = onStopCallback;
|
||||
+ activity->callbacks->onDestroy = onDestroyCallback;
|
||||
+ activity->callbacks->onWindowFocusChanged = onWindowFocusChangedCallback;
|
||||
+ activity->callbacks->onNativeWindowCreated = onNativeWindowCreatedCallback;
|
||||
+ activity->callbacks->onNativeWindowResized = onNativeWindowResizedCallback;
|
||||
+ activity->callbacks->onNativeWindowRedrawNeeded = onNativeWindowRedrawNeededCallback;
|
||||
+ activity->callbacks->onNativeWindowDestroyed = onNativeWindowDestroyedCallback;
|
||||
+ activity->callbacks->onInputQueueCreated = onInputQueueCreatedCallback;
|
||||
+ activity->callbacks->onInputQueueDestroyed = onInputQueueDestroyedCallback;
|
||||
+ activity->callbacks->onContentRectChanged = onContentRectChangedCallback;
|
||||
+ activity->callbacks->onConfigurationChanged = onConfigurationChangedCallback;
|
||||
+ activity->callbacks->onLowMemory = onLowMemoryCallback;
|
||||
+ }
|
||||
}
|
||||
|
||||
NativeActivity::~NativeActivity (void)
|
||||
diff --git a/framework/platform/android/tcuAndroidPlatform.cpp b/framework/platform/android/tcuAndroidPlatform.cpp
|
||||
index b8a35898c..cf02e6b70 100644
|
||||
--- a/framework/platform/android/tcuAndroidPlatform.cpp
|
||||
+++ b/framework/platform/android/tcuAndroidPlatform.cpp
|
||||
@@ -22,6 +22,7 @@
|
||||
*//*--------------------------------------------------------------------*/
|
||||
|
||||
#include "tcuAndroidPlatform.hpp"
|
||||
+#include "tcuAndroidNativeActivity.hpp"
|
||||
#include "tcuAndroidUtil.hpp"
|
||||
#include "gluRenderContext.hpp"
|
||||
#include "egluNativeDisplay.hpp"
|
||||
@@ -170,7 +171,7 @@ eglu::NativeWindow* NativeWindowFactory::createWindow (const eglu::WindowParams&
|
||||
Window* window = m_windowRegistry.tryAcquireWindow();
|
||||
|
||||
if (!window)
|
||||
- throw ResourceError("Native window is not available", DE_NULL, __FILE__, __LINE__);
|
||||
+ throw NotSupportedError("Native window is not available", DE_NULL, __FILE__, __LINE__);
|
||||
|
||||
return new NativeWindow(window, params.width, params.height, format);
|
||||
}
|
||||
@@ -292,6 +293,9 @@ static size_t getTotalSystemMemory (ANativeActivity* activity)
|
||||
|
||||
try
|
||||
{
|
||||
+ if (!activity)
|
||||
+ throw tcu::InternalError("No activity (running from command line?");
|
||||
+
|
||||
const size_t totalMemory = getTotalAndroidSystemMemory(activity);
|
||||
print("Device has %.2f MiB of system memory\n", static_cast<double>(totalMemory) / static_cast<double>(MiB));
|
||||
return totalMemory;
|
||||
@@ -388,3 +392,9 @@ bool Platform::hasDisplay (vk::wsi::Type wsiType) const
|
||||
|
||||
} // Android
|
||||
} // tcu
|
||||
+
|
||||
+tcu::Platform* createPlatform (void)
|
||||
+{
|
||||
+ tcu::Android::NativeActivity activity(NULL);
|
||||
+ return new tcu::Android::Platform(activity);
|
||||
+}
|
||||
--
|
||||
2.42.0
|
||||
|
@ -0,0 +1,26 @@
|
||||
From a602822c53e22e985f942f843ccadbfb64613212 Mon Sep 17 00:00:00 2001
|
||||
From: Helen Koike <helen.koike@collabora.com>
|
||||
Date: Tue, 27 Sep 2022 12:35:22 -0300
|
||||
Subject: [PATCH 2/2] Android prints to stdout instead of logcat
|
||||
|
||||
Signed-off-by: Helen Koike <helen.koike@collabora.com>
|
||||
---
|
||||
framework/qphelper/qpDebugOut.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/framework/qphelper/qpDebugOut.c b/framework/qphelper/qpDebugOut.c
|
||||
index 6579e9f48..c200c6f6b 100644
|
||||
--- a/framework/qphelper/qpDebugOut.c
|
||||
+++ b/framework/qphelper/qpDebugOut.c
|
||||
@@ -98,7 +98,7 @@ void qpDiev (const char* format, va_list args)
|
||||
}
|
||||
|
||||
/* print() implementation. */
|
||||
-#if (DE_OS == DE_OS_ANDROID)
|
||||
+#if (0)
|
||||
|
||||
#include <android/log.h>
|
||||
|
||||
--
|
||||
2.42.0
|
||||
|
@ -0,0 +1,173 @@
|
||||
From dc97ee83a813f6b170079ddf2a04bbb06221a5a7 Mon Sep 17 00:00:00 2001
|
||||
From: Tomeu Vizoso <tomeu.vizoso@collabora.com>
|
||||
Date: Fri, 26 Aug 2022 18:24:27 +0200
|
||||
Subject: [PATCH 1/2] Allow running on Android from the command line
|
||||
|
||||
For testing the Android EGL platform without having to go via the
|
||||
Android activity manager, build deqp-egl.
|
||||
|
||||
Tests that render to native windows are unsupported, as command line
|
||||
programs cannot create windows on Android.
|
||||
|
||||
$ cmake -S . -B build/ -DDEQP_TARGET=android -DDEQP_TARGET_TOOLCHAIN=ndk-modern -DCMAKE_C_FLAGS=-Werror -DCMAKE_CXX_FLAGS=-Werror -DANDROID_NDK_PATH=./android-ndk-r21d -DANDROID_ABI=x86_64 -DDE_ANDROID_API=28 -DGLCTS_GTF_TARGET=gles32 -G Ninja
|
||||
$ ninja -C build modules/egl/deqp-egl
|
||||
|
||||
Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
|
||||
---
|
||||
CMakeLists.txt | 36 ++-----------------
|
||||
.../android/tcuAndroidNativeActivity.cpp | 36 ++++++++++---------
|
||||
.../platform/android/tcuAndroidPlatform.cpp | 12 ++++++-
|
||||
3 files changed, 33 insertions(+), 51 deletions(-)
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index f9c61d0db..d6ad2990b 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -272,7 +272,7 @@ include_directories(
|
||||
external/vulkancts/framework/vulkan
|
||||
)
|
||||
|
||||
-if (DE_OS_IS_ANDROID OR DE_OS_IS_IOS)
|
||||
+if (DE_OS_IS_IOS)
|
||||
# On Android deqp modules are compiled as libraries and linked into final .so
|
||||
set(DEQP_MODULE_LIBRARIES )
|
||||
set(DEQP_MODULE_ENTRY_POINTS )
|
||||
@@ -316,7 +316,7 @@ macro (add_deqp_module MODULE_NAME SRCS LIBS EXECLIBS ENTRY)
|
||||
set(DEQP_MODULE_LIBRARIES ${DEQP_MODULE_LIBRARIES} PARENT_SCOPE)
|
||||
set(DEQP_MODULE_ENTRY_POINTS ${DEQP_MODULE_ENTRY_POINTS} PARENT_SCOPE)
|
||||
|
||||
- if (NOT DE_OS_IS_ANDROID AND NOT DE_OS_IS_IOS)
|
||||
+ if (NOT DE_OS_IS_IOS)
|
||||
# Executable target
|
||||
add_executable(${MODULE_NAME} ${PROJECT_SOURCE_DIR}/framework/platform/tcuMain.cpp ${ENTRY})
|
||||
target_link_libraries(${MODULE_NAME} PUBLIC "${EXECLIBS}" "${MODULE_NAME}${MODULE_LIB_TARGET_POSTFIX}")
|
||||
@@ -390,37 +390,7 @@ add_subdirectory(external/vulkancts/vkscpc ${MAYBE_EXCLUDE_FROM_ALL})
|
||||
add_subdirectory(external/openglcts ${MAYBE_EXCLUDE_FROM_ALL})
|
||||
|
||||
# Single-binary targets
|
||||
-if (DE_OS_IS_ANDROID)
|
||||
- include_directories(executor)
|
||||
- include_directories(${PROJECT_BINARY_DIR}/external/vulkancts/framework/vulkan)
|
||||
-
|
||||
- set(DEQP_SRCS
|
||||
- framework/platform/android/tcuAndroidMain.cpp
|
||||
- framework/platform/android/tcuAndroidJNI.cpp
|
||||
- framework/platform/android/tcuAndroidPlatformCapabilityQueryJNI.cpp
|
||||
- framework/platform/android/tcuTestLogParserJNI.cpp
|
||||
- ${DEQP_MODULE_ENTRY_POINTS}
|
||||
- )
|
||||
-
|
||||
- set(DEQP_LIBS
|
||||
- tcutil-platform
|
||||
- xecore
|
||||
- ${DEQP_MODULE_LIBRARIES}
|
||||
- )
|
||||
-
|
||||
- add_library(deqp SHARED ${DEQP_SRCS})
|
||||
- target_link_libraries(deqp ${DEQP_LIBS})
|
||||
-
|
||||
- # Separate out the debug information because it's enormous
|
||||
- add_custom_command(TARGET deqp POST_BUILD
|
||||
- COMMAND ${CMAKE_STRIP} --only-keep-debug -o $<TARGET_FILE:deqp>.debug $<TARGET_FILE:deqp>
|
||||
- COMMAND ${CMAKE_STRIP} -g $<TARGET_FILE:deqp>)
|
||||
-
|
||||
- # Needed by OpenGL CTS that defines its own activity but depends on
|
||||
- # common Android support code.
|
||||
- target_include_directories(deqp PRIVATE framework/platform/android)
|
||||
-
|
||||
-elseif (DE_OS_IS_IOS)
|
||||
+if (DE_OS_IS_IOS)
|
||||
# Code sign identity
|
||||
set(DEQP_IOS_CODE_SIGN_IDENTITY "drawElements" CACHE STRING "Code sign identity for iOS build")
|
||||
|
||||
diff --git a/framework/platform/android/tcuAndroidNativeActivity.cpp b/framework/platform/android/tcuAndroidNativeActivity.cpp
|
||||
index 6f8cd8fc5..b83e30f41 100644
|
||||
--- a/framework/platform/android/tcuAndroidNativeActivity.cpp
|
||||
+++ b/framework/platform/android/tcuAndroidNativeActivity.cpp
|
||||
@@ -116,23 +116,25 @@ namespace Android
|
||||
NativeActivity::NativeActivity (ANativeActivity* activity)
|
||||
: m_activity(activity)
|
||||
{
|
||||
- activity->instance = (void*)this;
|
||||
- activity->callbacks->onStart = onStartCallback;
|
||||
- activity->callbacks->onResume = onResumeCallback;
|
||||
- activity->callbacks->onSaveInstanceState = onSaveInstanceStateCallback;
|
||||
- activity->callbacks->onPause = onPauseCallback;
|
||||
- activity->callbacks->onStop = onStopCallback;
|
||||
- activity->callbacks->onDestroy = onDestroyCallback;
|
||||
- activity->callbacks->onWindowFocusChanged = onWindowFocusChangedCallback;
|
||||
- activity->callbacks->onNativeWindowCreated = onNativeWindowCreatedCallback;
|
||||
- activity->callbacks->onNativeWindowResized = onNativeWindowResizedCallback;
|
||||
- activity->callbacks->onNativeWindowRedrawNeeded = onNativeWindowRedrawNeededCallback;
|
||||
- activity->callbacks->onNativeWindowDestroyed = onNativeWindowDestroyedCallback;
|
||||
- activity->callbacks->onInputQueueCreated = onInputQueueCreatedCallback;
|
||||
- activity->callbacks->onInputQueueDestroyed = onInputQueueDestroyedCallback;
|
||||
- activity->callbacks->onContentRectChanged = onContentRectChangedCallback;
|
||||
- activity->callbacks->onConfigurationChanged = onConfigurationChangedCallback;
|
||||
- activity->callbacks->onLowMemory = onLowMemoryCallback;
|
||||
+ if (activity) {
|
||||
+ activity->instance = (void*)this;
|
||||
+ activity->callbacks->onStart = onStartCallback;
|
||||
+ activity->callbacks->onResume = onResumeCallback;
|
||||
+ activity->callbacks->onSaveInstanceState = onSaveInstanceStateCallback;
|
||||
+ activity->callbacks->onPause = onPauseCallback;
|
||||
+ activity->callbacks->onStop = onStopCallback;
|
||||
+ activity->callbacks->onDestroy = onDestroyCallback;
|
||||
+ activity->callbacks->onWindowFocusChanged = onWindowFocusChangedCallback;
|
||||
+ activity->callbacks->onNativeWindowCreated = onNativeWindowCreatedCallback;
|
||||
+ activity->callbacks->onNativeWindowResized = onNativeWindowResizedCallback;
|
||||
+ activity->callbacks->onNativeWindowRedrawNeeded = onNativeWindowRedrawNeededCallback;
|
||||
+ activity->callbacks->onNativeWindowDestroyed = onNativeWindowDestroyedCallback;
|
||||
+ activity->callbacks->onInputQueueCreated = onInputQueueCreatedCallback;
|
||||
+ activity->callbacks->onInputQueueDestroyed = onInputQueueDestroyedCallback;
|
||||
+ activity->callbacks->onContentRectChanged = onContentRectChangedCallback;
|
||||
+ activity->callbacks->onConfigurationChanged = onConfigurationChangedCallback;
|
||||
+ activity->callbacks->onLowMemory = onLowMemoryCallback;
|
||||
+ }
|
||||
}
|
||||
|
||||
NativeActivity::~NativeActivity (void)
|
||||
diff --git a/framework/platform/android/tcuAndroidPlatform.cpp b/framework/platform/android/tcuAndroidPlatform.cpp
|
||||
index b8a35898c..cf02e6b70 100644
|
||||
--- a/framework/platform/android/tcuAndroidPlatform.cpp
|
||||
+++ b/framework/platform/android/tcuAndroidPlatform.cpp
|
||||
@@ -22,6 +22,7 @@
|
||||
*//*--------------------------------------------------------------------*/
|
||||
|
||||
#include "tcuAndroidPlatform.hpp"
|
||||
+#include "tcuAndroidNativeActivity.hpp"
|
||||
#include "tcuAndroidUtil.hpp"
|
||||
#include "gluRenderContext.hpp"
|
||||
#include "egluNativeDisplay.hpp"
|
||||
@@ -170,7 +171,7 @@ eglu::NativeWindow* NativeWindowFactory::createWindow (const eglu::WindowParams&
|
||||
Window* window = m_windowRegistry.tryAcquireWindow();
|
||||
|
||||
if (!window)
|
||||
- throw ResourceError("Native window is not available", DE_NULL, __FILE__, __LINE__);
|
||||
+ throw NotSupportedError("Native window is not available", DE_NULL, __FILE__, __LINE__);
|
||||
|
||||
return new NativeWindow(window, params.width, params.height, format);
|
||||
}
|
||||
@@ -292,6 +293,9 @@ static size_t getTotalSystemMemory (ANativeActivity* activity)
|
||||
|
||||
try
|
||||
{
|
||||
+ if (!activity)
|
||||
+ throw tcu::InternalError("No activity (running from command line?");
|
||||
+
|
||||
const size_t totalMemory = getTotalAndroidSystemMemory(activity);
|
||||
print("Device has %.2f MiB of system memory\n", static_cast<double>(totalMemory) / static_cast<double>(MiB));
|
||||
return totalMemory;
|
||||
@@ -388,3 +392,9 @@ bool Platform::hasDisplay (vk::wsi::Type wsiType) const
|
||||
|
||||
} // Android
|
||||
} // tcu
|
||||
+
|
||||
+tcu::Platform* createPlatform (void)
|
||||
+{
|
||||
+ tcu::Android::NativeActivity activity(NULL);
|
||||
+ return new tcu::Android::Platform(activity);
|
||||
+}
|
||||
--
|
||||
2.42.0
|
||||
|
@ -0,0 +1,26 @@
|
||||
From a602822c53e22e985f942f843ccadbfb64613212 Mon Sep 17 00:00:00 2001
|
||||
From: Helen Koike <helen.koike@collabora.com>
|
||||
Date: Tue, 27 Sep 2022 12:35:22 -0300
|
||||
Subject: [PATCH 2/2] Android prints to stdout instead of logcat
|
||||
|
||||
Signed-off-by: Helen Koike <helen.koike@collabora.com>
|
||||
---
|
||||
framework/qphelper/qpDebugOut.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/framework/qphelper/qpDebugOut.c b/framework/qphelper/qpDebugOut.c
|
||||
index 6579e9f48..c200c6f6b 100644
|
||||
--- a/framework/qphelper/qpDebugOut.c
|
||||
+++ b/framework/qphelper/qpDebugOut.c
|
||||
@@ -98,7 +98,7 @@ void qpDiev (const char* format, va_list args)
|
||||
}
|
||||
|
||||
/* print() implementation. */
|
||||
-#if (DE_OS == DE_OS_ANDROID)
|
||||
+#if (0)
|
||||
|
||||
#include <android/log.h>
|
||||
|
||||
--
|
||||
2.42.0
|
||||
|
@ -24,10 +24,10 @@ variables:
|
||||
DEBIAN_X86_64_TEST_IMAGE_VK_PATH: "debian/x86_64_test-vk"
|
||||
DEBIAN_X86_64_TEST_ANDROID_IMAGE_PATH: "debian/x86_64_test-android"
|
||||
|
||||
DEBIAN_X86_64_TEST_ANDROID_TAG: "20240301-split-gles"
|
||||
DEBIAN_X86_64_TEST_GL_TAG: "20240301-split-gles"
|
||||
DEBIAN_X86_64_TEST_VK_TAG: "20240301-split-gl"
|
||||
KERNEL_ROOTFS_TAG: "20240301-split-gles"
|
||||
DEBIAN_X86_64_TEST_ANDROID_TAG: "20240301-patches"
|
||||
DEBIAN_X86_64_TEST_GL_TAG: "20240301-patches"
|
||||
DEBIAN_X86_64_TEST_VK_TAG: "20240301-patches"
|
||||
KERNEL_ROOTFS_TAG: "20240301-patches"
|
||||
|
||||
ALPINE_X86_64_BUILD_TAG: "20240208-libclc-5"
|
||||
ALPINE_X86_64_LAVA_SSH_TAG: "20230626-v1"
|
||||
|
Loading…
Reference in New Issue
Block a user