diff options
author | Ariadna Vigo <arivigodr@gmail.com> | 2020-06-19 16:03:23 +0200 |
---|---|---|
committer | Ariadna Vigo <arivigodr@gmail.com> | 2020-06-19 16:03:23 +0200 |
commit | 68a2b8706a41273b27dc3cfefbafd2c19dba7645 (patch) | |
tree | d632a5e09b8b0f360d478e46c46fb194995f9d6c /Makefile |
Initial commit
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..0868099 --- /dev/null +++ b/Makefile @@ -0,0 +1,37 @@ +# See LICENSE file for copyright and license details. + +.POSIX: + +include config.mk + +SRC = cras.c tasklst.c +OBJ = ${SRC:%.c=%.o} + +all: options cras + +options: + @echo Build options: + @echo "CFLAGS = ${CFLAGS}" + @echo "LDFLAGS = ${LDFLAGS}" + @echo "CC = ${CC}" + +.c.o: + ${CC} -c ${CFLAGS} $< + +${OBJ}: config.mk + +cras: ${OBJ} + ${CC} -o $@ ${OBJ} ${LDFLAGS} + +clean: + rm -f cras ${OBJ} + +install: all + mkdir -p ${DESTDIR}${PREFIX}/bin + cp -f cras ${DESTDIR}${PREFIX}/bin + chmod 755 ${DESTDIR}${PREFIX}/bin/cras + +uninstall: + rm -f ${DESTDIR}${PREFIX}/bin/cras + +.PHONY: all options clean install uninstall |