1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-11-24 08:32:34 +02:00

some OS X fixes

This commit is contained in:
stopiccot 2013-10-07 01:19:02 +00:00
parent aa7ab847c7
commit cbc8cde10a
4 changed files with 10 additions and 3 deletions

View File

@ -47,6 +47,9 @@ if (APPLE)
# On OS X we use Sparkle framework for updates
find_path(SPARKLE_INCLUDE_DIR Sparkle.h)
find_library(SPARKLE_FRAMEWORK NAMES Sparkle)
# Xcode 5.0 fix
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ftemplate-depth=256")
endif()
find_package(Boost 1.46.0 COMPONENTS program_options filesystem system thread REQUIRED)

View File

@ -57,7 +57,7 @@ elseif(APPLE)
target_link_libraries(vcmiclient ${SPARKLE_FRAMEWORK})
# Because server and AI libs would be copies to bundle they need to be built before client
add_dependencies(vcmiclient vcmiserver VCAI EmptyAI StupidAI BattleAI)
add_dependencies(vcmiclient vcmiserver VCAI EmptyAI StupidAI BattleAI minizip)
# Custom Info.plist
set_target_properties(vcmiclient PROPERTIES MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist)
@ -73,6 +73,7 @@ elseif(APPLE)
mkdir -p ${BUNDLE_PATH}/MacOS/AI &&
cp ${CMAKE_HOME_DIRECTORY}/bin/$(CONFIGURATION)/vcmiserver ${BUNDLE_PATH}/MacOS/vcmiserver &&
cp ${CMAKE_HOME_DIRECTORY}/bin/$(CONFIGURATION)/libvcmi.dylib ${BUNDLE_PATH}/MacOS/libvcmi.dylib &&
cp ${CMAKE_HOME_DIRECTORY}/bin/$(CONFIGURATION)/libminizip.dylib ${BUNDLE_PATH}/MacOS/libminizip.dylib &&
cp ${CMAKE_HOME_DIRECTORY}/bin/$(CONFIGURATION)/libVCAI.dylib ${BUNDLE_PATH}/MacOS/AI/libVCAI.dylib &&
cp ${CMAKE_HOME_DIRECTORY}/bin/$(CONFIGURATION)/libStupidAI.dylib ${BUNDLE_PATH}/MacOS/AI/libStupidAI.dylib &&
cp ${CMAKE_HOME_DIRECTORY}/bin/$(CONFIGURATION)/libEmptyAI.dylib ${BUNDLE_PATH}/MacOS/AI/libEmptyAI.dylib &&

View File

@ -2,7 +2,7 @@ project(vcmilauncher)
cmake_minimum_required(VERSION 2.8.7)
include_directories(${CMAKE_HOME_DIRECTORY} ${CMAKE_CURRENT_SOURCE_DIR})
include_directories(${Qt5Widgets_INCLUDE_DIRS} ${Qt5Network_INCLUDE_DIRS})
include_directories(${Boost_INCLUDE_DIRS} ${Qt5Widgets_INCLUDE_DIRS} ${Qt5Network_INCLUDE_DIRS})
set(launcher_modmanager_SRCS
modManager/cdownloadmanager_moc.cpp

View File

@ -12,6 +12,9 @@ set(lib_SRCS
)
add_library(minizip SHARED ${lib_SRCS})
set_target_properties(minizip PROPERTIES XCODE_ATTRIBUTE_LD_DYLIB_INSTALL_NAME "@executable_path/libminizip.dylib")
target_link_libraries(minizip ${ZLIB_LIBRARIES})
install(TARGETS minizip DESTINATION ${LIB_DIR})
if (NOT APPLE) # Already inside vcmiclient bundle
install(TARGETS minizip DESTINATION ${LIB_DIR})
endif()