Makefile 302 B

123456789101112131415161718192021
  1. CC:=gcc
  2. OBJ:=bucts.o
  3. VERSION:=withoutgit
  4. ifeq ($(shell uname), FreeBSD)
  5. CFLAGS = -I/usr/local/include
  6. LDFLAGS = -L/usr/local/lib
  7. endif
  8. all: bucts
  9. bucts: $(OBJ)
  10. $(CC) -o $@ $(OBJ) $(LDFLAGS) -lpci
  11. %.o: %.c
  12. $(CC) $(CFLAGS) -DVERSION='"$(VERSION)"' -c $<
  13. .PHONY: clean
  14. clean:
  15. rm -f bucts $(OBJ)