summaryrefslogtreecommitdiff
path: root/tools/showpic/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'tools/showpic/Makefile')
-rw-r--r--tools/showpic/Makefile46
1 files changed, 46 insertions, 0 deletions
diff --git a/tools/showpic/Makefile b/tools/showpic/Makefile
new file mode 100644
index 0000000..82970e7
--- /dev/null
+++ b/tools/showpic/Makefile
@@ -0,0 +1,46 @@
+#
+# Makefile for the GraphLCD tool showpic
+#
+
+-include ../../Make.config
+
+PRGNAME = showpic
+
+OBJS = showpic.o
+
+INCLUDES += -I../../
+LIBDIRS += -L../../glcdgraphics/ -L../../glcddrivers/
+
+
+all: $(PRGNAME)
+.PHONY: all
+
+# Implicit rules:
+
+%.o: %.c
+ $(CXX) $(CXXFLAGS) -c $(DEFINES) $(INCLUDES) $<
+
+# Dependencies:
+
+MAKEDEP = $(CXX) -MM -MG
+DEPFILE = .dependencies
+$(DEPFILE): Makefile
+ @$(MAKEDEP) $(DEFINES) $(INCLUDES) $(OBJS:%.o=%.c) > $@
+
+-include $(DEPFILE)
+
+# The main program:
+
+$(PRGNAME): $(OBJS)
+ $(CXX) $(CXXFLAGS) -rdynamic $(OBJS) $(LIBS) $(LIBDIRS) -lglcdgraphics -lglcddrivers -lstdc++ -o $(PRGNAME)
+
+install: $(PRGNAME)
+ install -d $(BINDIR)
+ install -m 755 -o root -g root -s $(PRGNAME) $(BINDIR)
+
+uninstall:
+ rm -f $(BINDIR)/$(PRGNAME)
+
+clean:
+ @-rm -f $(OBJS) $(DEPFILE) $(PRGNAME) *~
+