Subversion Repositories Kolibri OS

Rev

Rev 5096 | Rev 6082 | Go to most recent revision | Only display areas with differences | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 5096 Rev 5270
1
CC = gcc
-
 
2
AS = as
1
CC = gcc
3
 
2
AS = as
4
DRV_TOPDIR   = $(CURDIR)/..
3
 
5
DRV_INCLUDES = $(DRV_TOPDIR)/include
4
DRV_TOPDIR   = $(CURDIR)/..
6
 
5
DRV_INCLUDES = $(DRV_TOPDIR)/include
7
INCLUDES = 	-I$(DRV_INCLUDES) -I$(DRV_INCLUDES)/linux -I$(DRV_INCLUDES)/linux/asm
6
 
-
 
7
 
8
DEFINES  = 	-DKOLIBRI -D__KERNEL__ -DCONFIG_X86_32 -DCONFIG_DMI
8
INCLUDES =	-I$(DRV_INCLUDES)	\
-
 
9
		-I$(DRV_INCLUDES)/asm 	\
-
 
10
		-I$(DRV_INCLUDES)/uapi
-
 
11
 
9
CFLAGS = 	-c -Os $(INCLUDES) $(DEFINES) -march=i686 -fomit-frame-pointer -fno-builtin-printf \
12
DEFINES = -DKOLIBRI -D__KERNEL__ -DCONFIG_X86_32 -DCONFIG_DMI -DCONFIG_TINY_RCU
-
 
13
DEFINES+= -DCONFIG_X86_L1_CACHE_SHIFT=6 -DCONFIG_ARCH_HAS_CACHE_LINE_SIZE
-
 
14
 
10
-mno-stack-arg-probe -mpreferred-stack-boundary=2 -mincoming-stack-boundary=2
15
CFLAGS = 	-c -Os $(INCLUDES) $(DEFINES) -march=i686 -fomit-frame-pointer -fno-builtin-printf \
11
 
16
-mno-stack-arg-probe -mpreferred-stack-boundary=2 -mincoming-stack-boundary=2
12
NAME:=	  libddk
17
 
13
 
18
NAME:=	  libddk
14
CORE_SRC=	core.S
19
 
15
 
20
CORE_SRC=	core.S
16
 
21
 
17
NAME_SRCS:=  				\
22
 
18
		debug/dbglog.c		\
23
NAME_SRCS:=  				\
19
		debug/chkstk.S		\
24
		debug/dbglog.c		\
20
           	io/create.c		\
25
		debug/chkstk.S		\
21
           	io/finfo.c		\
26
           	io/create.c		\
22
           	io/ssize.c		\
27
           	io/finfo.c		\
23
           	io/write.c		\
28
           	io/ssize.c		\
24
		linux/bitmap.c		\
29
           	io/write.c		\
25
		linux/dmi.c		\
30
		linux/bitmap.c		\
26
		linux/idr.c		\
31
		linux/dmi.c		\
27
		linux/interval_tree.c	\
32
		linux/find_next_bit.c	\
-
 
33
		linux/idr.c		\
28
		linux/firmware.c	\
34
		linux/interval_tree.c	\
29
		linux/hdmi.c		\
35
		linux/firmware.c	\
30
		linux/kasprintf.c	\
36
		linux/hdmi.c		\
31
		linux/kref.c		\
37
		linux/kasprintf.c	\
32
		linux/list_sort.c	\
38
		linux/kref.c		\
33
		linux/mutex.c		\
39
		linux/list_sort.c	\
34
		linux/rbtree.c		\
40
		linux/mutex.c		\
35
		linux/dmapool.c		\
41
		linux/rbtree.c		\
36
		linux/ctype.c		\
42
		linux/dmapool.c		\
37
		linux/scatterlist.c	\
43
		linux/ctype.c		\
38
		linux/string.c		\
44
		linux/scatterlist.c	\
39
		linux/time.c		\
45
		linux/string.c		\
40
		linux/workqueue.c	\
46
		linux/time.c		\
41
		malloc/malloc.c		\
47
		linux/workqueue.c	\
42
		stdio/vsprintf.c	\
48
		malloc/malloc.c		\
43
		string/_memmove.S 	\
49
		stdio/vsprintf.c	\
44
		string/_strncat.S 	\
50
		string/_memmove.S 	\
45
		string/_strncmp.S 	\
51
		string/_strncat.S 	\
46
		string/_strncpy.S 	\
52
		string/_strncmp.S 	\
47
		string/_strnlen.S 	\
53
		string/_strncpy.S 	\
48
		string/bcmp.S 		\
54
		string/_strnlen.S 	\
49
		string/bcopy.S 		\
55
		string/bcmp.S 		\
50
		string/bzero.S 		\
56
		string/bcopy.S 		\
51
		string/index.S 		\
57
		string/bzero.S 		\
52
		string/memchr.S 	\
58
		string/index.S 		\
53
		string/memcmp.S 	\
59
		string/memchr.S 	\
54
		string/memcpy.S 	\
60
		string/memcmp.S 	\
55
		string/memmove.S 	\
61
		string/memcpy.S 	\
56
		string/memset.S 	\
62
		string/memmove.S 	\
57
		string/rindex.S 	\
63
		string/memset.S 	\
58
		string/strcat.S 	\
64
		string/rindex.S 	\
59
		string/strchr.S 	\
65
		string/strcat.S 	\
60
		string/strcmp.S 	\
66
		string/strchr.S 	\
61
		string/strcpy.S 	\
67
		string/strcmp.S 	\
62
		string/strlen.S 	\
68
		string/strcpy.S 	\
63
		string/strncat.S 	\
69
		string/strlen.S 	\
64
		string/strncmp.S 	\
70
		string/strncat.S 	\
65
		string/strncpy.S 	\
71
		string/strncmp.S 	\
66
		string/strnlen.S 	\
72
		string/strncpy.S 	\
67
		string/strrchr.S 
73
		string/strnlen.S 	\
68
 
74
		string/strrchr.S 
69
 
75
 
70
 
76
 
71
NAME_OBJS =  $(patsubst %.S, %.o, $(patsubst %.asm, %.o,\
77
 
72
             $(patsubst %.c, %.o, $(NAME_SRCS))))
78
NAME_OBJS =  $(patsubst %.S, %.o, $(patsubst %.asm, %.o,\
73
 
79
             $(patsubst %.c, %.o, $(NAME_SRCS))))
74
 
80
 
75
TARGET  = $(NAME).a 
81
 
76
 
82
TARGET  = $(NAME).a 
77
all: $(TARGET) libcore.a
83
 
78
 
84
all: $(TARGET) libcore.a
79
 
85
 
80
$(TARGET): $(NAME_OBJS) $(NAME_SRC) Makefile
86
 
81
	$(AR) cvrs $@ $(NAME_OBJS)
87
$(TARGET): $(NAME_OBJS) $(NAME_SRC) Makefile
82
 
88
	$(AR) cvrs $@ $(NAME_OBJS)
83
 
89
 
84
libcore.a: core.S Makefile
90
 
85
	$(AS) -o core.o $<
91
libcore.a: core.S Makefile
86
	$(LD) -shared -s --out-implib $@ --output-def core.def -o core.dll core.o
92
	$(AS) -o core.o $<
87
	
93
	$(LD) -shared -s --out-implib $@ --output-def core.def -o core.dll core.o
88
%.o: %.S Makefile
94
	
89
	$(CC) $(CFLAGS) -o $@ $<
95
%.o: %.S Makefile
90
 
96
	$(CC) $(CFLAGS) -o $@ $<
91
%.o: %.c Makefile ../include/*.h ../include/linux/*.h
97
 
92
	$(CC) $(CFLAGS) -o $@ $<
98
%.o: %.c Makefile ../include/*.h ../include/linux/*.h
93
 
99
	$(CC) $(CFLAGS) -o $@ $<
94
clean: 
100
 
95
	-rm -f */*.o
101
clean: 
96
 
102
	-rm -f */*.o
97
clean:>
103
 
98
 
104
clean:>
99
%.o:>
105
 
100
>
106
%.o:>
-
 
107
>