blob: d8058b0134e31e05260fe4b044f5c7465a99b351 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
TOP=..
include $(TOP)/Make.defs
OBJ = __ffillbuf.o __stdio_init.o fflush.o fgetc.o fgets.o \
fputc.o fputs.o puts.o printf.o fopen.o fclose.o scanf.o
#missing functions from above: printf etc, scanf etc, idealgetline
#seek
#fopen.c, fclose.c removed because of malloc() use
CFLAGS+=$(WALL)
ifeq ($(PLATFORM),i86-ELKS)
CFLAGS=$(CCFLAGS) $(DEFS) -ansi
endif
all: $(OBJ)
libc.a: $(OBJ)
ar r ../$(LIBC) $(OBJ)
@touch libc.a
$(OBJ): stdio.h
test: test.o $(OBJ)
$(CC) -o test test.o $(OBJ)
%.o: %.c
$(CC) $(CFLAGS) -o $@ $< -c
clean:
rm -f *.o test libc.a
transfer:
-@rm -f ../include/stdio.h
cp -p stdio.h ../include/.
|