1# This is Picprog, Microchip PIC programmer software for the serial 2# port device. 3# Copyright © 1997,2002,2003,2004 Jaakko Hyvätti 4# 5# This program is free software; you can redistribute it and/or modify 6# it under the terms of the GNU General Public License version 2 as 7# published by the Free Software Foundation. 8# 9# This program is distributed in the hope that it will be useful, 10# but WITHOUT ANY WARRANTY; without even the implied warranty of 11# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12# GNU General Public License for more details. 13# 14# You should have received a copy of the GNU General Public License 15# along with this program; if not, write to the Free Software Foundation, 16# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 17# 18# The author may be contacted at: 19# 20# Email: Jaakko.Hyvatti@iki.fi 21# URL: http://www.iki.fi/hyvatti/ 22# Phone: +358 40 5011222 23# 24# Please send any suggestions, bug reports, success stories etc. to the 25# Email address above. 26 27# Please use a reasonably recent GNU make. 28 29 30 31 32 33OBJS=main.o picport.o hexfile.o program.o 34PROG=picprog 35 36all: $(PROG) testport 37 38$(PROG): $(OBJS) 39 $(CXX) $(LDFLAGS) $(OBJS) -o $@ 40 41testport: testport.o 42 $(CXX) $(LDFLAGS) $^ -o $@ 43 44dep: 45 $(CXX) -M $(CXXFLAGS) *.cc > .depend 46 47clean: 48 rm -f core $(OBJS) $(PROG) 49 50tar: 51 chmod -R a+rX,go-w . 52 VERSION=`expr $$PWD : '.*-\([1-9]\.[1-9]\?[0-9]\(\.[0-9]\)\?\)$$'`; \ 53 cd ..; \ 54 tar -czvf $(PROG)-$$VERSION.tar.gz \ 55 $(PROG)-$$VERSION/{Makefile,COPYING,README} \ 56 $(PROG)-$$VERSION/[a-zA-Z]*.{html,png,1,h,cc} 57 58install: all 59 install -c -o 0 -g 0 -m 755 $(PROG) /usr/local/bin/ 60 install -c -o 0 -g 0 -m 644 *.1 /usr/local/man/man1/ 61 62# 63# include a dependency file if one exists 64# 65ifeq (.depend,$(wildcard .depend)) 66include .depend 67endif 68