summaryrefslogtreecommitdiff
path: root/src/Makefile
diff options
context:
space:
mode:
authorDaniel Carl <danielcarl@gmx.de>2018-04-14 21:57:07 +0200
committerDaniel Carl <danielcarl@gmx.de>2018-04-14 21:57:07 +0200
commitaad01d935221bb7e58e5d0f01613ae1677016195 (patch)
tree82fb6835d75b4f96462f2c801b1a3912a10c2193 /src/Makefile
parent366abadbd1ddecbc20891377911c86c77975594c (diff)
Use separate makefile in for scripts.
Diffstat (limited to 'src/Makefile')
-rw-r--r--src/Makefile15
1 files changed, 4 insertions, 11 deletions
diff --git a/src/Makefile b/src/Makefile
index a22d7a6..9c0ed2b 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -1,13 +1,11 @@
include ../config.mk
-OBJ = $(patsubst %.c, %.o, $(wildcard *.c))
-JSFILES = $(wildcard scripts/*.js)
-CSSFILES = $(wildcard scripts/*.css)
+OBJ = $(patsubst %.c, %.o, $(wildcard *.c))
all: vimb webextension.subdir-all
clean: webextension.subdir-clean
- $(RM) vimb *.o scripts/scripts.h
+ $(RM) vimb $(OBJ)
vimb: $(OBJ)
@echo "${CC} $@"
@@ -19,19 +17,14 @@ normal.o: scripts/scripts.h
setting.o: scripts/scripts.h
+scripts/scripts.h: scripts.subdir-all
+
-include $(OBJ:.o=.d)
config.h:
@echo create $@ from config.def.h
$(Q)cp config.def.h $@
-scripts/scripts.h: $(JSFILES) $(CSSFILES)
- $(Q)$(RM) $@
- @echo "create $@ from *.{css,js}"
- $(Q)for file in $(JSFILES) $(CSSFILES); do \
- ./scripts/js2h.sh $$file >> $@; \
- done
-
%.o: %.c
@echo "${CC} $@"
$(Q)$(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<