-
Notifications
You must be signed in to change notification settings - Fork 203
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
compatibility issues for IDA9.0 RC1 #140
Comments
Yeah, I have an equivalent change internally. On one hand, IDA 9 makes things a lot simpler, on the other, we'd have to break build compatibility, like you said. I'm not sure which direction to go right now, TBH, as I don't have much time to spend on BinDiff/BinExport right now. |
Updated FindIdaSdk.cmake to support IDA Pro 9.0.240925 on macOS ARM64. Keep in mind that this is a temporary solution till binexport gets updated. --- FindIdaSdk.cmake 2024-11-13 15:18:48
+++ FindIdaSdk_IDA_9.0.240925.cmake 2024-11-12 11:07:42
@@ -105,29 +105,29 @@
# Not using find_library(), as static-lib search might be enforced in
# calling project.
_ida_get_libpath_suffixes(_ida64_x64_suffixes "x64_mac_clang_64")
- find_path(IdaSdk_LIBPATH64_X64 libida64.dylib
+ find_path(IdaSdk_LIBPATH64_X64 libida.dylib
PATHS "${IdaSdk_DIR}/lib" PATH_SUFFIXES ${_ida64_x64_suffixes}
NO_DEFAULT_PATH REQUIRED
)
_ida_get_libpath_suffixes(_ida64_arm64_suffixes "arm64_mac_clang_64")
- find_path(IdaSdk_LIBPATH64_ARM64 libida64.dylib
+ find_path(IdaSdk_LIBPATH64_ARM64 libida.dylib
PATHS "${IdaSdk_DIR}/lib" PATH_SUFFIXES ${_ida64_arm64_suffixes}
NO_DEFAULT_PATH REQUIRED
)
if(NOT TARGET ida64_universal)
set(_ida64_universal_lib
- "${CMAKE_CURRENT_BINARY_DIR}/libida64_universal.dylib"
+ "${CMAKE_CURRENT_BINARY_DIR}/libida_universal.dylib"
CACHE INTERNAL ""
)
# Create a new "universal" library to allow the linker to select the
# correct one per architecture. Ideally, Hex Rays would just compile
# libida64.dylib as a universal bundle.
add_custom_target(ida64_universal
- DEPENDS "${IdaSdk_LIBPATH64_ARM64}/libida64.dylib"
- "${IdaSdk_LIBPATH64_X64}/libida64.dylib"
+ DEPENDS "${IdaSdk_LIBPATH64_ARM64}/libida.dylib"
+ "${IdaSdk_LIBPATH64_X64}/libida.dylib"
BYPRODUCTS "${_ida64_universal_lib}"
- COMMAND lipo -create "${IdaSdk_LIBPATH64_ARM64}/libida64.dylib"
- "${IdaSdk_LIBPATH64_X64}/libida64.dylib"
+ COMMAND lipo -create "${IdaSdk_LIBPATH64_ARM64}/libida.dylib"
+ "${IdaSdk_LIBPATH64_X64}/libida.dylib"
-output "${_ida64_universal_lib}"
)
endif()
@@ -137,35 +137,7 @@
IMPORTED_LOCATION "${_ida64_universal_lib}"
)
- _ida_get_libpath_suffixes(_ida32_x64_suffixes "x64_mac_clang_32")
- find_path(IdaSdk_LIBPATH32_X64 libida.dylib
- PATHS "${IdaSdk_DIR}/lib" PATH_SUFFIXES ${_ida32_x64_suffixes}
- NO_DEFAULT_PATH REQUIRED
- )
- _ida_get_libpath_suffixes(_ida32_arm64_suffixes "arm64_mac_clang_32")
- find_path(IdaSdk_LIBPATH32_ARM64 libida.dylib
- PATHS "${IdaSdk_DIR}/lib" PATH_SUFFIXES ${_ida32_arm64_suffixes}
- NO_DEFAULT_PATH REQUIRED
- )
- if(NOT TARGET ida32_universal)
- set(_ida32_universal_lib
- "${CMAKE_CURRENT_BINARY_DIR}/libida32_universal.dylib"
- CACHE INTERNAL ""
- )
- add_custom_target(ida32_universal
- DEPENDS "${IdaSdk_LIBPATH32_ARM64}/libida.dylib"
- "${IdaSdk_LIBPATH32_X64}/libida.dylib"
- BYPRODUCTS "${_ida32_universal_lib}"
- COMMAND lipo -create "${IdaSdk_LIBPATH32_ARM64}/libida.dylib"
- "${IdaSdk_LIBPATH32_X64}/libida.dylib"
- -output "${_ida32_universal_lib}"
- )
- endif()
- add_library(ida32 SHARED IMPORTED)
- add_dependencies(ida32 ida32_universal)
- set_target_properties(ida32 PROPERTIES
- IMPORTED_LOCATION "${_ida32_universal_lib}"
- )
+
elseif(UNIX)
set(IdaSdk_PLATFORM __LINUX__)
@@ -179,15 +151,7 @@
IMPORTED_LOCATION "${IdaSdk_LIBPATH64}/libida64.so"
)
- _ida_get_libpath_suffixes(_ida32_suffixes "x64_linux_gcc_32")
- find_path(IdaSdk_LIBPATH32 libida.so
- PATHS "${IdaSdk_DIR}/lib" PATH_SUFFIXES ${_ida32_suffixes}
- NO_DEFAULT_PATH REQUIRED
- )
- add_library(ida32 SHARED IMPORTED)
- set_target_properties(ida32 PROPERTIES
- IMPORTED_LOCATION "${IdaSdk_LIBPATH32}/libida.so"
- )
+
elseif(WIN32)
set(IdaSdk_PLATFORM __NT__)
@@ -200,14 +164,6 @@
set_target_properties(ida64 PROPERTIES IMPORTED_LOCATION "${IdaSdk_LIB64}")
set_target_properties(ida64 PROPERTIES IMPORTED_IMPLIB "${IdaSdk_LIB64}")
- _ida_get_libpath_suffixes(_ida32_suffixes "x64_win_vc_32")
- find_library(IdaSdk_LIB32 ida
- PATHS "${IdaSdk_DIR}/lib" PATH_SUFFIXES ${_ida32_suffixes}
- NO_DEFAULT_PATH REQUIRED
- )
- add_library(ida32 SHARED IMPORTED)
- set_target_properties(ida32 PROPERTIES IMPORTED_LOCATION "${IdaSdk_LIB32}")
- set_target_properties(ida32 PROPERTIES IMPORTED_IMPLIB "${IdaSdk_LIB32}")
else()
message(FATAL_ERROR "Unsupported system type: ${CMAKE_SYSTEM_NAME}")
endif()
@@ -258,8 +214,6 @@
set_target_properties(${t} PROPERTIES PREFIX "" SUFFIX "")
if(ea64)
target_link_libraries(${t} ida64)
- else()
- target_link_libraries(${t} ida32)
endif()
if(UNIX)
if(APPLE)
@@ -298,9 +252,6 @@
cmake_parse_arguments(PARSE_ARGV 1 opt "NOEA32;NOEA64" "" "")
_ida_check_bitness(opt_NOEA32 opt_NOEA64)
- if(NOT opt_NOEA32)
- _ida_plugin(${name} FALSE plugins/exports.def ${opt_UNPARSED_ARGUMENTS})
- endif()
if(NOT opt_NOEA64)
_ida_plugin(${name} TRUE plugins/exports.def ${opt_UNPARSED_ARGUMENTS})
endif()
|
In IDA 9.0 rc1, IDA32 has been removed (No more IDA32), and rename
libida64.dylib
tolibida.dylib
(in MacOS).also IDA 9.0 sdk no longer distinguish per edition.
binexport/cmake/FindIdaSdk.cmake
Lines 94 to 100 in 624377d
Here's my temporary solution to go through compilation:
Mas0nShi@ab7aafa
NOTICE: this patches would break compatibility(IDA 8.*), so it's not the best way to solve this issue.
The text was updated successfully, but these errors were encountered: