1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112
|
#!/usr/bin/make -f
# Sample debian/rules that uses debhelper.
# GNU copyright 1997 by Joey Hess.
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
# DBS options
package := libupnp
version := 1.6.6
INSTALL := install
INSTALL_DATA := $(INSTALL)install -m644
INSTALL_DIR := $(INSTALL) -p -d -o root -g root -m 755
INSTALL_FILE := $(INSTALL) -p -o root -g root -m 644
INSTALL_PROGRAM := $(INSTALL) -m755
INSTALL_SCRIPT := $(INSTALL) -p -o root -g root -m 755
SCRIPT_DIR = /usr/share/dbs
# no point in building them as we don't ship them
CONFOPTS ?= --disable-samples
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
CFLAGS += -O0 -Wall -g
endif
ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS)))
CONFOPTS += --enable-debug
endif
export LANG=
# the dbs rules
TAR_DIR := $(package)-$(version)
include $(SCRIPT_DIR)/dbs-build.mk
# dpkg-arch rules
ifeq (,$(DEB_BUILD_GNU_TYPE))
include $(SCRIPT_DIR)/dpkg-arch.mk
endif
# Make rules
configure: $(STAMP_DIR)/stamp-configure
$(STAMP_DIR)/stamp-configure:
dh_testdir
QUILT_PATCHES=debian/patches quilt push -a || test $$? = 2
autoreconf -f -i
CFLAGS="$(CFLAGS)" ./configure --build=$(DEB_BUILD_GNU_TYPE) --host=$(DEB_HOST_GNU_TYPE) --prefix=/usr --with-documentation=/usr/share/doc/libupnp3-dev $(CONFOPTS)
mkdir -p $(STAMP_DIR)
touch $@
build: $(STAMP_DIR)/stamp-build
$(STAMP_DIR)/stamp-build: $(STAMP_DIR)/stamp-configure
dh_testdir
$(MAKE)
# $(MAKE) html
touch $@
install: $(STAMP_DIR)/stamp-install
$(STAMP_DIR)/stamp-install: $(STAMP_DIR)/stamp-build
dh_testdir
dh_testroot
dh_clean -k
$(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
dh_installdirs
touch $@
clean:
dh_testdir
rm -rf $(STAMP_DIR) $(SOURCE_DIR)
rm -rf debian/tmp
perl $(SCRIPT_DIR)/dbs_split clean
QUILT_PATCHES=debian/patches quilt pop -a -R || test $$? = 2
# quilt cruft
rm -rf .pc
[ ! -f Makefile ] || $(MAKE) distclean
find -name "Makefile.in" | xargs -r rm
rm -f aclocal.m4 configure autoconfig.h.in
rm -rf build-aux
dh_clean
binary-indep:
binary-arch: build install
dh_install --sourcedir=debian/tmp --list-missing
dh_installdocs
dh_strip -plibupnp3 --dbg-package=libupnp3-dbg
dh_installchangelogs
dh_link
dh_compress
dh_fixperms
dh_makeshlibs
dh_installdeb
dh_shlibdeps -Llibupnp3 -ldebian/libupnp3/usr/lib
dh_shlibdeps -plibupnp3-dev
dh_gencontrol
dh_md5sums
dh_builddeb
binary: binary-indep binary-arch
source diff:
@echo >&2 'source and diff are obsolete - use dpkg-source -b'; false
|