Subversion Repositories Kolibri OS

Rev

Rev 4765 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1882 clevermous 1
include $(MENUETDEV)/osrules.mak
2
 
3
.SUFFIXES: .asm;
4
 
4765 right-hear 5
 
1882 clevermous 6
NASM = nasm
7
 
8
DEBUG = 0
9
 
10
.c.o:
11
	$(MGCC) $*.c $*.o $(CFLAGS) $(GCC32OPT)
12
 
13
.cpp.o:
14
	$(MGPP) $*.cpp $*.o $(CPPFLAGS) $(GCC32OPT)
15
 
16
.asm.o:
17
	$(NASM) $*.asm -o $*.o -f $(ASMFMT)
18
 
19
.s.o:
4763 right-hear 20
	$(CPP) -nostdinc -I$(MENUETDEV)/include $*.s -o $*.sx $(CSFLAGS) -DMENUETDEV=$(MENUETDEV) -D__DEV_CONFIG_H=\"$(MENUETDEV)/config.h\"
4764 right-hear 21
	$(AS) $*.sx $(AS32OPT) -o $*.o
1882 clevermous 22
 
23
ATHIS_LIBC_OBJS += $(subst .c,.o,$(filter %.c,$(THIS_SRCS))) \
24
	$(subst .s,.o,$(filter %.s,$(THIS_SRCS))) \
25
	$(subst .cpp,.o,$(filter %.cpp,$(THIS_SRCS)))
26
 
27
THIS_LIBC_OBJS = $(addprefix $(CURDIR)/,$(ATHIS_LIBC_OBJS))
28
 
29
export MENUET_LIBC_OBJS += $(THIS_LIBC_OBJS)
30
 
31
all: making check_ldepend $(ATHIS_LIBC_OBJS)
32
	@$(MENUET_LIBC_TOPDIR)/m_echo $(MENUET_LIBC_TOPDIR)/tmp_make $(THIS_LIBC_OBJS)
33
 
34
making:
35
	@echo --- Making in $(CURDIR) ---
36
 
37
clean:
38
	$(RM) $(ATHIS_LIBC_OBJS)
39
ifdef ON_MINGW
40
	@echo # nothing> ./ldepend
41
else
42
	@echo "# nothing" > ./ldepend
43
endif
44
 
45
ifdef DJDIR
46
depend:
47
	echo $(THIS_SRCS) > __tmp.1
48
	$(MMKDEP) @__tmp.1 > ./ldepend
49
	$(RM) __tmp.1
50
else
51
depend:
52
	$(MMKDEP) $(THIS_SRCS) > ./ldepend
53
endif
54
 
55
ifeq ($(wildcard ./ldepend),)
56
check_ldepend:
57
	echo Warning: ldepend not present in $(CURDIR)
58
else
59
check_ldepend:
60
 
61
include ldepend
62
endif