fixed creation of SFML.framework

This commit is contained in:
Marco Antognini 2011-09-09 15:24:09 +02:00
parent c942e576c1
commit d6c1fda5bd
2 changed files with 7 additions and 1 deletions

View File

@ -174,6 +174,12 @@ else()
POST_BUILD POST_BUILD
COMMAND cp -r ${PROJECT_SOURCE_DIR}/include/SFML/* SFML.framework/Versions/2.0.0/Headers) COMMAND cp -r ${PROJECT_SOURCE_DIR}/include/SFML/* SFML.framework/Versions/2.0.0/Headers)
# adapt install directory to allow distributing dylibs/frameworks in users frameworks/application bundle
# NOTE : it's not required to link agains SFML.framework
set_target_properties(SFML PROPERTIES
BUILD_WITH_INSTALL_RPATH 1
INSTALL_NAME_DIR "@executable_path/../Frameworks")
# install rule # install rule
install(TARGETS SFML install(TARGETS SFML
FRAMEWORK DESTINATION ${CMAKE_INSTALL_FRAMEWORK_PREFIX} FRAMEWORK DESTINATION ${CMAKE_INSTALL_FRAMEWORK_PREFIX}

View File

@ -150,7 +150,7 @@ macro(sfml_add_library target)
MACOSX_FRAMEWORK_BUNDLE_VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}) MACOSX_FRAMEWORK_BUNDLE_VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH})
endif() endif()
# adapt install directory to allow distributing dylibs/frameworks in users frameworks # adapt install directory to allow distributing dylibs/frameworks in users frameworks/application bundle
set_target_properties(${target} PROPERTIES set_target_properties(${target} PROPERTIES
BUILD_WITH_INSTALL_RPATH 1 BUILD_WITH_INSTALL_RPATH 1
INSTALL_NAME_DIR "@executable_path/../Frameworks") INSTALL_NAME_DIR "@executable_path/../Frameworks")