]> git.sur5r.net Git - cc65/blob - libsrc/common/Makefile
98ca45efdb8bd07784dc76ea4f468d01eb18fef8
[cc65] / libsrc / common / Makefile
1 #
2 # makefile for CC65 runtime library
3 #
4
5 .SUFFIXES: .o .s .c
6
7 %.o:    %.c
8         @echo $<
9         @$(CC) $(CFLAGS) $<
10         @$(AS) -g -o $@ $(AFLAGS) $(*).s
11
12 %.o:    %.s
13         @echo $<
14         @$(AS) -g -o $@ $(AFLAGS) $<
15
16 C_OBJS = fclose.o fgets.o fprintf.o strdup.o calloc.o _fopen.o\
17          fputs.o fread.o fwrite.o gets.o realloc.o bsearch.o strxfrm.o\
18          printf.o _hextab.o vfprintf.o fdopen.o strtok.o\
19          _afailed.o fopen.o fgetc.o fputc.o puts.o gets.o perror.o getchar.o\
20          _printf.o vprintf.o vsprintf.o sprintf.o abort.o qsort.o putchar.o\
21          errormsg.o cprintf.o vcprintf.o freopen.o locale.o
22
23 S_OBJS =        _fdesc.o        \
24                 _file.o         \
25                 _hadd.o         \
26                 _heap.o         \
27                 _oserror.o      \
28                 _stksize.o      \
29                 _swap.o         \
30                 _sys.o          \
31                 abs.o           \
32                 atexit.o        \
33                 atoi.o          \
34                 copydata.o      \
35                 errno.o         \
36                 fmisc.o         \
37                 free.o          \
38                 getcpu.o        \
39                 isalnum.o       \
40                 isalpha.o       \
41                 isblank.o       \
42                 iscntrl.o       \
43                 isdigit.o       \
44                 isgraph.o       \
45                 islower.o       \
46                 isprint.o       \
47                 ispunct.o       \
48                 isspace.o       \
49                 isupper.o       \
50                 isxdigit.o      \
51                 itoa.o          \
52                 jmpvec.o        \
53                 labs.o          \
54                 longjmp.o       \
55                 ltoa.o          \
56                 malloc.o        \
57                 maperrno.o      \
58                 memchr.o        \
59                 memcmp.o        \
60                 memcpy.o        \
61                 memset.o        \
62                 rand.o          \
63                 setjmp.o        \
64                 stkcheck.o      \
65                 strcat.o        \
66                 strchr.o        \
67                 strcmp.o        \
68                 strcoll.o       \
69                 strcpy.o        \
70                 strcspn.o       \
71                 strerror.o      \
72                 stricmp.o       \
73                 strlen.o        \
74                 strlower.o      \
75                 strncat.o       \
76                 strncmp.o       \
77                 strncpy.o       \
78                 strpbrk.o       \
79                 strrchr.o       \
80                 strspn.o        \
81                 strstr.o        \
82                 strupper.o      \
83                 tolower.o       \
84                 toupper.o       \
85                 zerobss.o
86
87
88 all:    $(C_OBJS) $(S_OBJS)
89
90 clean:
91         @rm -f *~
92         @rm -f $(C_OBJS:.o=.s)
93         @rm -f $(C_OBJS)
94         @rm -f $(S_OBJS)