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.

162 lines
5.7KB

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