diff options
Diffstat (limited to 'package/toolbox/src/common.mk')
-rw-r--r-- | package/toolbox/src/common.mk | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/package/toolbox/src/common.mk b/package/toolbox/src/common.mk new file mode 100644 index 000000000..ab0728f18 --- /dev/null +++ b/package/toolbox/src/common.mk @@ -0,0 +1,21 @@ +OBJS:= ${SRCS:.c=.o} +CFLAGS?= -Os -Wall +CPPFLAGS+= -I. +#CPPFLAGS+= -D_FILE_OFFSET_BITS=64 +CPPFLAGS+= -isystem ../lib +CPPFLAGS+= -D'__COPYRIGHT(x)=' -D'__RCSID(x)=' +CPPFLAGS+= -D'__unused=__attribute__((__unused__))' +CPPFLAGS+= -D'__dead=__attribute__((__noreturn__))' +CLEANFILES+= ${OBJS} ${PROG} + +all: + +COMPILE.c= ${CC} ${CPPFLAGS} ${CFLAGS} ${CFLAGS_$@} -c + +.c.o: + ${COMPILE.c} -o $@ $< + +clean: + rm -f ${CLEANFILES} + +# no depend magic; if you change a .h file, just make clean |