Skip to content

Commit

Permalink
CMakeLists.txt: improve macOS handling.
Browse files Browse the repository at this point in the history
  • Loading branch information
PeterMatula committed Sep 5, 2018
1 parent ddb7438 commit a321e35
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 4 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ if(MSVC) # Windows
# std::numeric_limits<...>::max()
# (http://stackoverflow.com/questions/1904635/warning-c4003-and-errors-c2589-and-c2059-on-x-stdnumeric-limitsintmax).
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /DNOMINMAX")
else() # Linux
else() # Linux or macOS
# Common options.
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pedantic")
Expand Down Expand Up @@ -69,7 +69,9 @@ if(RETDEC_IDAPLUGIN_DOC)
set(RELEASE_LICENSE_DIR "${RELEASE_DIR}/license")
if(MSVC) # Windows
set(RELEASE_OS_NAME "windows")
else()
elseif(APPLE) # macOS
set(RELEASE_OS_NAME "macOS")
else() # Linux
set(RELEASE_OS_NAME "linux")
endif()
add_custom_target(release
Expand Down
6 changes: 2 additions & 4 deletions src/idaplugin/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,8 @@ set(FINAL_PLUGIN_NAME "retdec")
# Windows.
if(MSVC)
add_definitions(-D__NT__) #-DWIN32
if(MSVC)
set(IDASDK_LIBRARIES "${IDA_SDK_DIR}/lib/x64_win_vc_32/ida.lib")
endif()
elseif (APPLE)
set(IDASDK_LIBRARIES "${IDA_SDK_DIR}/lib/x64_win_vc_32/ida.lib")
elseif(APPLE)
ADD_DEFINITIONS (-D__MAC__)
set(IDASDK_LIBRARIES "${IDA_SDK_DIR}/lib/x64_mac_gcc_32/libida.dylib")
# Linux.
Expand Down

0 comments on commit a321e35

Please sign in to comment.