summaryrefslogtreecommitdiff
path: root/src/mods/Makefile.mods.in
diff options
context:
space:
mode:
authoradmin (centauri.fritz.box) <puppet@mx.buetow.org>2014-07-01 20:17:31 +0200
committeradmin (centauri.fritz.box) <puppet@mx.buetow.org>2014-07-01 20:17:31 +0200
commite5ff213596011443c467a5257ed6fe5847265d7f (patch)
treeb7322e71dd7f2fb1ff6824cb20acc706b84d06c5 /src/mods/Makefile.mods.in
parent0b4ccf59b27f0a8de71b10120b50c916fdbc46a0 (diff)
parent13aaf70af703748fe096e0664c305cd202637ad2 (diff)
Diffstat (limited to 'src/mods/Makefile.mods.in')
-rw-r--r--src/mods/Makefile.mods.in19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/mods/Makefile.mods.in b/src/mods/Makefile.mods.in
new file mode 100644
index 0000000..92a5409
--- /dev/null
+++ b/src/mods/Makefile.mods.in
@@ -0,0 +1,19 @@
+SRCS=$(shell find ./ -name '*.cpp')
+MODS=$(addprefix ../../../mods/@CATEGORY@/, $(SRCS:.cpp=.so))
+CXX=@CXX@
+CXXFLAGS=@CXXFLAGS@
+all: mods
+${MODS}:
+ @if ! test -d `dirname $@`; then mkdir -p `dirname $@`; fi
+ @${CXX} ${CXXGLAGS} -shared -s -o $@ ` \
+ echo $(notdir $@) | sed s/.so/.cpp/`
+ @echo "mods:@CATEGORY@:`basename $@ | sed s/\.so// | sed s/yc_//` (` \
+ du -hs $@ | awk '{ print $$1 }'`) "
+infotext:
+ @echo "===> Compiling @CATEGORY@ modules"
+mods: infotext ${MODS}
+ @echo "===> Num of @CATEGORY@ modules: `ls \
+ ../../../mods/@CATEGORY@/*.so | wc -l | sed 's/ //g;'`"
+clean:
+ @echo "===> Cleaning @CATEGORY@ modules"
+ @if test -d ../../../mods/@CATEGORY@; then rm -Rf ../../../mods/@CATEGORY@; fi