all repos — mgba @ d2af8b83e06019ed28b68ec311fcffc3c863433d

mGBA Game Boy Advance Emulator

CMake: Fix build with downstream minizip that exports incompatible symbols
Vicki Pfau vi@endrift.com
Wed, 04 Nov 2020 18:27:53 -0800
commit

d2af8b83e06019ed28b68ec311fcffc3c863433d

parent

01e73bc15f11d759a3327fb37edddb07be54b6cc

2 files changed, 7 insertions(+), 0 deletions(-)

jump to
M CHANGESCHANGES

@@ -45,6 +45,7 @@ - SM83: Emulate HALT bug

Other fixes: - 3DS: Fix thread cleanup - All: Improve export headers (fixes mgba.io/i/1738) + - CMake: Fix build with downstream minizip that exports incompatible symbols - Core: Ensure ELF regions can be written before trying - Debugger: Don't skip undefined instructions when debugger attached - FFmpeg: Fix some small memory leaks
M CMakeLists.txtCMakeLists.txt

@@ -664,6 +664,12 @@ list(APPEND DEPENDENCY_LIB ${MINIZIP_LIBRARIES})

list(APPEND FEATURES MINIZIP) list(APPEND VFS_SRC ${CMAKE_CURRENT_SOURCE_DIR}/src/util/vfs/vfs-zip.c) set(CPACK_DEBIAN_PACKAGE_DEPENDS "${CPACK_DEBIAN_PACKAGE_DEPENDS},libminizip1") + set(CMAKE_REQUIRED_LIBRARIES ${MINIZIP_LIBRARIES}) + check_function_exists(unztell64 HAVE_UNZTELL64) + unset(CMAKE_REQUIRED_LIBRARIES) + if(NOT HAVE_UNZTELL64) + add_definitions(-Dunztell64=unzTell64) # Bug in downstream minizip that some distros use + endif() elseif(USE_ZLIB) list(APPEND VFS_SRC ${CMAKE_CURRENT_SOURCE_DIR}/src/util/vfs/vfs-zip.c ${CMAKE_CURRENT_SOURCE_DIR}/src/third-party/zlib/contrib/minizip/ioapi.c