Browse Source

Allow building with Qt6

Signed-off-by: falktx@falktx.com <falkTX>
pull/1555/merge
falktx@falktx.com 3 months ago
parent
commit
104839fbd3
Signed by: falkTX <falktx@falktx.com> GPG Key ID: CDBAA37ABC74FBA0
3 changed files with 138 additions and 143 deletions
  1. +88
    -34
      source/Makefile.deps.mk
  2. +13
    -26
      source/frontend/Makefile
  3. +37
    -83
      source/theme/Makefile

+ 88
- 34
source/Makefile.deps.mk View File

@@ -261,31 +261,59 @@ endif
endif

# ---------------------------------------------------------------------------------------------------------------------
# Set Qt tools
# Set Qt tools, part1

ifeq ($(HAVE_QT4),true)
MOC_QT4 ?= $(shell $(PKG_CONFIG) --variable=moc_location QtCore)
RCC_QT4 ?= $(shell $(PKG_CONFIG) --variable=rcc_location QtCore)
ifeq (,$(wildcard $(MOC_QT4)))
HAVE_QT4 = false
endif
ifeq (,$(wildcard $(RCC_QT4)))
HAVE_QT4 = false
endif
QT4_CXX_FLAGS = $(BUILD_CXX_FLAGS) $(shell pkg-config --cflags QtCore QtGui)
QT4_LINK_FLAGS = $(NON_STATIC_LINK_FLAGS) $(shell pkg-config --libs QtCore QtGui)
QT4_STYLES_DIR = $(shell pkg-config --variable=libdir QtCore)/qt4/plugins/styles
endif

ifeq ($(HAVE_QT5),true)
QT5_HOSTBINS = $(shell $(PKG_CONFIG) --variable=host_bins Qt5Core)
QT5_HOSTBINS = $(shell $(PKG_CONFIG) --variable=host_bins Qt5Core)
QT5_PREFIX = $(shell $(PKG_CONFIG) --variable=prefix Qt5Core)
QT5_CXX_FLAGS = $(shell $(PKG_CONFIG) --cflags Qt5Core Qt5Gui Qt5Widgets)
QT5_LINK_FLAGS = -Wl,-rpath,$(QT5_PREFIX)/lib $(shell $(PKG_CONFIG) --libs Qt5Core Qt5Gui Qt5Widgets)
QT5_STYLES_DIR = $(shell pkg-config --variable=libdir Qt5Core)/qt5/plugins/styles
else ifeq ($(HAVE_QT5PKG),true)
QT5_HOSTBINS = $(shell $(PKG_CONFIG) --variable=prefix Qt5OpenGLExtensions)/bin
QT5_HOSTBINS = $(shell $(PKG_CONFIG) --variable=prefix Qt5OpenGLExtensions)/bin
QT5_PREFIX = $(shell $(PKG_CONFIG) --variable=prefix Qt5OpenGLExtensions)
QT5_CXX_FLAGS = -DQT_CORE_LIB -DQT_GUI_LIB -DQT_WIDGETS_LIB -I $(QT5_PREFIX)/include/qt5
QT5_LINK_FLAGS = -Wl,-rpath,$(QT5_PREFIX)/lib -F $(QT5_PREFIX)/lib -framework QtCore -framework QtGui -framework QtWidgets
QT5_STYLES_DIR = $(QT5_PREFIX)/lib/qt5/plugins/styles
else ifeq ($(HAVE_QT5BREW),true)
QT5_HOSTBINS = /usr/local/opt/qt5/bin
QT5_HOSTBINS = /usr/local/opt/qt5/bin
QT5_PREFIX = /usr/local/opt/qt5
QT5_CXX_FLAGS = -DQT_CORE_LIB -DQT_GUI_LIB -DQT_WIDGETS_LIB -I $(QT5_PREFIX)/include
QT5_LINK_FLAGS = -Wl,-rpath,$(QT5_PREFIX)/lib -F $(QT5_PREFIX)/lib -framework QtCore -framework QtGui -framework QtWidgets
QT5_STYLES_DIR = $(QT5_PREFIX)/plugins/styles
endif

ifeq ($(HAVE_QT6),true)
QT6_HOSTBINS = $(shell $(PKG_CONFIG) --variable=libexecdir Qt6Core)
QT6_PREFIX = $(shell $(PKG_CONFIG) --variable=prefix Qt6Core)
QT6_CXX_FLAGS = $(shell $(PKG_CONFIG) --cflags Qt6Core Qt6Gui Qt6Widgets) -std=gnu++17
QT6_LINK_FLAGS = -Wl,-rpath,$(QT6_PREFIX)/lib $(shell $(PKG_CONFIG) --libs Qt6Core Qt6Gui Qt6Widgets)
QT6_STYLES_DIR = $(shell pkg-config --variable=libdir Qt6Core)/qt6/plugins/styles
endif

MOC_QT5 ?= $(QT5_HOSTBINS)/moc
RCC_QT5 ?= $(QT5_HOSTBINS)/rcc
UIC_QT5 ?= $(QT5_HOSTBINS)/uic

MOC_QT6 ?= $(QT6_HOSTBINS)/moc
RCC_QT6 ?= $(QT6_HOSTBINS)/rcc
UIC_QT6 ?= $(QT6_HOSTBINS)/uic

ifeq (,$(wildcard $(MOC_QT4)))
HAVE_QT4 = false
endif
ifeq (,$(wildcard $(RCC_QT4)))
HAVE_QT4 = false
endif

ifeq (,$(wildcard $(MOC_QT5)))
HAVE_QT5 = false
endif
@@ -296,27 +324,14 @@ ifeq (,$(wildcard $(UIC_QT5)))
HAVE_QT5 = false
endif

ifeq ($(HAVE_QT6),true)
QT6_HOSTBINS = $(shell $(PKG_CONFIG) --variable=libexecdir Qt6Core)
ifeq (,$(wildcard $(MOC_QT6)))
HAVE_QT6 = false
endif

MOC_QT6 ?= $(QT6_HOSTBINS)/moc
RCC_QT6 ?= $(QT6_HOSTBINS)/rcc
UIC_QT6 ?= $(QT6_HOSTBINS)/uic

ifeq ($(HAVE_QT4),true)
HAVE_QT = true
else ifeq ($(HAVE_QT5),true)
HAVE_QT = true
else ifeq ($(HAVE_QT6),true)
HAVE_QT = true
# FIXME
else ifeq ($(WINDOWS),true)
HAVE_QT = true
ifeq (,$(wildcard $(RCC_QT6)))
HAVE_QT6 = false
endif

ifneq (,$(findstring true,$(HAVE_QT5)$(HAVE_QT5PKG)$(HAVE_QT5BREW)))
HAVE_THEME = true
ifeq (,$(wildcard $(UIC_QT6)))
HAVE_QT6 = false
endif

# ---------------------------------------------------------------------------------------------------------------------
@@ -325,20 +340,54 @@ endif
PYRCC5 ?= $(shell which pyrcc5 2>/dev/null)
PYUIC5 ?= $(shell which pyuic5 2>/dev/null)

ifneq ($(PYUIC5),)
ifneq ($(PYRCC5),)
PYUIC6 ?= $(shell which pyuic6 2>/dev/null)

ifeq ($(HAVE_QT6),true)
ifneq ($(PYUIC6),)
HAVE_FRONTEND = true
HAVE_PYQT = true
FRONTEND_TYPE = 6
endif
endif

ifneq (,$(findstring true,$(HAVE_QT5)$(HAVE_QT5PKG)$(HAVE_QT5BREW)))
ifneq ($(PYUIC5)$(PYRCC5),)
HAVE_FRONTEND = true
HAVE_PYQT = true
FRONTEND_TYPE = 5
endif
endif

ifneq ($(PYUIC5)$(PYRCC5),)
PYRCC ?= $(PYRCC5)
PYUIC ?= $(PYUIC5)
else ifneq ($(PYUIC6),)
PYRCC ?= $(RCC_QT6) -g python
PYUIC ?= $(PYRCC6)
endif

# ---------------------------------------------------------------------------------------------------------------------
# Set PyQt tools, part2
# Set Qt tools, part2

PYRCC ?= $(PYRCC5)
PYUIC ?= $(PYUIC5)
ifneq (,$(findstring true,$(HAVE_QT4)$(HAVE_QT5)$(HAVE_QT5PKG)$(HAVE_QT5BREW)$(HAVE_QT6)))
HAVE_QT = true
endif

ifeq ($(FRONTEND_TYPE),5)
MOC = $(MOC_QT5)
RCC = $(RCC_QT5)
UIC = $(UIC_QT5)
HAVE_THEME = $(HAVE_QT5)
QT_CXX_FLAGS = $(QT5_CXX_FLAGS)
QT_LINK_FLAGS = $(QT5_LINK_FLAGS)
else ifeq ($(FRONTEND_TYPE),6)
MOC = $(MOC_QT6)
RCC = $(RCC_QT6)
UIC = $(UIC_QT6)
HAVE_THEME = $(HAVE_QT6)
QT_CXX_FLAGS = $(QT6_CXX_FLAGS)
QT_LINK_FLAGS = $(QT6_LINK_FLAGS)
endif

# ---------------------------------------------------------------------------------------------------------------------
# Set USING_RTAUDIO
@@ -405,6 +454,11 @@ QT5_FLAGS = $(shell $(PKG_CONFIG) --cflags Qt5Core Qt5Gui Qt5Widgets)
QT5_LIBS = $(shell $(PKG_CONFIG) --libs Qt5Core Qt5Gui Qt5Widgets)
endif

ifeq ($(HAVE_QT6),true)
QT6_FLAGS = $(shell $(PKG_CONFIG) --cflags Qt6Core Qt6Gui Qt6Widgets)
QT6_LIBS = $(shell $(PKG_CONFIG) --libs Qt6Core Qt6Gui Qt6Widgets)
endif

ifeq ($(WASM),true)
HAVE_SDL = true
SDL_FLAGS = -sUSE_SDL=2


+ 13
- 26
source/frontend/Makefile View File

@@ -21,7 +21,6 @@ endif
# ---------------------------------------------------------------------------------------------------------------------

BUILD_CXX_FLAGS += -I. -Iutils

BUILD_CXX_FLAGS += -I../backend
BUILD_CXX_FLAGS += -I../includes
BUILD_CXX_FLAGS += -I../modules
@@ -30,38 +29,26 @@ BUILD_CXX_FLAGS += -I../utils
# ---------------------------------------------------------------------------------------------------------------------

ifeq ($(WINDOWS),true)
QT5_LINK_FLAGS = $(shell echo $(LINK_FLAGS) | awk 'sub(" -static","")')
NON_STATIC_LINK_FLAGS = $(shell echo $(LINK_FLAGS) | awk 'sub(" -static","")') -static-libgcc
else
QT5_LINK_FLAGS = $(LINK_FLAGS)
NON_STATIC_LINK_FLAGS = $(LINK_FLAGS)
endif

ifeq ($(HAVE_QT5),true)
QT5_PREFIX = $(shell $(PKG_CONFIG) --variable=prefix Qt5Core)
BUILD_CXX_FLAGS += $(shell $(PKG_CONFIG) --cflags Qt5Core Qt5Gui Qt5Widgets)
QT5_LINK_FLAGS += -Wl,-rpath,$(QT5_PREFIX)/lib $(shell $(PKG_CONFIG) --libs Qt5Core Qt5Gui Qt5Widgets)
else ifeq ($(HAVE_QT5PKG),true)
QT5_PREFIX = $(shell $(PKG_CONFIG) --variable=prefix Qt5OpenGLExtensions)
BUILD_CXX_FLAGS += -DQT_CORE_LIB -DQT_GUI_LIB -DQT_WIDGETS_LIB -I $(QT5_PREFIX)/include/qt5
QT5_LINK_FLAGS += -Wl,-rpath,$(QT5_PREFIX)/lib -F $(QT5_PREFIX)/lib -framework QtCore -framework QtGui -framework QtWidgets
else ifeq ($(HAVE_QT5BREW),true)
QT5_PREFIX = /usr/local/opt/qt5
BUILD_CXX_FLAGS += -DQT_CORE_LIB -DQT_GUI_LIB -DQT_WIDGETS_LIB -I $(QT5_PREFIX)/include
QT5_LINK_FLAGS += -Wl,-rpath,$(QT5_PREFIX)/lib -F $(QT5_PREFIX)/lib -framework QtCore -framework QtGui -framework QtWidgets
else
$(error Trying to build frontend without Qt5, cannot continue)
ifeq (,$(FRONTEND_TYPE))
$(error Trying to build frontend without Qt and/or PyQt, cannot continue)
endif

ifeq ($(WINDOWS),true)
QT5_LINK_FLAGS += -L$(BINDIR) $(BINDIR)/libcarla_utils.dll
QT_LINK_FLAGS += -L$(BINDIR) $(BINDIR)/libcarla_utils.dll
else
QT5_LINK_FLAGS += -L$(BINDIR) -lcarla_utils
QT_LINK_FLAGS += -L$(BINDIR) -lcarla_utils
endif

ifeq ($(MACOS),true)
QT5_LINK_FLAGS += -install_name @rpath/libcarla_frontend.dylib
QT_LINK_FLAGS += -install_name @rpath/libcarla_frontend.dylib
# FIXME this does not work: -Wl,-rpath,@loader_path
else
QT5_LINK_FLAGS += -Wl,-rpath,'$${ORIGIN}'
QT_LINK_FLAGS += -Wl,-rpath,'$${ORIGIN}'
endif

# ---------------------------------------------------------------------------------------------------------------------
@@ -167,10 +154,10 @@ all: $(BINDIR)/libcarla_frontend$(LIB_EXT) $(QMs) $(RES) $(UIs)
# ---------------------------------------------------------------------------------------------------------------------

dialogs/ui_%.h: dialogs/%.ui
$(UIC_QT5) $< -o $@
$(UIC) $< -o $@

pluginlist/ui_%.h: pluginlist/%.ui
$(UIC_QT5) $< -o $@
$(UIC) $< -o $@

%_ui.py: %.ui
$(PYUIC) $< -o $@
@@ -183,7 +170,7 @@ resources_rc.py: $(RESDIR)/resources.qrc $(RESDIR)/*/*.png $(RESDIR)/*/*.svg $(R

test: $(OBJS) $(LIBS) test.cpp
@echo "Linking test"
$(SILENT)$(CXX) $(OBJS) test.cpp $(BUILD_CXX_FLAGS) -Wl,-rpath,$(abspath $(BINDIR)) $(QT5_LINK_FLAGS) -o $@
$(SILENT)$(CXX) $(OBJS) test.cpp $(BUILD_CXX_FLAGS) $(NON_STATIC_LINK_FLAGS) -Wl,-rpath,$(abspath $(BINDIR)) $(QT_LINK_FLAGS) -o $@

$(BINDIR)/resources/%: %
-@mkdir -p $(BINDIR)/resources
@@ -202,7 +189,7 @@ $(BINDIR)/resources/zynaddsubfx-ui: ../native-plugins/resources/zynaddsubfx-ui
$(BINDIR)/libcarla_frontend$(LIB_EXT): $(OBJS) $(LIBS)
-@mkdir -p $(BINDIR)
@echo "Linking libcarla_frontend$(LIB_EXT)"
$(SILENT)$(CXX) $(OBJS) $(BUILD_CXX_FLAGS) $(QT5_LINK_FLAGS) $(SHARED) -o $@
$(SILENT)$(CXX) $(OBJS) $(BUILD_CXX_FLAGS) $(QT_CXX_FLAGS) $(NON_STATIC_LINK_FLAGS) $(QT_LINK_FLAGS) $(SHARED) -o $@
ifeq ($(MACOS),true)
# FIXME this does not work: -Wl,-rpath,@loader_path
$(SILENT)install_name_tool -change ../../../bin/libcarla_utils.dylib @loader_path/libcarla_utils.dylib $@
@@ -211,7 +198,7 @@ endif
$(OBJDIR)/%.cpp.o: %.cpp $(UIs)
-@mkdir -p $(shell dirname $@)
@echo "Compiling $<"
$(SILENT)$(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@
$(SILENT)$(CXX) $< $(BUILD_CXX_FLAGS) $(QT_CXX_FLAGS) -c -o $@

-include $(OBJS:%.o=%.d)



+ 37
- 83
source/theme/Makefile View File

@@ -16,40 +16,6 @@ else
NON_STATIC_LINK_FLAGS = $(LINK_FLAGS)
endif

ifeq ($(HAVE_QT4),true)
QT4_CXX_FLAGS = $(BUILD_CXX_FLAGS) $(shell pkg-config --cflags QtCore QtGui)
QT4_LINK_FLAGS = $(NON_STATIC_LINK_FLAGS) $(shell pkg-config --libs QtCore QtGui)
QT4_STYLES_DIR = $(shell pkg-config --variable=libdir QtCore)/qt4/plugins/styles
endif

ifeq ($(HAVE_QT5),true)
QT5_CXX_FLAGS = $(BUILD_CXX_FLAGS) $(shell pkg-config --cflags Qt5Core Qt5Gui Qt5Widgets)
QT5_LINK_FLAGS = $(NON_STATIC_LINK_FLAGS) $(shell pkg-config --libs Qt5Core Qt5Gui Qt5Widgets)
QT5_STYLES_DIR = $(shell pkg-config --variable=libdir Qt5Core)/qt5/plugins/styles
else ifeq ($(HAVE_QT5PKG),true)
ifeq ($(MACOS),true)
ifeq ($(HAVE_PYQT),true)
HAVE_QT5 = true
QT5_PREFIX = $(shell pkg-config --variable=prefix Qt5OpenGLExtensions)
QT5_CXX_FLAGS = $(BUILD_CXX_FLAGS) -DQT_CORE_LIB -DQT_GUI_LIB -DQT_WIDGETS_LIB -I $(QT5_PREFIX)/include/qt5
QT5_LINK_FLAGS = $(NON_STATIC_LINK_FLAGS) -F $(QT5_PREFIX)/lib -framework QtCore -framework QtGui -framework QtWidgets
QT5_STYLES_DIR = $(QT5_PREFIX)/lib/qt5/plugins/styles
endif
endif
else ifeq ($(HAVE_QT5BREW),true)
HAVE_QT5 = true
QT5_PREFIX = /usr/local/opt/qt5
QT5_CXX_FLAGS = $(BUILD_CXX_FLAGS) -DQT_CORE_LIB -DQT_GUI_LIB -DQT_WIDGETS_LIB -I $(QT5_PREFIX)/include
QT5_LINK_FLAGS = $(NON_STATIC_LINK_FLAGS) -F $(QT5_PREFIX)/lib -framework QtCore -framework QtGui -framework QtWidgets
QT5_STYLES_DIR = $(QT5_PREFIX)/plugins/styles
endif

ifeq ($(HAVE_QT6),true)
QT6_CXX_FLAGS = $(BUILD_CXX_FLAGS) $(shell pkg-config --cflags Qt6Core Qt6Gui Qt6Widgets) -std=gnu++17
QT6_LINK_FLAGS = $(NON_STATIC_LINK_FLAGS) $(shell pkg-config --libs Qt6Core Qt6Gui Qt6Widgets)
QT6_STYLES_DIR = $(shell pkg-config --variable=libdir Qt6Core)/qt6/plugins/styles
endif

# ---------------------------------------------------------------------------------------------------------------------

ifeq ($(HAVE_QT4),true)
@@ -59,70 +25,56 @@ FILES_qt4 = \
$(OBJDIR)/moc_CarlaStylePlugin.qt4.cpp \
$(OBJDIR)/moc_CarlaStylePrivate.qt4.cpp \
$(OBJDIR)/resources.qt4.cpp
endif

ifeq ($(HAVE_QT5),true)
FILES_qt5 = \
$(OBJDIR)/moc_CarlaStyle.qt5.cpp \
$(OBJDIR)/moc_CarlaStyleAnimations.qt5.cpp \
$(OBJDIR)/moc_CarlaStylePlugin.qt5.cpp \
$(OBJDIR)/moc_CarlaStylePrivate.qt5.cpp \
$(OBJDIR)/resources.qt5.cpp
endif

ifeq ($(HAVE_QT6),true)
FILES_qt6 = \
$(OBJDIR)/moc_CarlaStyle.qt6.cpp \
$(OBJDIR)/moc_CarlaStyleAnimations.qt6.cpp \
$(OBJDIR)/moc_CarlaStylePlugin.qt6.cpp \
$(OBJDIR)/moc_CarlaStylePrivate.qt6.cpp \
$(OBJDIR)/resources.qt6.cpp
endif

# ---------------------------------------------------------------------------------------------------------------------

ifeq ($(HAVE_QT4),true)
OBJS_qt4 = \
$(OBJDIR)/CarlaStyle.cpp.qt4.o \
$(OBJDIR)/moc_CarlaStyle.qt4.cpp.o \
$(OBJDIR)/moc_CarlaStyleAnimations.qt4.cpp.o \
$(OBJDIR)/moc_CarlaStylePrivate.qt4.cpp.o \
$(OBJDIR)/resources.qt4.cpp.o

OBJS_qt4_shared = $(OBJS_qt4) \
$(OBJDIR)/CarlaStylePlugin.cpp.qt4.o \
$(OBJDIR)/moc_CarlaStylePlugin.qt4.cpp.o
endif

ifeq ($(HAVE_QT5),true)
FILES_qt5 = \
$(OBJDIR)/moc_CarlaStyle.qt5.cpp \
$(OBJDIR)/moc_CarlaStyleAnimations.qt5.cpp \
$(OBJDIR)/moc_CarlaStylePlugin.qt5.cpp \
$(OBJDIR)/moc_CarlaStylePrivate.qt5.cpp \
$(OBJDIR)/resources.qt5.cpp

OBJS_qt5 = \
$(OBJDIR)/CarlaStyle.cpp.qt5.o \
$(OBJDIR)/moc_CarlaStyle.qt5.cpp.o \
$(OBJDIR)/moc_CarlaStyleAnimations.qt5.cpp.o \
$(OBJDIR)/moc_CarlaStylePrivate.qt5.cpp.o \
$(OBJDIR)/resources.qt5.cpp.o

OBJS_qt5_shared = $(OBJS_qt5) \
$(OBJDIR)/CarlaStylePlugin.cpp.qt5.o \
$(OBJDIR)/moc_CarlaStylePlugin.qt5.cpp.o
endif

ifeq ($(HAVE_QT6),true)
FILES_qt6 = \
$(OBJDIR)/moc_CarlaStyle.qt6.cpp \
$(OBJDIR)/moc_CarlaStyleAnimations.qt6.cpp \
$(OBJDIR)/moc_CarlaStylePlugin.qt6.cpp \
$(OBJDIR)/moc_CarlaStylePrivate.qt6.cpp \
$(OBJDIR)/resources.qt6.cpp

OBJS_qt6 = \
$(OBJDIR)/CarlaStyle.cpp.qt6.o \
$(OBJDIR)/moc_CarlaStyle.qt6.cpp.o \
$(OBJDIR)/moc_CarlaStyleAnimations.qt6.cpp.o \
$(OBJDIR)/moc_CarlaStylePrivate.qt6.cpp.o \
$(OBJDIR)/resources.qt6.cpp.o

OBJS_qt6_shared = $(OBJS_qt6) \
$(OBJDIR)/CarlaStylePlugin.cpp.qt6.o \
$(OBJDIR)/moc_CarlaStylePlugin.qt6.cpp.o
endif

# ---------------------------------------------------------------------------------------------------------------------

ifeq ($(HAVE_QT5),true)
OBJS_qt_shared = $(OBJS_qt$(FRONTEND_TYPE)) \
$(OBJDIR)/CarlaStylePlugin.cpp.qt$(FRONTEND_TYPE).o \
$(OBJDIR)/moc_CarlaStylePlugin.qt$(FRONTEND_TYPE).cpp.o

# ---------------------------------------------------------------------------------------------------------------------

ifneq (,$(FRONTEND_TYPE))
all: $(BINDIR)/styles/carlastyle$(LIB_EXT) $(BINDIR)/styles/carlastyle.json
else
all:
@@ -167,20 +119,20 @@ $(MODULEDIR)/$(MODULENAME).qt6.a: $(FILES_qt6) $(OBJS_qt6)

# ---------------------------------------------------------------------------------------------------------------------

$(BINDIR)/styles/carlastyle.dll: $(FILES_qt5) $(OBJS_qt5_shared)
$(BINDIR)/styles/carlastyle.dll: $(FILES_qt5) $(OBJS_qt_shared)
-@mkdir -p $(BINDIR)/styles
@echo "Linking carlastyle.dll"
$(SILENT)$(CXX) $(OBJS_qt5_shared) $(QT5_LINK_FLAGS) -shared -o $@
$(SILENT)$(CXX) $(OBJS_qt_shared) $(NON_STATIC_LINK_FLAGS) $(QT_LINK_FLAGS) -shared -o $@

$(BINDIR)/styles/carlastyle.dylib: $(FILES_qt5) $(OBJS_qt5_shared)
$(BINDIR)/styles/carlastyle.dylib: $(FILES_qt5) $(OBJS_qt_shared)
-@mkdir -p $(BINDIR)/styles
@echo "Linking carlastyle.dylib"
$(SILENT)$(CXX) $(OBJS_qt5_shared) $(QT5_LINK_FLAGS) -dynamiclib -o $@
$(SILENT)$(CXX) $(OBJS_qt_shared) $(NON_STATIC_LINK_FLAGS) $(QT_LINK_FLAGS) -dynamiclib -o $@

$(BINDIR)/styles/carlastyle.so: $(FILES_qt5) $(OBJS_qt5_shared)
$(BINDIR)/styles/carlastyle.so: $(FILES_qt5) $(OBJS_qt_shared)
-@mkdir -p $(BINDIR)/styles
@echo "Linking carlastyle.so"
$(SILENT)$(CXX) $(OBJS_qt5_shared) $(QT5_LINK_FLAGS) -shared -o $@
$(SILENT)$(CXX) $(OBJS_qt_shared) $(NON_STATIC_LINK_FLAGS) $(QT_LINK_FLAGS) -shared -o $@

$(BINDIR)/styles/carlastyle.json: styles/carlastyle.json
-@mkdir -p $(BINDIR)/styles
@@ -223,36 +175,38 @@ $(OBJDIR)/resources.qt6.cpp: $(CWD)/../resources/resources-theme.qrc
$(OBJDIR)/%.qt4.cpp.o: $(OBJDIR)/%.qt4.cpp $(OBJDIR)/moc_CarlaStyle.qt4.cpp
-@mkdir -p $(OBJDIR)
@echo "Compiling $*.cpp (Qt4)"
$(SILENT)$(CXX) $< $(QT4_CXX_FLAGS) -Wno-unused-variable -c -o $@
$(SILENT)$(CXX) $< $(BUILD_CXX_FLAGS) $(QT4_CXX_FLAGS) -Wno-unused-variable -c -o $@

$(OBJDIR)/%.qt5.cpp.o: $(OBJDIR)/%.qt5.cpp $(OBJDIR)/moc_CarlaStyle.qt5.cpp
-@mkdir -p $(OBJDIR)
@echo "Compiling $*.cpp (Qt5)"
$(SILENT)$(CXX) $< $(QT5_CXX_FLAGS) -c -o $@
$(SILENT)$(CXX) $< $(BUILD_CXX_FLAGS) $(QT5_CXX_FLAGS) -c -o $@

$(OBJDIR)/%.qt6.cpp.o: $(OBJDIR)/%.qt6.cpp $(OBJDIR)/moc_CarlaStyle.qt6.cpp
-@mkdir -p $(OBJDIR)
@echo "Compiling $*.cpp (Qt6)"
$(SILENT)$(CXX) $< $(QT6_CXX_FLAGS) -c -o $@
$(SILENT)$(CXX) $< $(BUILD_CXX_FLAGS) $(QT6_CXX_FLAGS) -c -o $@

$(OBJDIR)/%.cpp.qt4.o: %.cpp $(OBJDIR)/moc_CarlaStyle.qt4.cpp
-@mkdir -p $(OBJDIR)
@echo "Compiling $< (Qt4)"
$(SILENT)$(CXX) $< $(QT4_CXX_FLAGS) -c -o $@
$(SILENT)$(CXX) $< $(BUILD_CXX_FLAGS) $(QT4_CXX_FLAGS) -c -o $@

$(OBJDIR)/%.cpp.qt5.o: %.cpp $(OBJDIR)/moc_CarlaStyle.qt5.cpp
-@mkdir -p $(OBJDIR)
@echo "Compiling $< (Qt5)"
$(SILENT)$(CXX) $< $(QT5_CXX_FLAGS) -c -o $@
$(SILENT)$(CXX) $< $(BUILD_CXX_FLAGS) $(QT5_CXX_FLAGS) -c -o $@

$(OBJDIR)/%.cpp.qt6.o: %.cpp $(OBJDIR)/moc_CarlaStyle.qt6.cpp
-@mkdir -p $(OBJDIR)
@echo "Compiling $< (Qt6)"
$(SILENT)$(CXX) $< $(QT6_CXX_FLAGS) -c -o $@
$(SILENT)$(CXX) $< $(BUILD_CXX_FLAGS) $(QT6_CXX_FLAGS) -c -o $@

# ---------------------------------------------------------------------------------------------------------------------

-include $(OBJS_qt4_shared:%.o=%.d)
-include $(OBJS_qt5_shared:%.o=%.d)
-include $(OBJS_qt4:%.o=%.d)
-include $(OBJS_qt5:%.o=%.d)
-include $(OBJS_qt6:%.o=%.d)
-include $(OBJS_qt_shared:%.o=%.d)

# ---------------------------------------------------------------------------------------------------------------------

Loading…
Cancel
Save