Cleanup
[carla.git] / source / frontend / widgets / Makefile
blob0a6255396dce3151180ef1bbe88a4ab0a564eed1
1 #!/usr/bin/make -f
2 # Makefile for carla-widgets #
3 # -------------------------- #
4 # Created by falkTX
7 CWD=..
8 include $(CWD)/Makefile.mk
10 # ---------------------------------------------------------------------------------------------------------------------
12 BINDIR := $(CWD)/../bin
14 ifeq ($(DEBUG),true)
15 OBJDIR := $(CWD)/../build/widgets/Debug
16 MODULEDIR := $(CWD)/../build/modules/Debug
17 else
18 OBJDIR := $(CWD)/../build/widgets/Release
19 MODULEDIR := $(CWD)/../build/modules/Release
20 endif
22 # ---------------------------------------------------------------------------------------------------------------------
24 BUILD_CXX_FLAGS += -I. -I$(CWD)/includes -I$(CWD)/modules -I$(CWD)/utils
26 ifeq ($(HAVE_QT4),true)
27 BUILD_CXX_FLAGS += $(shell pkg-config --cflags QtCore QtGui)
28 LINK_FLAGS += $(shell pkg-config --libs QtCore QtGui)
29 else
30 BUILD_CXX_FLAGS += $(shell pkg-config --cflags Qt5Core Qt5Gui Qt5Widgets)
31 LINK_FLAGS += $(shell pkg-config --libs Qt5Core Qt5Gui Qt5Widgets)
32 endif
34 # ---------------------------------------------------------------------------------------------------------------------
36 # FILES = \
37 # moc_paramspinbox.cpp \
38 # moc_pixmapkeyboard.cpp
40 OBJS = \
41 $(OBJDIR)/digitalpeakmeter.cpp.o
43 # ledbutton.cpp.o \
44 # paramspinbox.cpp.o \
45 # pixmapdial.cpp.o \
46 # pixmapkeyboard.cpp.o
48 # OBJS += \
49 # moc_paramspinbox.cpp.o \
50 # moc_pixmapkeyboard.cpp.o
52 TARGET = $(MODULEDIR)/widgets.a
54 # ---------------------------------------------------------------------------------------------------------------------
56 all: $(TARGET)
58 # ---------------------------------------------------------------------------------------------------------------------
60 clean:
61 rm -f $(OBJDIR)/*.o $(TARGET)
63 debug:
64 $(MAKE) DEBUG=true
66 # ---------------------------------------------------------------------------------------------------------------------
68 $(MODULEDIR)/widgets.a: $(FILES) $(OBJS)
69 $(RM) $@
70 $(AR) crs $@ $(OBJS)
72 # ---------------------------------------------------------------------------------------------------------------------
74 $(OBJDIR)/%.cpp.o: %.cpp
75 -@mkdir -p $(OBJDIR)
76 @echo "Compiling $<"
77 $(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@
79 -include $(OBJS:%.o=%.d)
81 # moc_%.cpp.o: %.cpp
82 # $(CXX) moc_$< $(BUILD_CXX_FLAGS) -c -o $@
84 # moc_%.cpp: %.hpp
85 # $(MOC) $< -o $@
87 # ---------------------------------------------------------------------------------------------------------------------