Add osx-arm64 target

This commit is contained in:
twinaphex 2021-03-09 22:05:36 +01:00
parent 45c8ef0a0b
commit bd36c9c77d
3 changed files with 32 additions and 27 deletions

View File

@ -33,6 +33,10 @@ include:
- project: 'libretro-infrastructure/ci-templates' - project: 'libretro-infrastructure/ci-templates'
file: '/osx-x64.yml' file: '/osx-x64.yml'
# MacOS ARM 64-bit
- project: 'libretro-infrastructure/ci-templates'
file: '/osx-arm64.yml'
################################## CELLULAR ################################ ################################## CELLULAR ################################
# Android # Android
- project: 'libretro-infrastructure/ci-templates' - project: 'libretro-infrastructure/ci-templates'
@ -114,6 +118,12 @@ libretro-build-osx-x64:
- .libretro-osx-x64-make-default - .libretro-osx-x64-make-default
- .core-defs - .core-defs
# MacOS ARM 64-bit
libretro-build-osx-arm64:
extends:
- .libretro-osx-arm64-make-default
- .core-defs
################################### CELLULAR ################################# ################################### CELLULAR #################################
# Android ARMv8a # Android ARMv8a
android-arm64-v8a: android-arm64-v8a:

View File

@ -7,24 +7,16 @@ HAVE_MMAP_WIN32=0
UNAME=$(shell uname -a) UNAME=$(shell uname -a)
ifneq ($(EMSCRIPTEN),) # platform
platform = emscripten
endif
ifeq ($(platform),) ifeq ($(platform),)
platform = unix platform = unix
ifeq ($(UNAME),) ifeq ($(shell uname -s),)
platform = win platform = win
else ifneq ($(findstring MINGW,$(UNAME)),) else ifneq ($(findstring MINGW,$(shell uname -s)),)
platform = win platform = win
else ifneq ($(findstring Darwin,$(UNAME)),) else ifneq ($(findstring Darwin,$(shell uname -s)),)
platform = osx platform = osx
arch = intel else ifneq ($(findstring win,$(shell uname -s)),)
ifeq ($(shell uname -p),powerpc)
arch = ppc
FORCE_32BIT_ARCH = 1
endif
else ifneq ($(findstring win,$(UNAME)),)
platform = win platform = win
endif endif
endif endif
@ -48,16 +40,19 @@ endif
# system platform # system platform
system_platform = unix system_platform = unix
ifeq ($(UNAME),) ifeq ($(shell uname -a),)
EXE_EXT = .exe EXE_EXT = .exe
system_platform = win system_platform = win
else ifneq ($(findstring Darwin,$(UNAME)),) else ifneq ($(findstring Darwin,$(shell uname -a)),)
system_platform = osx system_platform = osx
arch = intel arch = intel
ifeq ($(shell uname -p),powerpc) ifeq ($(shell uname -p),powerpc)
arch = ppc arch = ppc
endif endif
else ifneq ($(findstring MINGW,$(UNAME)),) ifeq ($(shell uname -p),arm)
arch = arm
endif
else ifneq ($(findstring MINGW,$(shell uname -a)),)
system_platform = win system_platform = win
endif endif

View File

@ -833,17 +833,17 @@ bool retro_load_game(const struct retro_game_info* info)
extract_directory(main_path, info->path, sizeof(main_path)); extract_directory(main_path, info->path, sizeof(main_path));
if (environ_cb(RETRO_ENVIRONMENT_GET_SYSTEM_DIRECTORY, &dir) && dir) if (environ_cb(RETRO_ENVIRONMENT_GET_SYSTEM_DIRECTORY, &dir) && dir)
strncpy(filename_bios, dir, sizeof(filename_bios)); strcpy(filename_bios, dir);
else else
strncpy(filename_bios, main_path, sizeof(filename_bios)); strcpy(filename_bios, main_path);
strncat(filename_bios, "/gba_bios.bin", sizeof(filename_bios)); strcat(filename_bios, "/gba_bios.bin");
if (environ_cb(RETRO_ENVIRONMENT_GET_SAVE_DIRECTORY, &dir) && dir) if (environ_cb(RETRO_ENVIRONMENT_GET_SAVE_DIRECTORY, &dir) && dir)
strncpy(save_path, dir, sizeof(save_path)); strcpy(save_path, dir);
else else
strncpy(save_path, main_path, sizeof(save_path)); strcpy(save_path, main_path);
if (load_bios(filename_bios) != 0) if (load_bios(filename_bios) != 0)
{ {