Subversion Repositories shark

Rev

Rev 306 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
308 giacomo 1
include $(BASE)/../shark.cfg
2
 
2 pj 3
CC  = gcc
4
AS  = gcc
5
LD  = ld
6
AR  = ar
7
INCL   = $(BASE)
8
LIB_PATH    = $(BASE)/lib/
9
LIB_DIR  = $(BASE)/lib
10
 
308 giacomo 11
ifeq ($(TSC),TRUE)
12
CFG_OPT = -D__TSC__
13
ifeq ($(APIC),TRUE)
14
CFG_OPT += -D__APIC__
15
endif
16
endif
17
 
18
C_OPT =  -Wall -O -fno-builtin -nostdinc -D__LINUX__ $(CFG_OPT) -DMAIN=__kernel_init__ -I$(INCL)
19
ASM_OPT =  -x assembler-with-cpp -D__LINUX__ $(CFG_OPT) -I$(INCL)
2 pj 20
LINK_OPT = -Bstatic -Ttext 0x220000 -s -nostartfiles -nostdlib -L$(LIB_PATH)
21
 
22
MKDIR   = mkdir
23
CP	= cp
24
CAT	= cat
25
RM	= rm -f
26
RMDIR	= rm -rf
27
 
28
# Common rules
29
 
30
%.o : %.s
31
	$(REDIR) $(CC) $(ASM_OPT) -c $<
32
%.o : %.c
33
	$(REDIR) $(CC) $(C_OPT) -c $<
34
%.s : %.c
35
	$(REDIR) $(CC) $(C_OPT) -S $<
36