summaryrefslogtreecommitdiffstats
path: root/hello_world_ada/Makefile.erc32
blob: fe2db50221a0032f4349ffd8a0e7277f62cf600b (plain) (blame)
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
#
#  Makefile for hello world example
#

MAIN=hello

# Tool paths
target=sparc-rtems
tooldir=/home/joel/gnat-3.10b/${target}/
rtemsdir=${tooldir}/rtems/erc32

# Tool names
GCC=${tooldir}/bin/${target}-gcc
GNATMAKE=${tooldir}/bin/${target}-gnatmake
SIZE=${tooldir}/bin/${target}-size
SIS=${tooldir}/bin/sis
GDB=${tooldir}/bin/sis-gdb

CARGS=-B${rtemsdir}/lib/ -specs bsp_specs -qrtems -mcypress

all: init.o 
	$(GNATMAKE) -v -O -gnata -gnatE -gnato $(MAIN) -g \
	    -bargs -r \
	    -cargs $(CARGS) \
	    -largs $(CARGS) init.o
	$(SIZE) $(MAIN)



init.o: init.c
	$(GCC) -O4 -g  -Wall -ansi -fasm $(CARGS) -c init.c

run:
	$(SIS) $(MAIN)	

gdb:
	$(GDB) $(MAIN)	

clean:
	rm -f b_$(MAIN).c b_$(MAIN).o *.o *.ali $(MAIN)