From 20be3f828557374a0c33f083a3374e6b31b2056f Mon Sep 17 00:00:00 2001 From: Sebastian Harl Date: Sat, 14 Oct 2006 12:09:39 +0000 Subject: [PATCH] configure and build in ./debian/build. --- debian/rules | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/debian/rules b/debian/rules index fa2988f..bbbe4db 100755 --- a/debian/rules +++ b/debian/rules @@ -13,24 +13,28 @@ DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) CFLAGS = -Wall -g +BUILDDIR = ./debian/build/ + ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) CFLAGS += -O0 else CFLAGS += -O2 endif -config.status: configure +$(BUILDDIR)/config.status: configure dh_testdir - CFLAGS="$(CFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) \ + [ -e $(BUILDDIR) ] || mkdir $(BUILDDIR) + cd $(BUILDDIR) && CFLAGS="$(CFLAGS)" ../../configure \ + --host=$(DEB_HOST_GNU_TYPE) \ --build=$(DEB_BUILD_GNU_TYPE) \ --prefix=/usr build: build-stamp -build-stamp: config.status +build-stamp: $(BUILDDIR)/config.status dh_testdir - $(MAKE) + $(MAKE) -C $(BUILDDIR) touch build-stamp @@ -38,9 +42,8 @@ clean: dh_testdir dh_testroot rm -f build-stamp - rm -f config.sub config.guess - -$(MAKE) distclean + rm -rf $(BUILDDIR) dh_clean @@ -49,7 +52,7 @@ install: build dh_testroot dh_clean -k - $(MAKE) install DESTDIR=$(CURDIR)/debian/fusedav + $(MAKE) -C $(BUILDDIR) install DESTDIR=$(CURDIR)/debian/fusedav binary-indep: # nothing to do here -- 2.30.2