changed for plugin support
This commit is contained in:
parent
a26d082bdb
commit
da2d463ab7
20
Makefile
20
Makefile
@ -1,4 +1,5 @@
|
||||
BIN := $(shell basename $$(pwd))
|
||||
PLUGINS := rect
|
||||
|
||||
MANSECTION := 1
|
||||
MANPAGE := $(BIN).$(MANSECTION)
|
||||
@ -27,11 +28,11 @@ else
|
||||
CXXFLAGS += -D NDEBUG -O3
|
||||
endif
|
||||
|
||||
LDLIBS := -lm -lpthread -lscgui -lSDL2 -lcairo -lscerror
|
||||
LDLIBS := -lm -lpthread -lscgui -lSDL2 -lcairo -lscerror -lscstring
|
||||
|
||||
.PHONY: all clean install
|
||||
.PHONY: all clean install modules
|
||||
|
||||
all: $(BIN)
|
||||
all: $(BIN) $(PLUGINS)
|
||||
|
||||
$(BIN): $(OBJS) $(DEPS)
|
||||
$(CXX) $(OBJS) $(LDFLAGS) $(LDLIBS) -o $(BIN)
|
||||
@ -43,8 +44,21 @@ $(BIN): $(OBJS) $(DEPS)
|
||||
|
||||
%.d: ;
|
||||
|
||||
modules: $(PLUGINS)
|
||||
mkdir -p plugins
|
||||
@for plug in $(PLUGINS) ;\
|
||||
do \
|
||||
cd $$plug && $(MAKE) && $(MAKE) install ;\
|
||||
cd .. ;\
|
||||
done
|
||||
|
||||
clean:
|
||||
$(RM) $(OBJS) $(DEPS) $(BIN)
|
||||
$(RM) -r plugins
|
||||
@for plug in $(PLUGINS) ;\
|
||||
do \
|
||||
$(MAKE) -C $$plug clean ;\
|
||||
done
|
||||
|
||||
install: $(BIN)
|
||||
$(INSTALL) -d $(BINDIR)
|
||||
|
Loading…
x
Reference in New Issue
Block a user