ADD: a switch to detect if Qt4 or Qt5 is used.

This commit is contained in:
iceman1001 2015-01-30 15:23:01 +01:00
parent 908536d161
commit e58c712c9e

View file

@ -37,6 +37,15 @@ LDLIBS += -ldl
LUAPLATFORM = linux
endif
# QT version, 4 or 5
qtplatform = $(shell $(MOC) -v)
ifneq (, $(findstring moc 5,$(qtplatform)))
CXXFLAGS = -I$(QTDIR)/include -I$(QTDIR)/include/QtCore -I$(QTDIR)/include/QtGui -I$(QTDIR)/include/QtWidgets -I/mingw/include
QTLDLIBS = -L$(QTDIR)/lib -lQt5Core -lQt5Gui -lQt5Widgets
else
CXXFLAGS = -I$(QTDIR)/include -I$(QTDIR)/include/QtCore -I$(QTDIR)/include/QtGui
QTLDLIBS = -L$(QTDIR)/lib -lQtCore4 -lQtGui4
endif
ifneq ($(QTLDLIBS),)
QTGUI = $(OBJDIR)/proxgui.o $(OBJDIR)/proxguiqt.o $(OBJDIR)/proxguiqt.moc.o