diff options
-rw-r--r-- | Makefile | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -4,6 +4,9 @@ CC := gcc INSTALL := install CP := cp RM := rm +ZBARIMG := zbarimg +SED := sed +GREP := grep CFLAGS += -O2 -Wall -Werror CFLAGS += $(shell pkg-config --cflags --libs libpng) \ $(shell pkg-config --cflags --libs zlib) \ @@ -16,8 +19,15 @@ all: cqrlogo.c config.h config.h: $(CP) config.def.h config.h + install: $(INSTALL) -D -m0755 cqrlogo $(DESTDIR)/usr/share/webapps/cqrlogo/cqrlogo +check: + SERVER_NAME=www.eworm.de HTTP_REFERER=http://www.eworm.de/ \ + QUERY_STRING='scale=2&border=1' ./cqrlogo | $(SED) '1,2d' > \ + check.png && $(ZBARIMG) --raw -q check.png | $(GREP) -e \ + '^http://www.eworm.de/$$' + clean: $(RM) -f *.o *~ cqrlogo |