zynaddsubfx

ZynAddSubFX open source synthesizer
Log | Files | Refs | Submodules | LICENSE

CMakeLists.txt (2078B)


      1 
      2 include_directories(${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_SOURCE_DIR}/DPF/distrho .)
      3 
      4 add_library(ZynReverb_lv2 SHARED ${CMAKE_SOURCE_DIR}/DPF/distrho/DistrhoPluginMain.cpp Reverb.cpp)
      5 add_library(ZynReverb_vst SHARED ${CMAKE_SOURCE_DIR}/DPF/distrho/DistrhoPluginMain.cpp Reverb.cpp)
      6 
      7 set_target_properties(ZynReverb_lv2 PROPERTIES COMPILE_DEFINITIONS "DISTRHO_PLUGIN_TARGET_LV2")
      8 set_target_properties(ZynReverb_lv2 PROPERTIES LIBRARY_OUTPUT_DIRECTORY "lv2")
      9 set_target_properties(ZynReverb_lv2 PROPERTIES RUNTIME_OUTPUT_DIRECTORY "lv2")
     10 set_target_properties(ZynReverb_lv2 PROPERTIES OUTPUT_NAME "ZynReverb")
     11 set_target_properties(ZynReverb_lv2 PROPERTIES PREFIX "")
     12 
     13 set_target_properties(ZynReverb_vst PROPERTIES COMPILE_DEFINITIONS "DISTRHO_PLUGIN_TARGET_VST2")
     14 set_target_properties(ZynReverb_vst PROPERTIES LIBRARY_OUTPUT_DIRECTORY "vst")
     15 set_target_properties(ZynReverb_vst PROPERTIES RUNTIME_OUTPUT_DIRECTORY "vst")
     16 set_target_properties(ZynReverb_vst PROPERTIES OUTPUT_NAME "ZynReverb")
     17 set_target_properties(ZynReverb_vst PROPERTIES PREFIX "")
     18 
     19 if(APPLE)
     20     target_link_libraries(ZynReverb_lv2 zynaddsubfx_core ${OS_LIBRARIES} "-Wl,-exported_symbol,_lv2_descriptor" "-Wl,-exported_symbol,_lv2_generate_ttl")
     21     target_link_libraries(ZynReverb_vst zynaddsubfx_core ${OS_LIBRARIES} "-Wl,-exported_symbol,_VSTPluginMain")
     22 else()
     23     target_link_libraries(ZynReverb_lv2 zynaddsubfx_core ${OS_LIBRARIES})
     24     target_link_libraries(ZynReverb_vst zynaddsubfx_core ${OS_LIBRARIES})
     25 endif()
     26 
     27 install(TARGETS ZynReverb_lv2 LIBRARY DESTINATION ${PluginLibDir}/lv2/ZynReverb.lv2/)
     28 install(TARGETS ZynReverb_vst LIBRARY DESTINATION ${PluginLibDir}/vst/)
     29 
     30 add_custom_command(TARGET ZynReverb_lv2 POST_BUILD
     31     COMMAND ../../lv2-ttl-generator $<TARGET_FILE:ZynReverb_lv2>
     32 	WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/lv2)
     33 
     34 add_dependencies(ZynReverb_lv2 lv2-ttl-generator)
     35 
     36 install(FILES
     37 	${CMAKE_CURRENT_BINARY_DIR}/lv2/manifest.ttl
     38 	${CMAKE_CURRENT_BINARY_DIR}/lv2/presets.ttl
     39 	${CMAKE_CURRENT_BINARY_DIR}/lv2/ZynReverb.ttl
     40     DESTINATION ${PluginLibDir}/lv2/ZynReverb.lv2/)