summaryrefslogtreecommitdiffstats
path: root/fpga/xilinx/programmer/bit2svf/Makefile
blob: a2387ad99ae9f112815be63e05e9320c2f70e47e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
CC=gcc
CFLAGS=-Wall -g3 -I$(BIDIR)
BIDIR=bitinfo-0.3
LDFLAGS=-I$(BIDIR)
PROYECTO=dumpbit bitdevice bit2svf
VERSION=1.3.1
PKG=bit2svf-$(VERSION)

all: $(PROYECTO) $(BIDIR)/bitinfo

$(BIDIR)/bitfile.o:
	$(MAKE) -C $(BIDIR)

bit2svf: bit2svf.o $(BIDIR)/bitfile.o parts.o commands.o bitshandle.o

bitdevice: bitdevice.o $(BIDIR)/bitfile.o

dumpbit: dumpbit.o $(BIDIR)/bitfile.o

debian/control: debian/packages debian/yada
	debian/yada rebuild control

debian/rules: debian/packages debian/yada
	debian/yada rebuild rules

deb: $(PROYECTO) debian/control debian/rules
	fakeroot dpkg-buildpackage -b -uc

tarball: clean
	cp -r ../bit2svf /tmp/$(PKG)
	-rm -rf /tmp/$(PKG)/CVS /tmp/$(PKG)/*/CVS /tmp/$(PKG)/*/*/CVS /tmp/$(PKG)/*/*/*/CVS /tmp/$(PKG)/*/*/*/*/CVS /tmp/$(PKG)/*/*/*/*/*/*/CVS /tmp/$(PKG)/*/*/*/*/*/*/CVS 2> /dev/null
	-rm -f /tmp/$(PKG)/.cvsignore /tmp/$(PKG)/*/.cvsignore /tmp/$(PKG)/*/*/.cvsignore /tmp/$(PKG)/*/*/*/.cvsignore /tmp/$(PKG)/*/*/*/*/.cvsignore /tmp/$(PKG)/*/*/*/*/*/*/.cvsignore /tmp/$(PKG)/*/*/*/*/*/*/.cvsignore 2> /dev/null
	-rm -f /tmp/$(PKG)/*.epr /tmp/$(PKG)/.*.dst /tmp/$(PKG)/Changelog /tmp/$(PKG)/lista 2> /dev/null
	cd /tmp ; tar zcvf $(PKG).tar.gz $(PKG)
	rm -r /tmp/$(PKG)
	mv /tmp/$(PKG).tar.gz .

clean:
	-rm -f *.o $(PROYECTO) .*~
	$(MAKE) -C $(BIDIR) clean
	debian/rules clean


install:
	mkdir -p /usr/share/bit2svf/
	cp -Rp templates/* /usr/share/bit2svf/
	cp -Rp bitdevice /usr/bin/
	cp -Rp bit2svf /usr/bin/