1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-02-01 04:45:36 +00:00

Merge branch 'apple-silicon-arm-build' into 'master'

Get build working on Apple Silicon

See merge request OpenMW/openmw!2286

(cherry picked from commit 36fbef1048)

1d7d3d57 Get build working on Apple Silicon
808a2e58 Merge commit '5ee4ce1232b0f334f29dd702f811c58dccf5c00d' into apple-silicon-arm-build
a61237f2 Cleaned up macOS FFmpeg framework linking
This commit is contained in:
psi29a 2022-08-21 20:15:01 +00:00
parent 2f1b4eb699
commit 03e24b1e70
2 changed files with 7 additions and 4 deletions

View file

@ -221,9 +221,12 @@ if(APPLE)
target_link_libraries(openmw ${COCOA_FRAMEWORK} ${IOKIT_FRAMEWORK}) target_link_libraries(openmw ${COCOA_FRAMEWORK} ${IOKIT_FRAMEWORK})
if (FFmpeg_FOUND) if (FFmpeg_FOUND)
find_library(COREVIDEO_FRAMEWORK CoreVideo) target_link_libraries(openmw z)
find_library(VDA_FRAMEWORK VideoDecodeAcceleration) target_link_options(openmw PRIVATE "LINKER:SHELL:-framework CoreVideo"
target_link_libraries(openmw z ${COREVIDEO_FRAMEWORK} ${VDA_FRAMEWORK}) "LINKER:SHELL:-framework CoreMedia"
"LINKER:SHELL:-framework VideoToolbox"
"LINKER:SHELL:-framework AudioToolbox"
"LINKER:SHELL:-framework VideoDecodeAcceleration")
endif() endif()
endif(APPLE) endif(APPLE)

View file

@ -104,7 +104,7 @@ void ESM::LuaScriptsCfg::adjustRefNums(const ESMReader& esm)
throw std::runtime_error("Incorrect contentFile index"); throw std::runtime_error("Incorrect contentFile index");
}; };
lua_State* L = lua_open(); lua_State* L = luaL_newstate();
LuaUtil::BasicSerializer serializer(adjustRefNumFn); LuaUtil::BasicSerializer serializer(adjustRefNumFn);
auto adjustLuaData = [&](std::string& data) auto adjustLuaData = [&](std::string& data)