comparison spandsp-0.0.3/user/Makefile @ 5:f762bf195c4b

import spandsp-0.0.3
author Peter Meerwald <pmeerw@cosy.sbg.ac.at>
date Fri, 25 Jun 2010 16:00:21 +0200
parents
children
comparison
equal deleted inserted replaced
4:26cd8f1ef0b1 5:f762bf195c4b
1 # Makefile for user mode oslec test programs
2 # David Rowe December 16 2006
3 #
4 # Copyright David Rowe 2007
5 # This program is distributed under the terms of the GNU General Public License
6 # Version 2
7
8 TOPDIR = $(shell pwd)
9 export TOPDIR
10
11 # extract dir from /path/to/dir
12 RELCWD = $(shell pwd | sed -e "s/.*\///")
13
14 VERSION = 0.1
15 PROJ=zaptap
16
17 DATE = $(shell date '+%d %b %Y')
18
19 TARGETS = sample speedtest
20
21 # add Blackfin targets if Blackfin toolchain is present
22
23 BLACKFIN=$(shell which bfin-linux-uclibc-gcc 2>/dev/null)
24 ifeq ($(BLACKFIN),)
25 else
26 TARGETS += speedtest.bf speedtest_slow.bf tfir.bf
27 endif
28
29 all: $(TARGETS)
30
31 sample: sample.c
32 gcc sample.c -o sample -Wall
33
34 speedtest: speedtest.c
35 gcc speedtest.c -O6 -I../spandsp-0.0.3/src/spandsp/ \
36 ../spandsp-0.0.3/src/echo.c -o speedtest -Wall
37
38 echo.s : ../spandsp-0.0.3/src/echo.c
39 bfin-linux-uclibc-gcc -D__BLACKFIN__ -D__BLACKFIN_ASM__ -O6 \
40 -I../spandsp-0.0.3/src/spandsp/ \
41 ../spandsp-0.0.3/src/echo.c -c -S -Wall
42
43 speedtest.bf: speedtest.c echo.s
44 bfin-linux-uclibc-gcc -D__BLACKFIN__ -D__BLACKFIN_ASM__ speedtest.c -O6 \
45 -I../spandsp-0.0.3/src/spandsp/ \
46 echo.s -o speedtest.bf -Wall
47
48 speedtest_slow.bf: speedtest.c
49 bfin-linux-uclibc-gcc -D__BLACKFIN__ speedtest.c -O6 \
50 -I../spandsp-0.0.3/src/spandsp/ \
51 ../spandsp-0.0.3/src/echo.c -o speedtest_slow.bf -Wall
52
53 tfir.bf: tfir.c
54 bfin-linux-uclibc-gcc -D__BLACKFIN_ASM__ \
55 -I../spandsp-0.0.3/src/spandsp/ \
56 tfir.c -o tfir.bf -Wall
57
58 # generate tarball distro
59
60 dist:
61 @if [ ! -d ../$(PROJ) ]; then \
62 echo "Please change directory name to $(PROJ)"; \
63 exit 1; \
64 fi
65
66 # remove unneeded files
67 rm -f *~
68
69 # create tar ball containing only directories we need
70 cd ..; tar vczf $(PROJ)-$(VERSION).tar.gz $(RELCWD)
71 @echo
72 @echo "Tar ball created in ../"
73 ls -lh ../$(PROJ)-$(VERSION).tar.gz
74
75 clean:
76 rm -f $(TARGETS) *~
77
78 publish:
79 /home/david/attic/asciidoc-7.0.4/asciidoc.py \
80 -a stylesdir=$(TOPDIR)/asciidoc -f $(TOPDIR)/asciidoc/asciidoc.conf \
81 --unsafe -a date='$(DATE)' -a icons -a badges README.txt
82 scp README.html $(WEBSITE)/zaptap.html

Repositories maintained by Peter Meerwald, pmeerw@pmeerw.net.