mirror of
https://github.com/fangfufu/httpdirfs.git
synced 2024-09-29 21:52:12 +02:00
40 lines
900 B
Makefile
40 lines
900 B
Makefile
VERSION=1.1.3
|
|
|
|
CFLAGS+= -g -O2 -Wall -Wextra -D_FILE_OFFSET_BITS=64 -DVERSION=\"$(VERSION)\" \
|
|
`pkg-config --cflags-only-I gumbo libcurl fuse`
|
|
LDFLAGS+= -pthread -lgumbo -lcurl -lfuse -lcrypto \
|
|
`pkg-config --libs-only-L gumbo libcurl fuse`
|
|
COBJS = main.o network.o fuse_local.o link.o cache.o util.o
|
|
|
|
prefix ?= /usr/local
|
|
|
|
all: httpdirfs
|
|
|
|
%.o: src/%.c
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -c -o $@ $<
|
|
|
|
httpdirfs: $(COBJS)
|
|
$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o $@ $^
|
|
|
|
install:
|
|
install -m 755 -D httpdirfs \
|
|
$(DESTDIR)$(prefix)/bin/httpdirfs
|
|
install -m 644 -D doc/man/httpdirfs.1 \
|
|
$(DESTDIR)$(prefix)/share/man/man1/httpdirfs.1
|
|
|
|
doc:
|
|
doxygen Doxyfile
|
|
|
|
clean:
|
|
-rm -f *.o
|
|
-rm -f httpdirfs
|
|
-rm -rf doc/html
|
|
|
|
distclean: clean
|
|
|
|
uninstall:
|
|
-rm -f $(DESTDIR)$(prefix)/bin/httpdirfs
|
|
-rm -f $(DESTDIR)$(prefix)/share/man/man1/httpdirfs.1
|
|
|
|
.PHONY: all doc install clean distclean uninstall
|