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 7.7KB

12 years ago
12 years ago
12 years ago
12 years ago
12 years ago
12 years ago
10 years ago
10 years ago
10 years ago
12 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231
  1. #!/usr/bin/make -f
  2. # Makefile for jackbridge #
  3. # ----------------------- #
  4. # Created by falkTX
  5. #
  6. CWD=..
  7. MODULENAME=jackbridge
  8. include ../modules/Makefile.mk
  9. # ----------------------------------------------------------------------------------------------------------------------------
  10. WINECXX ?= wineg++
  11. BUILD_CXX_FLAGS += $(JACKBRIDGE_FLAGS)
  12. LINK_FLAGS += $(JACKBRIDGE_LIBS)
  13. WINE_32BIT_FLAGS = $(32BIT_FLAGS)
  14. WINE_64BIT_FLAGS = $(64BIT_FLAGS)
  15. WINE_LINK_FLAGS = $(LINK_FLAGS) $(LIBDL_LIBS) -lpthread
  16. ifneq ($(MACOS),true)
  17. WINE_32BIT_FLAGS += -I/usr/include/wine/wine/windows
  18. WINE_32BIT_FLAGS += -L/usr/lib32/wine
  19. WINE_32BIT_FLAGS += -L/usr/lib/i386-linux-gnu/wine
  20. WINE_32BIT_FLAGS += -L/usr/lib/i386-linux-gnu/wine-development
  21. WINE_32BIT_FLAGS += -L/opt/wine-staging/lib
  22. WINE_32BIT_FLAGS += -L/opt/wine-staging/lib/wine
  23. WINE_64BIT_FLAGS += -I/usr/include/wine/wine/windows
  24. WINE_64BIT_FLAGS += -L/usr/lib64/wine
  25. WINE_64BIT_FLAGS += -L/usr/lib/x86_64-linux-gnu/wine
  26. WINE_64BIT_FLAGS += -L/usr/lib/x86_64-linux-gnu/wine-development
  27. WINE_64BIT_FLAGS += -L/opt/wine-staging/lib64
  28. WINE_64BIT_FLAGS += -L/opt/wine-staging/lib64/wine
  29. WINE_LINK_FLAGS += -lrt
  30. endif
  31. # ----------------------------------------------------------------------------------------------------------------------------
  32. OBJS = $(OBJDIR)/JackBridge1.cpp.o $(OBJDIR)/JackBridge2.cpp.o
  33. OBJS_posix32 = $(OBJDIR)/JackBridge1.cpp.posix32.o $(OBJDIR)/JackBridge2.cpp.posix32.o
  34. OBJS_posix64 = $(OBJDIR)/JackBridge1.cpp.posix64.o $(OBJDIR)/JackBridge2.cpp.posix64.o
  35. OBJS_win32 = $(OBJDIR)/JackBridge1.cpp.win32.o $(OBJDIR)/JackBridge2.cpp.win32.o
  36. OBJS_win64 = $(OBJDIR)/JackBridge1.cpp.win64.o $(OBJDIR)/JackBridge2.cpp.win64.o
  37. OBJS_wine32 = $(OBJDIR)/JackBridge1.cpp.wine32.o $(OBJDIR)/JackBridge2.cpp.wine32.o $(OBJDIR)/JackBridge3.cpp.wine32.o
  38. OBJS_wine64 = $(OBJDIR)/JackBridge1.cpp.wine64.o $(OBJDIR)/JackBridge2.cpp.wine64.o $(OBJDIR)/JackBridge3.cpp.wine64.o
  39. OBJS_posix32e = $(OBJDIR)/JackBridgeExport.cpp.posix32e.o
  40. OBJS_posix64e = $(OBJDIR)/JackBridgeExport.cpp.posix64e.o
  41. OBJS_win64e = $(OBJDIR)/JackBridgeExport.cpp.win64e.o
  42. OBJS_win32e = $(OBJDIR)/JackBridgeExport.cpp.win32e.o
  43. # ----------------------------------------------------------------------------------------------------------------------------
  44. all: $(MODULEDIR)/$(MODULENAME).a
  45. ifeq ($(WIN32),true)
  46. posix32:
  47. posix64:
  48. posix32e:
  49. posix64e:
  50. win32: $(MODULEDIR)/$(MODULENAME).win32.a
  51. win64: $(MODULEDIR)/$(MODULENAME).win64.a
  52. win32e: $(MODULEDIR)/$(MODULENAME).win32e.a
  53. win64e: $(MODULEDIR)/$(MODULENAME).win64e.a
  54. wine32:
  55. wine64:
  56. else
  57. posix32: $(MODULEDIR)/$(MODULENAME).posix32.a
  58. posix64: $(MODULEDIR)/$(MODULENAME).posix64.a
  59. posix32e: $(MODULEDIR)/$(MODULENAME).posix32e.a
  60. posix64e: $(MODULEDIR)/$(MODULENAME).posix64e.a
  61. win32:
  62. win64:
  63. win32e:
  64. win64e:
  65. wine32: $(MODULEDIR)/$(MODULENAME)-wine32.dll$(LIB_EXT)
  66. wine64: $(MODULEDIR)/$(MODULENAME)-wine64.dll$(LIB_EXT)
  67. endif
  68. # ----------------------------------------------------------------------------------------------------------------------------
  69. clean:
  70. rm -f $(OBJDIR)/*.o $(MODULEDIR)/$(MODULENAME)*.*
  71. debug:
  72. $(MAKE) DEBUG=true
  73. # ----------------------------------------------------------------------------------------------------------------------------
  74. $(MODULEDIR)/$(MODULENAME).a: $(OBJS)
  75. -@mkdir -p $(MODULEDIR)
  76. @echo "Creating $(MODULENAME).a"
  77. @rm -f $@
  78. @$(AR) crs $@ $^
  79. $(MODULEDIR)/$(MODULENAME).posix32.a: $(OBJS_posix32)
  80. -@mkdir -p $(MODULEDIR)
  81. @echo "Creating $(MODULENAME).posix32.a"
  82. @rm -f $@
  83. @$(AR) crs $@ $^
  84. $(MODULEDIR)/$(MODULENAME).posix64.a: $(OBJS_posix64)
  85. -@mkdir -p $(MODULEDIR)
  86. @echo "Creating $(MODULENAME).posix64.a"
  87. @rm -f $@
  88. @$(AR) crs $@ $^
  89. $(MODULEDIR)/$(MODULENAME).win32.a: $(OBJS_win32)
  90. -@mkdir -p $(MODULEDIR)
  91. @echo "Creating $(MODULENAME).win32.a"
  92. @rm -f $@
  93. @$(AR) crs $@ $^
  94. $(MODULEDIR)/$(MODULENAME).win64.a: $(OBJS_win64)
  95. -@mkdir -p $(MODULEDIR)
  96. @echo "Creating $(MODULENAME).win64.a"
  97. @rm -f $@
  98. @$(AR) crs $@ $^
  99. # ----------------------------------------------------------------------------------------------------------------------------
  100. $(MODULEDIR)/$(MODULENAME).posix32e.a: $(OBJS_posix32e)
  101. -@mkdir -p $(MODULEDIR)
  102. @echo "Creating $(MODULENAME).posix32e.a"
  103. @rm -f $@
  104. @$(AR) crs $@ $^
  105. $(MODULEDIR)/$(MODULENAME).posix64e.a: $(OBJS_posix64e)
  106. -@mkdir -p $(MODULEDIR)
  107. @echo "Creating $(MODULENAME).posix64e.a"
  108. @rm -f $@
  109. @$(AR) crs $@ $^
  110. $(MODULEDIR)/$(MODULENAME).win32e.a: $(OBJS_win32e)
  111. -@mkdir -p $(MODULEDIR)
  112. @echo "Creating $(MODULENAME).win32e.a"
  113. @rm -f $@
  114. @$(AR) crs $@ $^
  115. $(MODULEDIR)/$(MODULENAME).win64e.a: $(OBJS_win64e)
  116. -@mkdir -p $(MODULEDIR)
  117. @echo "Creating $(MODULENAME).win64e.a"
  118. @rm -f $@
  119. @$(AR) crs $@ $^
  120. # ----------------------------------------------------------------------------------------------------------------------------
  121. $(MODULEDIR)/$(MODULENAME)-wine32.dll$(LIB_EXT): $(OBJS_wine32) JackBridgeExport.def
  122. -@mkdir -p $(MODULEDIR)
  123. @echo "Linking $(MODULENAME)-wine32.dll$(LIB_EXT)"
  124. @$(WINECXX) $^ $(WINE_32BIT_FLAGS) $(WINE_LINK_FLAGS) $(SHARED) -o $@
  125. $(MODULEDIR)/$(MODULENAME)-wine64.dll$(LIB_EXT): $(OBJS_wine64) JackBridgeExport.def
  126. -@mkdir -p $(MODULEDIR)
  127. @echo "Linking $(MODULENAME)-wine64.dll$(LIB_EXT)"
  128. @$(WINECXX) $^ $(WINE_64BIT_FLAGS) $(WINE_LINK_FLAGS) $(SHARED) -o $@
  129. # ----------------------------------------------------------------------------------------------------------------------------
  130. $(OBJDIR)/JackBridge1.cpp.o: JackBridge1.cpp
  131. -@mkdir -p $(OBJDIR)
  132. @echo "Compiling JackBridge1.cpp"
  133. @$(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@
  134. $(OBJDIR)/JackBridge2.cpp.o: JackBridge2.cpp
  135. -@mkdir -p $(OBJDIR)
  136. @echo "Compiling JackBridge2.cpp"
  137. @$(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@
  138. # ----------------------------------------------------------------------------------------------------------------------------
  139. $(OBJDIR)/JackBridgeExport.cpp.%32e.o: JackBridgeExport.cpp
  140. -@mkdir -p $(OBJDIR)
  141. @echo "Compiling $<"
  142. @$(CXX) $< $(BUILD_CXX_FLAGS) $(32BIT_FLAGS) -fpermissive -c -o $@
  143. $(OBJDIR)/JackBridgeExport.cpp.%64e.o: JackBridgeExport.cpp
  144. -@mkdir -p $(OBJDIR)
  145. @echo "Compiling $<"
  146. @$(CXX) $< $(BUILD_CXX_FLAGS) $(64BIT_FLAGS) -fpermissive -c -o $@
  147. # ----------------------------------------------------------------------------------------------------------------------------
  148. $(OBJDIR)/%.cpp.posix32.o: %.cpp
  149. -@mkdir -p $(OBJDIR)
  150. @echo "Compiling $< (posix32)"
  151. @$(CXX) $< $(BUILD_CXX_FLAGS) $(32BIT_FLAGS) -c -o $@
  152. $(OBJDIR)/%.cpp.posix64.o: %.cpp
  153. -@mkdir -p $(OBJDIR)
  154. @echo "Compiling $< (posix64)"
  155. @$(CXX) $< $(BUILD_CXX_FLAGS) $(64BIT_FLAGS) -c -o $@
  156. $(OBJDIR)/%.cpp.win32.o: %.cpp
  157. -@mkdir -p $(OBJDIR)
  158. @echo "Compiling $< (win32)"
  159. @$(CXX) $< $(BUILD_CXX_FLAGS) $(32BIT_FLAGS) -c -o $@
  160. $(OBJDIR)/%.cpp.win64.o: %.cpp
  161. -@mkdir -p $(OBJDIR)
  162. @echo "Compiling $< (win64)"
  163. @$(CXX) $< $(BUILD_CXX_FLAGS) $(64BIT_FLAGS) -c -o $@
  164. $(OBJDIR)/%.cpp.wine32.o: %.cpp
  165. -@mkdir -p $(OBJDIR)
  166. @echo "Compiling $< (wine32)"
  167. @$(WINECXX) $< $(BUILD_CXX_FLAGS) $(32BIT_FLAGS) -c -o $@
  168. $(OBJDIR)/%.cpp.wine64.o: %.cpp
  169. -@mkdir -p $(OBJDIR)
  170. @echo "Compiling $< (wine64)"
  171. @$(WINECXX) $< $(BUILD_CXX_FLAGS) $(64BIT_FLAGS) -c -o $@
  172. # ----------------------------------------------------------------------------------------------------------------------------
  173. -include $(OBJS:%.o=%.d)
  174. -include $(OBJS_posix32:%.o=%.d)
  175. -include $(OBJS_posix32e:%.o=%.d)
  176. -include $(OBJS_posix64:%.o=%.d)
  177. -include $(OBJS_posix64e:%.o=%.d)
  178. -include $(OBJS_win32:%.o=%.d)
  179. -include $(OBJS_win32e:%.o=%.d)
  180. -include $(OBJS_win64:%.o=%.d)
  181. -include $(OBJS_win64e:%.o=%.d)
  182. -include $(OBJS_wine32:%.o=%.d)
  183. -include $(OBJS_wine64:%.o=%.d)
  184. # ----------------------------------------------------------------------------------------------------------------------------