diff --git a/build-scripts/build-release.py b/build-scripts/build-release.py index e25bda8c11ce0..747797091a59b 100755 --- a/build-scripts/build-release.py +++ b/build-scripts/build-release.py @@ -1517,7 +1517,7 @@ def main(argv=None) -> int: if args.android_home is None or not Path(args.android_home).is_dir(): parser.error("Invalid $ANDROID_HOME or --android-home: must be a directory containing the Android SDK") if args.android_ndk_home is None or not Path(args.android_ndk_home).is_dir(): - parser.error("Invalid $ANDROID_NDK_HOME or --android_ndk_home: must be a directory containing the Android NDK") + parser.error("Invalid $ANDROID_NDK_HOME or --android-ndk-home: must be a directory containing the Android NDK") if args.android_api is None: with section_printer.group("Detect Android APIS"): args.android_api = releaser._detect_android_api(android_home=args.android_home) diff --git a/build-scripts/pkg-support/android/aar/__main__.py.in b/build-scripts/pkg-support/android/aar/__main__.py.in index 344cf719370c1..917049f443e31 100755 --- a/build-scripts/pkg-support/android/aar/__main__.py.in +++ b/build-scripts/pkg-support/android/aar/__main__.py.in @@ -26,7 +26,6 @@ import zipfile AAR_PATH = pathlib.Path(__file__).resolve().parent -ANDROID_ARCHS = { "armeabi-v7a", "arm64-v8a", "x86", "x86_64" } def main(): diff --git a/cmake/sdlcpu.cmake b/cmake/sdlcpu.cmake index 5c4b575ec0fac..a27e7329c4a5f 100644 --- a/cmake/sdlcpu.cmake +++ b/cmake/sdlcpu.cmake @@ -1,6 +1,6 @@ function(SDL_DetectTargetCPUArchitectures DETECTED_ARCHS) - set(known_archs EMSCRIPTEN ARM32 ARM64 ARM64EC LOONGARCH64 POWERPC32 POWERPC64 X86 X64) + set(known_archs EMSCRIPTEN ARM32 ARM64 ARM64EC LOONGARCH64 POWERPC32 POWERPC64 RISCV32 RISCV64 X86 X64) if(APPLE AND CMAKE_OSX_ARCHITECTURES) foreach(known_arch IN LISTS known_archs) @@ -39,6 +39,8 @@ function(SDL_DetectTargetCPUArchitectures DETECTED_ARCHS) set(arch_check_LOONGARCH64 "defined(__loongarch64)") set(arch_check_POWERPC32 "(defined(__PPC__) || defined(__powerpc__)) && !defined(__powerpc64__)") set(arch_check_POWERPC64 "defined(__PPC64__) || defined(__powerpc64__)") + set(arch_check_RISCV32 "defined(__riscv) && defined(__riscv_xlen) && __riscv_xlen == 32") + set(arch_check_RISCV64 "defined(__riscv) && defined(__riscv_xlen) && __riscv_xlen == 64") set(arch_check_X86 "defined(__i386__) || defined(__i486__) || defined(__i586__) || defined(__i686__) ||defined( __i386) || defined(_M_IX86)") set(arch_check_X64 "(defined(__amd64__) || defined(__amd64) || defined(__x86_64__) || defined(__x86_64) || defined(_M_X64) || defined(_M_AMD64)) && !defined(_M_ARM64EC)") diff --git a/src/joystick/SDL_gamepad.c b/src/joystick/SDL_gamepad.c index 112f3ed99aa57..481278931c4de 100644 --- a/src/joystick/SDL_gamepad.c +++ b/src/joystick/SDL_gamepad.c @@ -2559,7 +2559,7 @@ static int SDL_PrivateAddGamepadMapping(const char *mappingString, SDL_GamepadMa } } -#ifdef ANDROID +#ifdef SDL_PLATFORM_ANDROID { // Extract and verify the SDK version const char *tmp;