Subversion Repositories shark

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 pj 1
#
2
# Rules and common variables
3
#
4
 
5
HOSTNAME=$(shell uname)
6
 
7
ifeq ($(HOSTNAME),Linux)
8
else
9
ifeq ($(HOSTNAME),MS-DOS)
10
else
11
all::
12
	@echo System "$(HOSTNAME)" unknow
13
	@error
14
endif
15
endif
16
 
17
#
18
#
19
#
20
 
21
LIBNAME      = mpeg
22
 
23
 
24
#
25
INCLUDE_PATH = $(HARTIK)/h
26
LIB_PATH     = $(HARTIK)/lib
27
 
28
CC           = gcc
29
 
30
C_DEF_TOREMOVE = -D__GNU__
31
 
32
C_DEF        = -D_PARANOIA -D_GNU_SOURCE $(C_DEF_TOREMOVE)
33
C_WARN       = -Wimplicit-function-declaration -Wall
34
C_FLAGS      = -O -finline-functions -fno-builtin -nostdinc
35
 
36
 
37
C_INC        = -I. -I$(HARTIK)/include -I$(HARTIK)
38
 
39
 
40
#C_MAC        = -imacros $(HARTIK)/include/hartik/bdevconf.h
41
C_MAC        =
42
C_OPT        = $(C_DEF) $(C_WARN) $(C_INC) $(C_MAC) $(C_FLAGS)
43
C_OUTPUT     = -o $(notdir $*.o)
44
 
45
# for mpeg lib
46
C_DEF += -DHAVE_CONFIG_H -D__LINUX__ -DNOCONTROLS
47
C_INC += -I$(HARTIK)/../oskit/src/include -I$(HARTIK)/drivers/linuxcom/include
48
C_INC += -I$(HARTIK)/h -I$(HARTIK)/h/sys -I$(HARTIK)/h/x86
49
 
50
ASM_DEF      =
51
ASM_WARN     =
52
ASM_FLAGS    =
53
ASM_INC      = -I. -I$(HARTIK)/include
54
ASM_MAC      =
55
ASM_OPT      = $(ASM_DEF) $(ASM_WARN) $(ASM_INC) $(ASM_MAC) $(ASM_FLAGS)
56
ASM_OUTPUT   = -o $*.o
57
 
58
 
59
%.o : %.c
60
	$(REDIR) $(CC) $(C_OPT) $(C_OUTPUT) -c $<
61
 
62
%.o : %.S
63
	$(REDIR) $(CC) $(ASM_OPT) $(ASM_OUTPUT) -c $<