summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authornigel <nigel@d7aaf104-2d23-0410-ae22-9d23157bf5a3>2006-10-28 00:01:31 +0000
committernigel <nigel@d7aaf104-2d23-0410-ae22-9d23157bf5a3>2006-10-28 00:01:31 +0000
commit43cfa868eeed16d967d13afa38ad66c8f3ae80f0 (patch)
treee3bab5b11dd4e392689753fb62c99a137086691f /Makefile
parent0a812e1c84d0522584b60a3903b0c923054af8fc (diff)
downloadmarex-dev-43cfa868eeed16d967d13afa38ad66c8f3ae80f0.tar.gz
marex-dev-43cfa868eeed16d967d13afa38ad66c8f3ae80f0.tar.bz2
Some fixes to the Makefile. May be more to come, but I have to go out now :)
git-svn-id: file:///beryl/trunk@840 d7aaf104-2d23-0410-ae22-9d23157bf5a3
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile65
1 files changed, 36 insertions, 29 deletions
diff --git a/Makefile b/Makefile
index bc65aec..07da7e5 100644
--- a/Makefile
+++ b/Makefile
@@ -18,13 +18,13 @@
# clean: Cleanup.
# distclean: Cleanup thoroughly.
# all: Build and install everything from source.
+# all-debs: Build and install everything as debs.
#
# Per package targets:
# (Replace $NAME with one of the names from modules below).
#
# $NAME.clean Clean a single package.
-# $NAME.deb Build and install a single deb.
-# $NAME.new-deb (Re)build a previously built deb.
+# $NAME.new-deb (Re)build a deb.
# $NAME.build Build but don't install a single package.
# $NAME.rebuild (Re)build a package.
# $NAME.install Rebuild and install a single package from source.
@@ -39,15 +39,22 @@ CFLAGS?=-O2 -Wall -ggdb3 -gstabs+
EXTRA_PACKAGE_ARGS=-us -uc
SVNVER:=$(shell svn info | head -5 | tail -1 | awk -F ': ' '{ print $$2 }')
+ifeq ($(QUIET),1)
+REDIRECT=>$*.log 2>&1
+else
+REDIRECT=2>&1 | tee ../$*.log
+endif
+
modules:=\
beryl-core \
beryl-plugins \
beryl-settings \
- beryl-dbus \
beryl-manager \
emerald \
emerald-themes
+# beryl-dbus \
+
cfgmodules:=$(patsubst %,.%.cfg,$(modules))
buildmodules:=$(patsubst %,.%.build,$(modules))
installmodules:=$(patsubst %,.%.inst,$(modules))
@@ -56,7 +63,11 @@ debmodules:=$(patsubst %,.%.deb,$(modules))
all: update rebuild $(buildmodules)
-beryl-plugins.cfg beryl-settings.cfg emerald.cfg: beryl-core.inst
+all-debs: update clean debs
+
+beryl-plugins.deb beryl-settings.deb emerald.deb: beryl-core.deb
+
+beryl-plugins.cfg beryl-settings.cfg emerald.cfg: beryl-core.installed
beryl: update rebuild beryl-core.build beryl-plugins.build
@@ -71,50 +82,46 @@ usrlocalcheck:
done;
update:
- svn up
+ @svn up
debs: $(debmodules)
-%.deb: .%.cfg
- if [ -d $*.build/debian ]; then \
- rm -rf .$*.build/debian; \
- fi
+.%.deb: .%.cfg
+ @echo "==> Building $* debian package."
if [ -d distro-specific-build-files/$*/debian ]; then \
- cp -ar distro-specific-build-files/$*/debian .$*.build; \
+ cp -ar distro-specific-build-files/$*/debian .$*.build $(REDIRECT); \
fi
- sed "1 s/)/-svn${SVNVER})/" -i .$*.build/debian/changelog
- sh -c 'cd .$*.build; dpkg-buildpackage -rfakeroot $(EXTRA_PACKAGE_ARGS) 2>&1 | tee ../$*.log '
- rm -rf .$*.build
- $(SUCMD) dpkg -i *.deb
- mkdir -p output/${SVNVER}
- mv -f *.deb *.changes *.tar.gz *.dsc *.log output/${SVNVER}
+ @sed "1 s/)/-svn${SVNVER})/" -i .$*.build/debian/changelog
+ @sh -c 'cd .$*.build; dpkg-buildpackage -rfakeroot $(EXTRA_PACKAGE_ARGS)' $(REDIRECT)
+ @rm -rf .$*.build
+ @$(SUCMD) dpkg -i *.deb $(REDIRECT)
+ @mkdir -p output/${SVNVER}
+ @mv -f *.deb *.changes *.tar.gz *.dsc *.log output/${SVNVER}
@touch $@
%.new-deb: %.clean
- @make $*.deb
+ @make .$*.deb
@/bin/true
%.clean:
- @rm -rf .$*.build || /bin/true
- @rm -f .$*.cfg
- @rm -f .$*.built
- @rm -f .$*.installed
- @rm -f $*.deb
+ @echo "==> Cleaning $* build."
+ @rm -rf $*.build || /bin/true
+ @rm -f $*.cfg $*.built $*.installed $*.deb
.%.build: .%.cfg
- rm -f .$*.installed .$*.deb
- cp -ar $* .$*.build
- make -C .$*.build
+ @rm -f .$*.installed .$*.deb
+ @cp -ar $* .$*.build
+ @make -C .$*.build
@touch $@
.%.inst: .%.build
- $(SUCMD) make -C .$*.build install
+ @$(SUCMD) make -C .$*.build install
@touch $@
.%.cfg:
- @rm -rf .$*.build
- cp -ar $* .$*.build
- sh -c 'cd .$*.build;./autogen.sh --prefix=$(PREFIX) CFLAGS="$(CFLAGS)"'
+ @echo "==> Configuring $* build."
+ @cp -ar $* .$*.build $(REDIRECT)
+ @sh -c 'cd .$*.build;./autogen.sh --prefix=$(PREFIX) CFLAGS="$(CFLAGS)"' $(REDIRECT)
@rm -f .$*.built
@rm -f .$*.installed
@touch $@