CMakeLists.txt 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. cmake_minimum_required(VERSION 2.8.5)
  2. project(NavApp3)
  3. set(CMAKE_OSX_SYSROOT iphoneos4.3)
  4. set(CMAKE_OSX_ARCHITECTURES "armv6;armv7;i386")
  5. include_directories(
  6. ${CMAKE_CURRENT_SOURCE_DIR}
  7. ${CMAKE_CURRENT_SOURCE_DIR}/Classes
  8. )
  9. add_library(Functions STATIC TotalFunction.c TotalFunction.h)
  10. set(M_SRCS main.m Classes/NavApp3AppDelegate.m Classes/RootViewController.m)
  11. set(HEADERS Classes/NavApp3AppDelegate.h Classes/RootViewController.h)
  12. set(RESOURCES MainWindow.xib RootViewController.xib)
  13. add_executable(NavApp3 MACOSX_BUNDLE ${M_SRCS} ${HEADERS} ${RESOURCES})
  14. target_link_libraries(NavApp3
  15. Functions
  16. "-framework CoreGraphics"
  17. "-framework Foundation"
  18. "-framework UIKit"
  19. )
  20. set_target_properties(NavApp3 PROPERTIES
  21. MACOSX_BUNDLE_GUI_IDENTIFIER "com.yourcompany.NavApp3"
  22. MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist.in
  23. RESOURCE "${RESOURCES}"
  24. XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY "iPhone Developer"
  25. XCODE_ATTRIBUTE_DEBUG_INFORMATION_FORMAT "dwarf-with-dsym"
  26. XCODE_ATTRIBUTE_GCC_PRECOMPILE_PREFIX_HEADER YES
  27. XCODE_ATTRIBUTE_GCC_PREFIX_HEADER ${CMAKE_CURRENT_LIST_DIR}/NavApp3_Prefix.pch
  28. XCODE_ATTRIBUTE_INFOPLIST_PREPROCESS YES
  29. XCODE_ATTRIBUTE_IPHONEOS_DEPLOYMENT_TARGET 3.0
  30. )