mirror of https://github.com/AxioDL/metaforce.git
Fixes for Apple Silicon
This commit is contained in:
parent
ced84a1eb8
commit
fe9e74561e
|
@ -1 +1 @@
|
||||||
Subproject commit f298113c4ee410f561731921f4cabacdb8ddc232
|
Subproject commit 385392349a6b7647a155e3743a6fb35e61dc4d3c
|
|
@ -1 +1 @@
|
||||||
Subproject commit 6ae9e93d31f74c6e7168a49ccf85d4fda31205e7
|
Subproject commit 6faff77f86381dee6ace365aa2f8105cae4c5cd1
|
|
@ -3,13 +3,13 @@ find_library(PNG_LIB NAMES png libpng)
|
||||||
endif()
|
endif()
|
||||||
if(NOT PNG_LIB)
|
if(NOT PNG_LIB)
|
||||||
message(STATUS "Using HECL's built-in libpng")
|
message(STATUS "Using HECL's built-in libpng")
|
||||||
if(NX)
|
if("${CMAKE_SYSTEM_PROCESSOR}" MATCHES "arm(64)?")
|
||||||
set(INTRINSICS
|
set(INTRINSICS
|
||||||
arm/arm_init.c
|
arm/arm_init.c
|
||||||
arm/filter_neon.S
|
arm/filter_neon.S
|
||||||
arm/filter_neon_intrinsics.c
|
arm/filter_neon_intrinsics.c
|
||||||
arm/palette_neon_intrinsics.c)
|
arm/palette_neon_intrinsics.c)
|
||||||
else()
|
elseif(${CMAKE_SYSTEM_PROCESSOR} STREQUAL x86_64)
|
||||||
set(INTRINSICS
|
set(INTRINSICS
|
||||||
intel/filter_sse2_intrinsics.c
|
intel/filter_sse2_intrinsics.c
|
||||||
intel/intel_init.c)
|
intel/intel_init.c)
|
||||||
|
@ -39,6 +39,9 @@ add_library(png
|
||||||
pngwtran.c
|
pngwtran.c
|
||||||
pngwutil.c
|
pngwutil.c
|
||||||
${INTRINSICS})
|
${INTRINSICS})
|
||||||
|
if(APPLE)
|
||||||
|
target_compile_options(png PRIVATE -Wno-implicit-fallthrough)
|
||||||
|
endif()
|
||||||
target_link_libraries(png PUBLIC ${ZLIB_LIBRARIES})
|
target_link_libraries(png PUBLIC ${ZLIB_LIBRARIES})
|
||||||
target_include_directories(png PUBLIC ${ZLIB_INCLUDE_DIR})
|
target_include_directories(png PUBLIC ${ZLIB_INCLUDE_DIR})
|
||||||
set(PNG_LIBRARIES png CACHE PATH "PNG libraries" FORCE)
|
set(PNG_LIBRARIES png CACHE PATH "PNG libraries" FORCE)
|
||||||
|
|
|
@ -49,12 +49,9 @@ FileStoreManager::FileStoreManager(SystemStringView domain) : m_domain(domain) {
|
||||||
path = home;
|
path = home;
|
||||||
path += "/.local/share";
|
path += "/.local/share";
|
||||||
}
|
}
|
||||||
path += "/hecl";
|
path += "/hecl/";
|
||||||
if (mkdir(path.c_str(), 0755) && errno != EEXIST)
|
|
||||||
Log.report(logvisor::Fatal, FMT_STRING("unable to mkdir at {}"), path);
|
|
||||||
path += '/';
|
|
||||||
path += domain.data();
|
path += domain.data();
|
||||||
if (mkdir(path.c_str(), 0755) && errno != EEXIST)
|
if (RecursiveMakeDir(path.c_str()) != 0)
|
||||||
Log.report(logvisor::Fatal, FMT_STRING("unable to mkdir at {}"), path);
|
Log.report(logvisor::Fatal, FMT_STRING("unable to mkdir at {}"), path);
|
||||||
m_storeRoot = path;
|
m_storeRoot = path;
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue