Verify bittorrent .torrent metainfo files.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
615B

  1. MultiThread = Yes
  2. PROGNAME = torrent-verify
  3. CC = cc
  4. CFLAGS = -Wall -std=gnu11 -I./subm/heapless-bencode -Werror -O3
  5. CPPFLAGS = -DPROGRAM_NAME='"$(PROGNAME)"' -DBUILD_INFO \
  6. -DBUILD_HASH="\"`git rev-parse --abbrev-ref HEAD` -> `git rev-parse --short HEAD`\"" -DBUILD_DATE="\"`date -I`\""
  7. ifeq ($(MultiThread), Yes)
  8. CFLAGS += -lpthread
  9. CPPFLAGS += -DMT
  10. endif
  11. SOURCE = $(wildcard subm/heapless-bencode/*.c) $(wildcard src/*.c)
  12. #OBJ = $(addsuffix .o,$(basename $(SOURCE)))
  13. OBJS = $(SOURCE:.c=.o)
  14. all: $(PROGNAME)
  15. $(PROGNAME): $(OBJS)
  16. $(CC) -o $@ $+ $(CFLAGS) $(CPPFLAGS)
  17. clean:
  18. -rm -- $(OBJS) $(PROGNAME)