Makefile
author Dmitriy Morozov <dmitriy@mrzv.org>
Fri, 01 Mar 2013 13:21:38 -0800
changeset 12 f7fd7f943fc8
parent 10 118b5e4e0f9b
child 13 4de1b8165ac9
permissions -rw-r--r--
Use moc-qt4 and uic-qt4

# --------------------------------------------------------------------
# Makefile for IpePresenter
# --------------------------------------------------------------------

QT_CFLAGS = -I/usr/include/QtGui -I/usr/include/QtCore
QT_LIBS = -lQtGui -lQtCore
CPPFLAGS += $(QT_CFLAGS)
LIBS += -lipecanvas -lipecairo -lipe $(QT_LIBS) $(CAIRO_LIBS)
DESTDIR=/usr/bin

MOC=moc-qt4
UIC=uic-qt4

OBJECTS = mainwindow.o moc_mainwindow.o canvasview.o moc_canvasview.o \
		  timelabel.o moc_timelabel.o 

# .INTERMEDIATE: $(OBJECTS)		  

all: ipepresenter

moc_%.cpp: %.h
	$(MOC) -o $@ $<

# %.o: %.cpp
#     g++ $< -c $(CPPFLAGS)

# moc_%.o: moc_%.cpp
#     g++ $< -c $(CPPFLAGS)

ui_%.h: %.ui
	$(UIC) $< > $@

mainwindow.o: mainwindow.cpp ui_mainwindow.h
	g++ $< -c $(CPPFLAGS)

ipepresenter: $(OBJECTS)
	g++ $+ -o $@ $(LIBS)

install: ipepresenter
	install -m 755 ipepresenter $(DESTDIR)

clean:
	rm $(OBJECTS)