CMakeLists.txt 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. project(mac-syphon)
  2. find_library(COCOA Cocoa)
  3. find_library(IOSURF IOSurface)
  4. find_library(SCRIPTINGBRIDGE ScriptingBridge)
  5. find_package(OpenGL REQUIRED)
  6. include_directories(${COCOA}
  7. ${IOSURF}
  8. ${SCRIPTINGBIRDGE}
  9. ${OPENGL_INCLUDE_DIR})
  10. set(syphon_HEADERS
  11. syphon-framework/Syphon_Prefix.pch
  12. syphon-framework/Syphon.h
  13. syphon-framework/SyphonBuildMacros.h
  14. syphon-framework/SyphonCFMessageReceiver.h
  15. syphon-framework/SyphonCFMessageSender.h
  16. syphon-framework/SyphonClient.h
  17. syphon-framework/SyphonClientConnectionManager.h
  18. syphon-framework/SyphonDispatch.h
  19. syphon-framework/SyphonIOSurfaceImage.h
  20. syphon-framework/SyphonImage.h
  21. syphon-framework/SyphonMachMessageReceiver.h
  22. syphon-framework/SyphonMachMessageSender.h
  23. syphon-framework/SyphonMessageQueue.h
  24. syphon-framework/SyphonMessageReceiver.h
  25. syphon-framework/SyphonMessageSender.h
  26. syphon-framework/SyphonMessaging.h
  27. syphon-framework/SyphonOpenGLFunctions.h
  28. syphon-framework/SyphonPrivate.h
  29. syphon-framework/SyphonServer.h
  30. syphon-framework/SyphonServerConnectionManager.h
  31. syphon-framework/SyphonServerDirectory.h
  32. )
  33. set(syphon_SOURCES
  34. syphon-framework/SyphonCFMessageReceiver.m
  35. syphon-framework/SyphonCFMessageSender.m
  36. syphon-framework/SyphonClient.m
  37. syphon-framework/SyphonClientConnectionManager.m
  38. syphon-framework/SyphonDispatch.c
  39. syphon-framework/SyphonImage.m
  40. syphon-framework/SyphonIOSurfaceImage.m
  41. syphon-framework/SyphonMachMessageReceiver.m
  42. syphon-framework/SyphonMachMessageSender.m
  43. syphon-framework/SyphonMessageQueue.m
  44. syphon-framework/SyphonMessageReceiver.m
  45. syphon-framework/SyphonMessageSender.m
  46. syphon-framework/SyphonMessaging.m
  47. syphon-framework/SyphonOpenGLFunctions.c
  48. syphon-framework/SyphonPrivate.m
  49. syphon-framework/SyphonServer.m
  50. syphon-framework/SyphonServerConnectionManager.m
  51. syphon-framework/SyphonServerDirectory.m
  52. )
  53. add_library(syphon-framework ${syphon_HEADERS}
  54. ${syphon_SOURCES})
  55. set(mac-syphon_HEADERS
  56. )
  57. set(mac-syphon_SOURCES
  58. syphon.m
  59. plugin-main.c)
  60. add_definitions(-DSYPHON_UNIQUE_CLASS_NAME_PREFIX=OBS_ -include
  61. ${PROJECT_SOURCE_DIR}/syphon-framework/Syphon_Prefix.pch)
  62. add_library(mac-syphon MODULE
  63. ${mac-syphon_SOURCES}
  64. ${mac-syphon_HEADERS})
  65. target_link_libraries(mac-syphon
  66. libobs
  67. syphon-framework
  68. ${COCOA}
  69. ${IOSURF}
  70. ${SCRIPTINGBRIDGE}
  71. ${OPENGL_gl_LIBRARY})
  72. set_property (TARGET mac-syphon APPEND_STRING PROPERTY
  73. COMPILE_FLAGS "-fobjc-arc")
  74. set_target_properties(mac-syphon PROPERTIES FOLDER "plugins")
  75. install_obs_plugin_with_data(mac-syphon data)