mirror of https://github.com/sipwise/sems.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
64 lines
1.2 KiB
64 lines
1.2 KiB
DSMPATH = ../
|
|
COREPATH = $(DSMPATH)/../../core
|
|
.DEFAULT_GOAL := all
|
|
|
|
include $(COREPATH)/../Makefile.defs
|
|
|
|
ifneq ($(USE_MONITORING), yes)
|
|
exclude_modules ?= mod_monitoring mod_mysql mod_aws
|
|
else
|
|
exclude_modules ?= mod_mysql mod_aws
|
|
endif
|
|
|
|
modules ?= $(filter-out $(subst ;, ,$(exclude_modules))\
|
|
$(wildcard Makefile*) lib CMakeLists.txt, \
|
|
$(wildcard *) )
|
|
|
|
|
|
.PHONY: all
|
|
all: modules
|
|
|
|
.PHONY: clean
|
|
clean:
|
|
-@rm -f lib/*.so
|
|
-@for r in $(modules) "" ; do \
|
|
if [ -n "$$r" ]; then \
|
|
echo "" ; \
|
|
echo "" ; \
|
|
COREPATH=../$(COREPATH) $(MAKE) -C $$r clean ; \
|
|
fi ; \
|
|
done
|
|
|
|
.PHONY: modules
|
|
modules:
|
|
-@for r in $(modules) "" ; do \
|
|
if [ -n "$$r" ]; then \
|
|
echo "" ; \
|
|
echo "" ; \
|
|
COREPATH=../$(COREPATH) $(MAKE) -C $$r all; \
|
|
fi ; \
|
|
done
|
|
|
|
.PHONY: install
|
|
install: install-bin install-cfg
|
|
|
|
.PHONY: install-bin
|
|
install-bin:
|
|
-@for r in $(modules) "" ; do \
|
|
if [ -n "$$r" ]; then \
|
|
echo "" ; \
|
|
echo "" ; \
|
|
COREPATH=../$(COREPATH) $(MAKE) -C $$r install; \
|
|
fi ; \
|
|
done
|
|
|
|
.PHONY: install-cfg
|
|
install-cfg: $(DESTDIR)$(cfg-target)
|
|
-@for r in $(modules) "" ; do \
|
|
if [ -n "$$r" ]; then \
|
|
echo "" ; \
|
|
echo "" ; \
|
|
COREPATH=../$(COREPATH) $(MAKE) -C $$r install-cfg; \
|
|
fi ; \
|
|
done
|