include config.mk
-all: $(SRCDIR).subdir-all
+all: src.subdir-all
options:
@echo "vimb build options:"
@echo "EXTCFLAGS = $(EXTCFLAGS)"
@echo "CC = $(CC)"
-install: $(SRCDIR).subdir-all
+install: src.subdir-all
@# binary
install -d $(BINPREFIX)
- install -m 755 $(SRCDIR)/vimb $(BINPREFIX)/vimb
+ install -m 755 src/vimb $(BINPREFIX)/vimb
@# extension
install -d $(LIBDIR)
- install -m 644 $(SRCDIR)/webextension/$(EXTTARGET) $(LIBDIR)/$(EXTTARGET)
+ install -m 644 src/webextension/$(EXTTARGET) $(LIBDIR)/$(EXTTARGET)
@# man page
install -d $(MANPREFIX)/man1
@sed -e "s!VERSION!$(VERSION)!g" \
$(RM) $(LIBDIR)/$(EXTTARGET)
$(RM) $(DOTDESKTOPPREFIX)/vimb.desktop
-clean: $(SRCDIR).subdir-clean
+clean: src.subdir-clean
sandbox:
$(Q)$(MAKE) RUNPREFIX=$(CURDIR)/sandbox/usr PREFIX=/usr DESTDIR=./sandbox install
-BASEDIR=..
-include $(BASEDIR)/config.mk
+include ../config.mk
-SUBDIRS = webextension
OBJ = $(patsubst %.c, %.o, $(wildcard *.c))
JSFILES = $(wildcard scripts/*.js)
CSSFILES = $(wildcard scripts/*.css)
-all: vimb $(SUBDIRS:%=%.subdir-all)
+all: vimb webextension.subdir-all
-clean: $(SUBDIRS:%=%.subdir-clean)
+clean: webextension.subdir-clean
$(RM) vimb *.o scripts/scripts.h
vimb: $(OBJ)
@echo "${CC} $@"
$(Q)$(CC) $(OBJ) $(LDFLAGS) -o $@
-$(OBJ): config.h $(BASEDIR)/config.mk
+$(OBJ): config.h ../config.mk
normal.o: scripts/scripts.h
-BASEDIR=../..
-include $(BASEDIR)/config.mk
+include ../../config.mk
OBJ = $(patsubst %.c, %.lo, $(wildcard *.c))