My slstatus configuration
Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

Makefile 1.0 KiB

il y a 8 ans
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. # See LICENSE file for copyright and license details.
  2. include config.mk
  3. SRC = ${NAME}.c
  4. OBJ = ${SRC:.c=.o}
  5. all: options ${NAME}
  6. options:
  7. @echo ${NAME} build options:
  8. @echo "CFLAGS = ${CFLAGS}"
  9. @echo "LDFLAGS = ${LDFLAGS}"
  10. @echo "CC = ${CC}"
  11. .c.o:
  12. @echo CC $<
  13. @${CC} -c ${CFLAGS} $<
  14. ${OBJ}: config.mk
  15. ${NAME}: ${OBJ}
  16. @echo CC -o $@
  17. @${CC} -o $@ ${OBJ} ${LDFLAGS}
  18. clean:
  19. @echo cleaning
  20. @rm -f ${NAME} ${OBJ} ${NAME}-${VERSION}.tar.gz
  21. dist: clean
  22. @echo creating dist tarball
  23. @mkdir -p ${NAME}-${VERSION}
  24. @cp -R Makefile config.mk LICENSE \
  25. ${SRC} ${NAME}-${VERSION}
  26. @tar -cf ${NAME}-${VERSION}.tar ${NAME}-${VERSION}
  27. @gzip ${NAME}-${VERSION}.tar
  28. @rm -rf ${NAME}-${VERSION}
  29. install: all
  30. @echo installing executable file to ${DESTDIR}${PREFIX}/bin
  31. @mkdir -p ${DESTDIR}${PREFIX}/bin
  32. @cp -f ${NAME} ${DESTDIR}${PREFIX}/bin
  33. @chmod 755 ${DESTDIR}${PREFIX}/bin/${NAME}
  34. uninstall:
  35. @echo removing executable file from ${DESTDIR}${PREFIX}/bin
  36. @rm -f ${DESTDIR}${PREFIX}/bin/${NAME}
  37. .PHONY: all options clean dist install uninstall