Root/Software/xc3sprog/Makefile

1# Spartan3 JTAG programmer and other utilities
2
3# Copyright (C) 2004 Andrew Rogers
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 as published by
7# the Free Software Foundation; either version 2 of the License, or
8# (at your option) any later version.
9
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY; without even the implied warranty of
12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13# GNU General Public License for more details.
14
15# You should have received a copy of the GNU General Public License
16# along with this program; if not, write to the Free Software
17# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18
19
20GXX=mipsel-openwrt-linux-g++
21GCC=mipsel-openwrt-linux-gcc
22LIBS=-lstdc++
23
24all: xc3sprog
25#debug bitparse detectchain xc3sprog
26
27debug: debug.o iobase.o sakcXCProgrammer.o iodebug.o
28    ${GXX} -Wall ${LIBS} $^ -o $@
29
30bitparse: bitparse.o bitfile.o
31    ${GXX} -Wall ${LIBS} $^ -o $@
32
33detectchain: detectchain.o jtag.o iobase.o sakcXCProgrammer.o iodebug.o devicedb.o
34    ${GXX} -Wall ${LIBS} $^ -o $@
35
36xc3sprog: xc3sprog.o jtag.o iobase.o sakcXCProgrammer.o iodebug.o bitfile.o devicedb.o progalgxcf.o progalgxc3s.o jz47xx_gpio.o
37    ${GXX} -Wall ${LIBS} $^ -o $@
38
39debug.o: debug.cpp iobase.h sakcXCProgrammer.h iodebug.h
40    ${GXX} -Wall -c $< -o $@
41
42bitparse.o: bitparse.cpp bitfile.h
43    ${GXX} -Wall -c $< -o $@
44
45detectchain.o: detectchain.cpp iobase.h sakcXCProgrammer.h jtag.h iodebug.h devicedb.h
46    ${GXX} -Wall -c $< -o $@
47
48xc3sprog.o: xc3sprog.cpp iobase.h sakcXCProgrammer.h jtag.h iodebug.h bitfile.h devicedb.h progalgxcf.h progalgxc3s.h
49    ${GXX} -Wall -c $< -o $@
50
51iobase.o: iobase.cpp iobase.h
52    ${GXX} -c $< -o $@
53
54iodebug.o: iodebug.cpp iodebug.h iobase.h
55    ${GXX} -c $< -o $@
56
57sakcXCProgrammer.o: sakcXCProgrammer.cpp sakcXCProgrammer.h iobase.h
58    ${GXX} -c $< -o $@
59
60bitfile.o: bitfile.cpp bitfile.h
61    ${GXX} -c $< -o $@
62
63jtag.o: jtag.cpp jtag.h
64    ${GXX} -c $< -o $@
65
66devicedb.o: devicedb.cpp devicedb.h
67    ${GXX} -c $< -o $@
68
69progalgxcf.o: progalgxcf.cpp progalgxcf.h iobase.h jtag.h bitfile.h
70    ${GXX} -c $< -o $@
71
72progalgxc3s.o: progalgxc3s.cpp progalgxc3s.h iobase.h jtag.h bitfile.h
73    ${GXX} -c $< -o $@
74
75jz47xx_gpio.o: jz47xx_gpio.c jz47xx_gpio.h
76    ${GCC} -c $< -o $@
77
78clean:
79    rm -f debug.o iobase.o sakcXCProgrammer.o iodebug.o bitfile.o jtag.o xc3sprog.o
80    rm -f devicedb.o bitparse.o detectchain.o progalgxcf.o progalgxc3s.o
81    rm -f debug bitparse detectchain xc3sprog jz47xx_gpio.o *~
82

Archive Download this file

Branches:
master



interactive