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.

Makefile 4.2KB

10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  1. #!/usr/bin/make -f
  2. # Makefile for juce_audio_processors #
  3. # ---------------------------------- #
  4. # Created by falkTX
  5. #
  6. CWD=../..
  7. MODULENAME=juce_audio_processors
  8. include ../Makefile.mk
  9. # ----------------------------------------------------------------------------------------------------------------------------
  10. BUILD_CXX_FLAGS += $(JUCE_AUDIO_PROCESSORS_FLAGS) -I$(CWD)/includes/ladspa -I$(CWD)/includes/vst2 -I$(CWD)/includes/vst3 -w
  11. ifeq ($(CARLA_VESTIGE_HEADER),true)
  12. BUILD_CXX_FLAGS += -DVESTIGE_HEADER
  13. else
  14. # needed by vst3
  15. ifeq ($(DEBUG),true)
  16. BUILD_CXX_FLAGS += -DDEVELOPMENT -D_DEBUG
  17. else
  18. BUILD_CXX_FLAGS += -DRELEASE
  19. endif
  20. # needed by vst3 on mingw
  21. ifeq ($(WIN32),true)
  22. BUILD_CXX_FLAGS += -D_NATIVE_WCHAR_T_DEFINED -D__wchar_t=wchar_t -fpermissive
  23. endif
  24. endif
  25. # ----------------------------------------------------------------------------------------------------------------------------
  26. ifeq ($(MACOS),true)
  27. OBJS = $(OBJDIR)/$(MODULENAME).mm.o
  28. OBJS_posix32 = $(OBJDIR)/$(MODULENAME).mm.posix32.o
  29. OBJS_posix64 = $(OBJDIR)/$(MODULENAME).mm.posix64.o
  30. else
  31. OBJS = $(OBJDIR)/$(MODULENAME).cpp.o
  32. OBJS_posix32 = $(OBJDIR)/$(MODULENAME).cpp.posix32.o
  33. OBJS_posix64 = $(OBJDIR)/$(MODULENAME).cpp.posix64.o
  34. endif
  35. OBJS_win32 = $(OBJDIR)/$(MODULENAME).cpp.win32.o
  36. OBJS_win64 = $(OBJDIR)/$(MODULENAME).cpp.win64.o
  37. # ----------------------------------------------------------------------------------------------------------------------------
  38. all: $(MODULEDIR)/$(MODULENAME).a
  39. posix32: $(MODULEDIR)/$(MODULENAME).posix32.a
  40. posix64: $(MODULEDIR)/$(MODULENAME).posix64.a
  41. win32: $(MODULEDIR)/$(MODULENAME).win32.a
  42. win64: $(MODULEDIR)/$(MODULENAME).win64.a
  43. # ----------------------------------------------------------------------------------------------------------------------------
  44. clean:
  45. rm -f $(OBJDIR)/*.o $(MODULEDIR)/$(MODULENAME)*.a
  46. debug:
  47. $(MAKE) DEBUG=true
  48. # ----------------------------------------------------------------------------------------------------------------------------
  49. $(MODULEDIR)/$(MODULENAME).a: $(OBJS)
  50. -@mkdir -p $(MODULEDIR)
  51. @echo "Creating $(MODULENAME).a"
  52. @rm -f $@
  53. @$(AR) crs $@ $^
  54. $(MODULEDIR)/$(MODULENAME).posix32.a: $(OBJS_posix32)
  55. -@mkdir -p $(MODULEDIR)
  56. @echo "Creating $(MODULENAME).posix32.a"
  57. @rm -f $@
  58. @$(AR) crs $@ $^
  59. $(MODULEDIR)/$(MODULENAME).posix64.a: $(OBJS_posix64)
  60. -@mkdir -p $(MODULEDIR)
  61. @echo "Creating $(MODULENAME).posix64.a"
  62. @rm -f $@
  63. @$(AR) crs $@ $^
  64. $(MODULEDIR)/$(MODULENAME).win32.a: $(OBJS_win32)
  65. -@mkdir -p $(MODULEDIR)
  66. @echo "Creating $(MODULENAME).win32.a"
  67. @rm -f $@
  68. @$(AR) crs $@ $^
  69. $(MODULEDIR)/$(MODULENAME).win64.a: $(OBJS_win64)
  70. -@mkdir -p $(MODULEDIR)
  71. @echo "Creating $(MODULENAME).win64.a"
  72. @rm -f $@
  73. @$(AR) crs $@ $^
  74. # ----------------------------------------------------------------------------------------------------------------------------
  75. $(OBJDIR)/$(MODULENAME).cpp.o: $(MODULENAME).cpp
  76. -@mkdir -p $(OBJDIR)
  77. @echo "Compiling $<"
  78. @$(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@
  79. $(OBJDIR)/$(MODULENAME).cpp.%32.o: $(MODULENAME).cpp
  80. -@mkdir -p $(OBJDIR)
  81. @echo "Compiling $< (32bit)"
  82. @$(CXX) $< $(BUILD_CXX_FLAGS) $(32BIT_FLAGS) -c -o $@
  83. $(OBJDIR)/$(MODULENAME).cpp.%64.o: $(MODULENAME).cpp
  84. -@mkdir -p $(OBJDIR)
  85. @echo "Compiling $< (64bit)"
  86. @$(CXX) $< $(BUILD_CXX_FLAGS) $(64BIT_FLAGS) -c -o $@
  87. # ----------------------------------------------------------------------------------------------------------------------------
  88. $(OBJDIR)/$(MODULENAME).mm.o: $(MODULENAME).cpp
  89. -@mkdir -p $(OBJDIR)
  90. @echo "Compiling $<"
  91. @$(CXX) $< $(BUILD_CXX_FLAGS) -ObjC++ -c -o $@
  92. $(OBJDIR)/$(MODULENAME).mm.%32.o: $(MODULENAME).cpp
  93. -@mkdir -p $(OBJDIR)
  94. @echo "Compiling $< (32bit)"
  95. @$(CXX) $< $(BUILD_CXX_FLAGS) $(32BIT_FLAGS) -ObjC++ -c -o $@
  96. $(OBJDIR)/$(MODULENAME).mm.%64.o: $(MODULENAME).cpp
  97. -@mkdir -p $(OBJDIR)
  98. @echo "Compiling $< (64bit)"
  99. @$(CXX) $< $(BUILD_CXX_FLAGS) $(64BIT_FLAGS) -ObjC++ -c -o $@
  100. # ----------------------------------------------------------------------------------------------------------------------------
  101. -include $(OBJS:%.o=%.d)
  102. -include $(OBJS_posix32:%.o=%.d)
  103. -include $(OBJS_posix64:%.o=%.d)
  104. -include $(OBJS_win32:%.o=%.d)
  105. -include $(OBJS_win64:%.o=%.d)
  106. # ----------------------------------------------------------------------------------------------------------------------------