source: project/release/3/z3/debian/debian/rules @ 8405

Last change on this file since 8405 was 8405, checked in by Ivan Raikov, 12 years ago

Copied debian/rules fixes to release 3 branch.

  • Property svn:executable set to *
File size: 1.4 KB
Line 
1#!/usr/bin/make -f
2export DH_COMPAT=4
3
4BUILD_ARCH = $(shell dpkg --print-installation-architecture)
5
6CFLAGS= -g
7ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
8     CFLAGS += -O0
9        else
10     CFLAGS += -O2 -fno-strict-aliasing
11endif
12
13EGG_TREE ?= /home/chicken/chicken-eggs
14
15BINARY_VERSION=$(shell basename `chicken-setup -R`)
16EGG_TMPDIR=debian/tmp/lib/chicken/$(BINARY_VERSION)
17CHICKEN_EGG=z3
18
19build: build-stamp
20build-stamp:
21        dh_testdir
22        mkdir -p $(CURDIR)/debian/tmp
23        chicken-setup -dont-ask -destdir $(CURDIR)/debian/tmp -local $(EGG_TREE) $(CHICKEN_EGG)
24        touch build-stamp
25
26clean:
27        dh_testdir
28        dh_testroot
29        rm -f build-stamp
30        rm -rf debian/tmp
31        rm -rf *.egg *.egg-dir *.exports *.so
32        dh_clean
33
34install: build
35        dh_testdir
36        dh_testroot
37        dh_installdirs
38
39binary-common:
40        dh_testdir
41        dh_testroot
42        dh_install $(EGG_TMPDIR)/{*.so,*.scm,*.setup-info,*.exports} var/lib/chicken/$(BINARY_VERSION)
43        dh_installdocs $(EGG_TMPDIR)/*.html
44#       dh_installman
45#       dh_installchangelogs ChangeLog
46#       dh_link
47ifeq "$(findstring nostrip,$(DEB_BUILD_OPTIONS))" ""
48        dh_strip
49endif   
50        dh_compress
51        dh_fixperms
52        dh_makeshlibs -V
53        dh_installdeb
54        dh_shlibdeps
55        dh_gencontrol
56        dh_md5sums
57        dh_builddeb
58
59binary-indep: build install
60
61binary-arch: build install
62        $(MAKE) -f debian/rules DH_OPTIONS=-a binary-common
63
64binary-%: build install
65        make -f debian/rules binary-common DH_OPTIONS=-p$*
66
67binary: binary-indep binary-arch
68.PHONY: build clean binary-indep binary-arch binary install
Note: See TracBrowser for help on using the repository browser.