source: soft/giet_vm/applications/rosenfeld/Makefile @ 822

Last change on this file since 822 was 822, checked in by meunier, 8 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 ----------
3SRC_PATH = src-par
4OBJ_PATH = obj
5INC_PATH = include
6
7TARGET ?= linux
8#
9# -- Config ----------
10
11ifeq ($(TARGET),giet-vm)
12
13C_DEBUG_FLAGS = -O0
14C_OPTIM_FLAGS = -std=c99 -O2 -fstrict-aliasing
15C_OS_FLAGS = -DGTODay -DTARGET_OS=GIETVM
16C_CONFIG_FLAGS = -DCLI
17C_INC_FLAGS = -I$(INC_PATH) -Inrc2/include -I../.. -I../../giet_libs -I../../giet_xml/
18CFLAGSCPU := -mips32 -EL -G0 -mhard-float -fomit-frame-pointer -fno-builtin -ffreestanding
19
20LDFLAGS := -Lnrc2 -L../../build/libs -Trosenfeld.ld --start-group -lnrc2x -luser -lmath --end-group
21
22endif
23
24ifeq ($(TARGET),linux)
25
26CC = gcc
27LD = gcc
28
29# -- Config ----------
30C_DEBUG_FLAGS = -O0
31C_OPTIM_FLAGS = -std=c99 -O2 -fstrict-aliasing
32C_OS_FLAGS = -DGTODay -DTARGET_OS=LINUX -D_GNU_SOURCE
33C_CONFIG_FLAGS = -DCLI
34C_INC_FLAGS = -I$(INC_PATH) -Inrc2/include
35CFLAGSCPU = 
36
37LDFLAGS := -Lnrc2 -Wl,--start-group -lnrc2x -lm -lpthread -Wl,--end-group
38
39endif
40
41
42
43CFLAGSW := -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)
47CFLAGS = $(C_OPTIM_FLAGS) $(C_OS_FLAGS) $(C_INC_FLAGS) $(C_CONFIG_FLAGS) -g -Wall $(CFLAGSW) $(CFLAGSCPU)
48
49
50APP_NAME = appli.elf
51
52SRC_FILE = $(wildcard $(SRC_PATH)/*.c)
53INC_FILE = $(wildcard $(INC_PATH)/*.h)
54
55#SRC = $(addprefix $(SRC_PATH)/,$(FILE))
56OBJ_FILE = $(addprefix $(OBJ_PATH)/,$(addsuffix .o, $(basename $(notdir $(SRC_FILE)))))
57
58
59
60
61
62all: nrclib $(APP_NAME)
63
64nrclib:
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
76clean:
77        rm -f $(OBJ_FILE)
78        rm -f $(APP_NAME)
79
80
81
Note: See TracBrowser for help on using the repository browser.