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

Last change on this file since 778 was 772, checked in by meunier, 9 years ago
  • Ajout de l'application rosenfeld
  • Changement du nom du flag O_CREATE en O_CREAT
File size: 1.3 KB
Line 
1
2# -- Paths ----------
3SRC_PATH = src
4OBJ_PATH = obj
5EXE_PATH = bin
6INC_PATH = include
7
8
9# -- Config ----------
10C_DEBUG_FLAGS = -O0
11C_OPTIM_FLAGS = -std=c99 -O2 -fstrict-aliasing
12C_OS_FLAGS = -DGTODay
13C_CONFIG_FLAGS = -DCLI
14C_INC_FLAGS = -I$(INC_PATH) -Inrc2/include -I../.. -I../../giet_libs -I../../giet_xml/
15
16# -- Flags ----------
17#CFLAGS = $(C_DEBUG_FLAGS) $(C_OS_FLAGS) $(C_INC_FLAGS) $(C_CONFIG_FLAGS)
18CFLAGS = $(C_OPTIM_FLAGS) $(C_OS_FLAGS) $(C_INC_FLAGS) $(C_CONFIG_FLAGS)
19
20
21APP_NAME = rosenfeld
22
23SRC_FILE = $(wildcard $(SRC_PATH)/*.c)
24INC_FILE = $(wildcard $(SRC_PATH)/*.h)
25
26#SRC = $(addprefix $(SRC_PATH)/,$(FILE))
27OBJ_FILE = $(addprefix $(OBJ_PATH)/,$(addsuffix .o, $(basename $(notdir $(SRC_FILE)))))
28
29
30CFLAGSW := -Wredundant-decls -Wdisabled-optimization -Winline -Wpointer-arith -Wsign-compare -Wendif-labels
31CFLAGSCPU := -mips32 -EL -G0 -mhard-float
32CFLAGS := $(CFLAGS) -g -Wall -fomit-frame-pointer $(CFLAGSW) $(CFLAGSCPU) -I$(INC_PATH) -fno-builtin -ffreestanding
33
34LDFLAGS := -Lnrc2 -L../../build/libs -T$(APP_NAME).ld --start-group -lnrc2x -luser -lmath --end-group
35
36
37all: $(APP_NAME)
38
39$(APP_NAME): $(OBJ_FILE)
40        $(LD) -o $@ $^ $(LDFLAGS)
41
42$(OBJ_PATH)/%.o: $(SRC_PATH)/%.c $(INC_FILE) nrc2/libnrc2x.a ../../build/libs/libuser.a
43        $(CC) -c $(CFLAGS) -o $@ $<
44
45clean:
46        rm -f $(OBJ_FILE)
47        rm -f $(APP_NAME)
48
49
50
Note: See TracBrowser for help on using the repository browser.