Last change
on this file since 822 was
822,
checked in by meunier, 9 years ago
|
In rosenfeld:
- Updated nrio0, nrio1, nrio2, nrio1f, nrio2f, nrio1x, nrbool1, nrbool2
and nralloc1 in the nrc2 lib in order to use macro-typed functions
- Updated the simulation script to include performance evaluation with
random images, and a script to generate graphs
- Updated the clock.h to use 64-bit integers, which potentially breaks
the printing on the giet
|
File size:
1.9 KB
|
Line | |
---|
1 | |
---|
2 | # -- Paths ---------- |
---|
3 | SRC_PATH = src-par |
---|
4 | OBJ_PATH = obj |
---|
5 | INC_PATH = include |
---|
6 | |
---|
7 | TARGET ?= linux |
---|
8 | # |
---|
9 | # -- Config ---------- |
---|
10 | |
---|
11 | ifeq ($(TARGET),giet-vm) |
---|
12 | |
---|
13 | C_DEBUG_FLAGS = -O0 |
---|
14 | C_OPTIM_FLAGS = -std=c99 -O2 -fstrict-aliasing |
---|
15 | C_OS_FLAGS = -DGTODay -DTARGET_OS=GIETVM |
---|
16 | C_CONFIG_FLAGS = -DCLI |
---|
17 | C_INC_FLAGS = -I$(INC_PATH) -Inrc2/include -I../.. -I../../giet_libs -I../../giet_xml/ |
---|
18 | CFLAGSCPU := -mips32 -EL -G0 -mhard-float -fomit-frame-pointer -fno-builtin -ffreestanding |
---|
19 | |
---|
20 | LDFLAGS := -Lnrc2 -L../../build/libs -Trosenfeld.ld --start-group -lnrc2x -luser -lmath --end-group |
---|
21 | |
---|
22 | endif |
---|
23 | |
---|
24 | ifeq ($(TARGET),linux) |
---|
25 | |
---|
26 | CC = gcc |
---|
27 | LD = gcc |
---|
28 | |
---|
29 | # -- Config ---------- |
---|
30 | C_DEBUG_FLAGS = -O0 |
---|
31 | C_OPTIM_FLAGS = -std=c99 -O2 -fstrict-aliasing |
---|
32 | C_OS_FLAGS = -DGTODay -DTARGET_OS=LINUX -D_GNU_SOURCE |
---|
33 | C_CONFIG_FLAGS = -DCLI |
---|
34 | C_INC_FLAGS = -I$(INC_PATH) -Inrc2/include |
---|
35 | CFLAGSCPU = |
---|
36 | |
---|
37 | LDFLAGS := -Lnrc2 -Wl,--start-group -lnrc2x -lm -lpthread -Wl,--end-group |
---|
38 | |
---|
39 | endif |
---|
40 | |
---|
41 | |
---|
42 | |
---|
43 | CFLAGSW := -Wredundant-decls -Wdisabled-optimization -Winline -Wpointer-arith -Wsign-compare -Wendif-labels -Wno-unused-function -Wno-unused-variable |
---|
44 | |
---|
45 | # -- Flags ---------- |
---|
46 | #CFLAGS = $(C_DEBUG_FLAGS) $(C_OS_FLAGS) $(C_INC_FLAGS) $(C_CONFIG_FLAGS) |
---|
47 | CFLAGS = $(C_OPTIM_FLAGS) $(C_OS_FLAGS) $(C_INC_FLAGS) $(C_CONFIG_FLAGS) -g -Wall $(CFLAGSW) $(CFLAGSCPU) |
---|
48 | |
---|
49 | |
---|
50 | APP_NAME = appli.elf |
---|
51 | |
---|
52 | SRC_FILE = $(wildcard $(SRC_PATH)/*.c) |
---|
53 | INC_FILE = $(wildcard $(INC_PATH)/*.h) |
---|
54 | |
---|
55 | #SRC = $(addprefix $(SRC_PATH)/,$(FILE)) |
---|
56 | OBJ_FILE = $(addprefix $(OBJ_PATH)/,$(addsuffix .o, $(basename $(notdir $(SRC_FILE))))) |
---|
57 | |
---|
58 | |
---|
59 | |
---|
60 | |
---|
61 | |
---|
62 | all: nrclib $(APP_NAME) |
---|
63 | |
---|
64 | nrclib: |
---|
65 | make -C nrc2 |
---|
66 | |
---|
67 | $(APP_NAME): $(OBJ_FILE) |
---|
68 | $(LD) -o $@ $^ $(LDFLAGS) |
---|
69 | |
---|
70 | #obj/bmpNR.o: src-par/bmpNR.c $(INC_FILE) nrc2/libnrc2x.a ../../build/libs/libuser.a nrc2/include/nrc_os_config.h |
---|
71 | # $(CC) -c $(CFLAGS) -o $@ $< |
---|
72 | |
---|
73 | $(OBJ_PATH)/%.o: $(SRC_PATH)/%.c $(INC_FILE) nrc2/libnrc2x.a ../../build/libs/libuser.a nrc2/include/nrc_os_config.h |
---|
74 | $(CC) -c $(CFLAGS) -o $@ $< |
---|
75 | |
---|
76 | clean: |
---|
77 | rm -f $(OBJ_FILE) |
---|
78 | rm -f $(APP_NAME) |
---|
79 | |
---|
80 | |
---|
81 | |
---|
Note: See
TracBrowser
for help on using the repository browser.