From f80e4bda5263e3428537ecb7d49b18ffd3c0e4ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anton=20Luka=20=C5=A0ijanec?= Date: Sat, 16 Apr 2022 19:50:39 +0200 Subject: separated css and html, removed php-cli dependency --- Makefile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index b0831c6..a8baf36 100644 --- a/Makefile +++ b/Makefile @@ -3,12 +3,14 @@ CC = cc .NOTPARALLEL: default: mkdir tmp -p - -[ ! -f tmp/hp.css ] && wget -c https://sijanec.eu/assets/css/styles.css?ref=sear.c-make -Otmp/hp.css - php src/hp.php > tmp/hp.html + sed "s//$$PVR/g" < src/hp.html > tmp/hp.html # gentoo ebuild. git overrides it. + -VER=`git describe --always` && sed "s//$$VER/g" < src/hp.html > tmp/hp.html xxd -i < tmp/hp.html > tmp/hp.xxd echo ', 0' >> tmp/hp.xxd xxd -i < src/osdd.xml > tmp/osdd.xxd echo ', 0' >> tmp/osdd.xxd + xxd -i < src/css.css > tmp/css.xxd + echo ', 0' >> tmp/css.xxd $(CC) -Wall -Wextra -pedantic -Wno-unused-parameter -g -Isrc -Itmp -pthread src/main.c $$(xml2-config --libs --cflags) -lmicrohttpd -lm -osear.c install: @@ -33,3 +35,5 @@ test-http-valgrind: valgrind: valgrind --leak-check=full --show-leak-kinds=all --track-origins=yes --verbose --log-file=valgrind-out.txt ./sear.c + +.PHONY: valgrind test-http-valgrind test-http prepare clean distclean install default -- cgit v1.2.3