summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDanny Baumann <dannybaumann@web.de>2007-04-18 13:01:33 +0200
committerDanny Baumann <dannybaumann@web.de>2007-04-18 13:01:33 +0200
commit134ce3574ff8a0a4e9058ded08b62f27c8e78cd8 (patch)
tree4da5f472925f5c9ac921037ca528ad7e20613592
parenta1ee1e536fa9f35af3f81e07d83de89d6ac128d0 (diff)
downloadberyl-premerge-134ce3574ff8a0a4e9058ded08b62f27c8e78cd8.tar.gz
beryl-premerge-134ce3574ff8a0a4e9058ded08b62f27c8e78cd8.tar.bz2
Use updated makefile.
-rw-r--r--src/3d/Makefile42
1 files changed, 30 insertions, 12 deletions
diff --git a/src/3d/Makefile b/src/3d/Makefile
index 67b4727..80c4726 100644
--- a/src/3d/Makefile
+++ b/src/3d/Makefile
@@ -20,9 +20,6 @@
## configuration
-#enter beryl or compiz here
-TARGET = compiz
-
#enter plugin name here
PLUGIN = 3d
@@ -31,7 +28,12 @@ PKG_DEP =
## end of configuration
+#enter beryl or compiz here
+TARGET = compiz
+
+
DESTDIR = $(HOME)/.$(TARGET)/plugins
+XMLDIR = $(HOME)/.$(TARGET)/metadata
BUILDDIR = build
@@ -44,10 +46,11 @@ BCOP = `pkg-config --variable=bin bcop`
CFLAGS = -g -Wall `pkg-config --cflags $(PKG_DEP) $(TARGET) `
LDFLAGS = `pkg-config --libs $(PKG_DEP) $(TARGET) `
-bcop-target := $(shell if [ -e $(PLUGIN).options ]; then echo $(PLUGIN).options; fi )
-bcop-target-src := $(shell if [ -e $(PLUGIN).options ]; then echo $(PLUGIN)_options.c; fi )
-bcop-target-hdr := $(shell if [ -e $(PLUGIN).options ]; then echo $(PLUGIN)_options.h; fi )
-bcop-opt := $(shell if [ "$(TARGET)" = "compiz" ]; then echo "--compiz"; else echo "--beryl"; fi )
+is-bcop-target := $(shell if [ -e $(PLUGIN).xml ]; then cat $(PLUGIN).xml | grep "useBcop=\"true\"";fi )
+
+bcop-target := $(shell if [ -n "$(is-bcop-target)" ]; then echo $(PLUGIN).xml; fi )
+bcop-target-src := $(shell if [ -n "$(is-bcop-target)" ]; then echo $(PLUGIN)_options.c; fi )
+bcop-target-hdr := $(shell if [ -n "$(is-bcop-target)" ]; then echo $(PLUGIN)_options.h; fi )
# find all the object files (including those from .moc.cpp files)
@@ -84,29 +87,31 @@ $(BUILDDIR) :
@mkdir -p $(BUILDDIR)
$(DESTDIR) :
- @mkdir -p $(DESTDIR)
+ @mkdir -p q$(DESTDIR)
#
# BCOP'ing
-%_options.h: %.options
+%_options.h: %.xml
@if [ '$(color)' != 'no' ]; then \
echo -e -n "\033[0;1;5mbcop'ing \033[0;1;37m: \033[0;32m$< \033[0;1;37m-> \033[0;31m$@\033[0m"; \
else \
echo "bcop'ing $< -> $@"; \
fi
- @$(BCOP) $(bcop-opt) --quiet --header $@ $<
+ @$(BCOP) --header=$@ $<
+ touch $@
@if [ '$(color)' != 'no' ]; then \
echo -e "\r\033[0mbcop'ing : \033[34m$< -> $@\033[0m"; \
fi
-%_options.c: %.options
+%_options.c: %.xml
@if [ '$(color)' != 'no' ]; then \
echo -e -n "\033[0;1;5mbcop'ing \033[0;1;37m: \033[0;32m$< \033[0;1;37m-> \033[0;31m$@\033[0m"; \
else \
echo "bcop'ing $< -> $@"; \
fi
- @$(BCOP) $(bcop-opt) --quiet --source $@ $<
+ @$(BCOP) --source=$@ $<
+ touch $@
@if [ '$(color)' != 'no' ]; then \
echo -e "\r\033[0mbcop'ing : \033[34m$< -> $@\033[0m"; \
fi
@@ -161,5 +166,18 @@ install: $(DESTDIR) all
@if [ '$(color)' != 'no' ]; then \
echo -e "\r\033[0minstall : \033[34m$(DESTDIR)/lib$(PLUGIN).so\033[0m"; \
fi
+ @if [ -e $(PLUGIN).xml ]; then \
+ if [ '$(color)' != 'no' ]; then \
+ echo -n -e "\033[0;1;5minstall \033[0;1;37m: \033[0;31m$(XMLDIR)/$(PLUGIN).xml\033[0m"; \
+ else \
+ echo "install : $(XMLDIR)/$(PLUGIN).xml"; \
+ fi; \
+ mkdir -p $(XMLDIR); \
+ $(INSTALL) $(PLUGIN).xml $(XMLDIR)/$(PLUGIN).xml; \
+ if [ '$(color)' != 'no' ]; then \
+ echo -e "\r\033[0minstall : \033[34m$(XMLDIR)/$(PLUGIN).xml\033[0m"; \
+ fi; \
+ fi
+