Audio plugin host https://kx.studio/carla
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

172 lines
6.0KB

  1. #!/usr/bin/make -f
  2. # Makefile for carla-discovery #
  3. # ---------------------------- #
  4. # Created by falkTX
  5. #
  6. CWD=..
  7. include ../Makefile.mk
  8. # --------------------------------------------------------------
  9. BUILD_CXX_FLAGS += -I../backend -I../includes -I../utils -isystem ../modules
  10. BUILD_CXX_FLAGS += -I../includes/ladspa -I../includes/vst -I../includes/vst3
  11. #-Wno-multichar
  12. ifeq ($(MACOS),true)
  13. BUILD_CXX_FLAGS += -ObjC++
  14. endif
  15. # --------------------------------------------------------------
  16. ifeq ($(CARLA_PLUGIN_SUPPORT),true)
  17. BUILD_CXX_FLAGS += -DWANT_LADSPA -DWANT_DSSI -DWANT_LV2 -DWANT_VST
  18. ifeq ($(MACOS),true)
  19. BUILD_CXX_FLAGS += -DWANT_AU
  20. endif
  21. ifeq ($(MACOS_OR_WIN32),true)
  22. BUILD_CXX_FLAGS += -DWANT_VST3
  23. endif
  24. ifeq ($(CARLA_VESTIGE_HEADER),true)
  25. BUILD_CXX_FLAGS += -DVESTIGE_HEADER
  26. endif
  27. endif
  28. # --------------------------------------------------------------
  29. ifeq ($(HAVE_FLUIDSYNTH),true)
  30. NATIVE_FLAGS += -DWANT_FLUIDSYNTH $(FLUIDSYNTH_FLAGS) $(FLUIDSYNTH_LIBS)
  31. endif
  32. ifeq ($(HAVE_LINUXSAMPLER),true)
  33. NATIVE_FLAGS += -DWANT_LINUXSAMPLER $(LINUXSAMPLER_FLAGS) $(LINUXSAMPLER_LIBS)
  34. endif
  35. # --------------------------------------------------------------
  36. ifeq ($(CARLA_PLUGIN_SUPPORT),true)
  37. LIBS += ../modules/lilv.a
  38. LIBS_posix32 += ../modules/lilv.posix32.a
  39. LIBS_posix64 += ../modules/lilv.posix64.a
  40. LIBS_win32 += ../modules/lilv.win32.a
  41. LIBS_win64 += ../modules/lilv.win64.a
  42. LINK_FLAGS += $(LILV_LIBS)
  43. endif
  44. LIBS += ../modules/juce_audio_basics.a
  45. LIBS_posix32 += ../modules/juce_audio_basics.posix32.a
  46. LIBS_posix64 += ../modules/juce_audio_basics.posix64.a
  47. LIBS_win32 += ../modules/juce_audio_basics.win32.a
  48. LIBS_win64 += ../modules/juce_audio_basics.win64.a
  49. LIBS += ../modules/juce_core.a
  50. LIBS_posix32 += ../modules/juce_core.posix32.a
  51. LIBS_posix64 += ../modules/juce_core.posix64.a
  52. LIBS_win32 += ../modules/juce_core.win32.a
  53. LIBS_win64 += ../modules/juce_core.win64.a
  54. LINK_FLAGS += $(JUCE_AUDIO_BASICS_LIBS)
  55. LINK_FLAGS += $(JUCE_CORE_LIBS)
  56. ifeq ($(MACOS_OR_WIN32),true)
  57. LIBS += ../modules/juce_audio_processors.a
  58. LIBS_posix32 += ../modules/juce_audio_processors.posix32.a
  59. LIBS_posix64 += ../modules/juce_audio_processors.posix64.a
  60. LIBS_win32 += ../modules/juce_audio_processors.win32.a
  61. LIBS_win64 += ../modules/juce_audio_processors.win64.a
  62. LIBS += ../modules/juce_data_structures.a
  63. LIBS_posix32 += ../modules/juce_data_structures.posix32.a
  64. LIBS_posix64 += ../modules/juce_data_structures.posix64.a
  65. LIBS_win32 += ../modules/juce_data_structures.win32.a
  66. LIBS_win64 += ../modules/juce_data_structures.win64.a
  67. LIBS += ../modules/juce_events.a
  68. LIBS_posix32 += ../modules/juce_events.posix32.a
  69. LIBS_posix64 += ../modules/juce_events.posix64.a
  70. LIBS_win32 += ../modules/juce_events.win32.a
  71. LIBS_win64 += ../modules/juce_events.win64.a
  72. LIBS += ../modules/juce_graphics.a
  73. LIBS_posix32 += ../modules/juce_graphics.posix32.a
  74. LIBS_posix64 += ../modules/juce_graphics.posix64.a
  75. LIBS_win32 += ../modules/juce_graphics.win32.a
  76. LIBS_win64 += ../modules/juce_graphics.win64.a
  77. LIBS += ../modules/juce_gui_basics.a
  78. LIBS_posix32 += ../modules/juce_gui_basics.posix32.a
  79. LIBS_posix64 += ../modules/juce_gui_basics.posix64.a
  80. LIBS_win32 += ../modules/juce_gui_basics.win32.a
  81. LIBS_win64 += ../modules/juce_gui_basics.win64.a
  82. LINK_FLAGS += $(JUCE_AUDIO_PROCESSORS_LIBS)
  83. LINK_FLAGS += $(JUCE_DATA_STRUCTURES_LIBS)
  84. LINK_FLAGS += $(JUCE_EVENTS_LIBS)
  85. LINK_FLAGS += $(JUCE_GRAPHICS_LIBS)
  86. LINK_FLAGS += $(JUCE_GUI_BASICS_LIBS)
  87. endif
  88. ifeq ($(MACOS),true)
  89. LIBS += ../modules/juce_gui_extra.a
  90. LINK_FLAGS += $(JUCE_GUI_EXTRA_LIBS)
  91. endif
  92. POSIX_BUILD_FLAGS = $(BUILD_CXX_FLAGS)
  93. POSIX_32BIT_FLAGS = $(32BIT_FLAGS) -L/usr/lib32 -L/usr/lib/i386-linux-gnu
  94. POSIX_64BIT_FLAGS = $(64BIT_FLAGS) -L/usr/lib64 -L/usr/lib/x86_64-linux-gnu
  95. POSIX_LINK_FLAGS = $(LINK_FLAGS)
  96. ifneq ($(HAIKU),true)
  97. POSIX_LINK_FLAGS += -ldl
  98. endif
  99. WIN_BUILD_FLAGS = $(BUILD_CXX_FLAGS)
  100. WIN_32BIT_FLAGS = $(32BIT_FLAGS)
  101. WIN_64BIT_FLAGS = $(64BIT_FLAGS)
  102. WIN_LINK_FLAGS = $(LINK_FLAGS) $(EXTRA_LIBS)
  103. # --------------------------------------------------------------
  104. DEPS = $(CARLA_BACKEND_UTILS_HPP)
  105. DEPS += $(CARLA_LIB_UTILS_HPP)
  106. DEPS += $(CARLA_MATH_UTILS_HPP)
  107. DEPS += $(CARLA_MIDI_H)
  108. # juce_audio_processors.h
  109. DEPS += $(CARLA_LADSPA_UTILS_HPP)
  110. DEPS += $(CARLA_DSSI_UTILS_CPP)
  111. DEPS += $(CARLA_LV2_UTILS_HPP)
  112. DEPS += $(CARLA_VST_UTILS_HPP)
  113. OBJS = carla-discovery.cpp
  114. # --------------------------------------------------------------
  115. all: ../../bin/carla-discovery-native$(APP_EXT)
  116. posix32: ../../bin/carla-discovery-posix32
  117. posix64: ../../bin/carla-discovery-posix64
  118. win32: ../../bin/carla-discovery-win32.exe
  119. win64: ../../bin/carla-discovery-win64.exe
  120. # --------------------------------------------------------------
  121. ../../bin/carla-discovery-native: $(OBJS) $(DEPS) $(LIBS)
  122. $(CXX) $(OBJS) $(LIBS_START) $(LIBS) $(LIBS_END) $(POSIX_BUILD_FLAGS) $(NATIVE_FLAGS) $(POSIX_LINK_FLAGS) -o $@
  123. ../../bin/carla-discovery-native.exe: $(OBJS) $(DEPS) $(LIBS)
  124. $(CXX) $(OBJS) $(LIBS_START) $(LIBS) $(LIBS_END) $(WIN_BUILD_FLAGS) $(NATIVE_FLAGS) $(WIN_LINK_FLAGS) -o $@
  125. ../../bin/carla-discovery-posix32: $(OBJS) $(DEPS) $(LIBS_posix32)
  126. $(CXX) $(OBJS) $(LIBS_START) $(LIBS_posix32) $(LIBS_END) $(POSIX_BUILD_FLAGS) $(POSIX_32BIT_FLAGS) $(POSIX_LINK_FLAGS) -o $@
  127. ../../bin/carla-discovery-posix64: $(OBJS) $(DEPS) $(LIBS_posix64)
  128. $(CXX) $(OBJS) $(LIBS_START) $(LIBS_posix64) $(LIBS_END) $(POSIX_BUILD_FLAGS) $(POSIX_64BIT_FLAGS) $(POSIX_LINK_FLAGS) -o $@
  129. ../../bin/carla-discovery-win32.exe: $(OBJS) $(DEPS) $(LIBS_win32)
  130. $(CXX) $(OBJS) $(LIBS_START) $(LIBS_win32) $(LIBS_END) $(WIN_BUILD_FLAGS) $(WIN_32BIT_FLAGS) $(WIN_LINK_FLAGS) -o $@
  131. ../../bin/carla-discovery-win64.exe: $(OBJS) $(DEPS) $(LIBS_win64)
  132. $(CXX) $(OBJS) $(LIBS_START) $(LIBS_win64) $(LIBS_END) $(WIN_BUILD_FLAGS) $(WIN_64BIT_FLAGS) $(WIN_LINK_FLAGS) -o $@
  133. # --------------------------------------------------------------
  134. clean:
  135. $(RM) ../../bin/carla-discovery-*
  136. debug:
  137. $(MAKE) DEBUG=true
  138. # --------------------------------------------------------------