~ubuntu-branches/ubuntu/edgy/logrotate/edgy

« back to all changes in this revision

Viewing changes to debian/rules

  • Committer: Bazaar Package Importer
  • Author(s): Paul Martin
  • Date: 2004-06-11 13:51:34 UTC
  • mfrom: (1.1.1 upstream)
  • mto: This revision was merged to the branch mainline in revision 3.
  • Revision ID: james.westby@ubuntu.com-20040611135134-xwwlztb186794ikt
Tags: 3.7-2
* Added commented out stuff in debian/rules to build a 
  logrotate-selinux package should Russell's move to get libselinux1 
  made "base" fail.
* Patch: 21-taboo-to-debug, reduces the "Ignoring..." messages of
  the taboo filter from ERROR to DEBUG. (Closes: #249073)
* Patch: 30-config-h, changed to fix upstream bug with mailing
  logs. (Closes: #253837)

Show diffs side-by-side

added added

removed removed

Lines of Context:
5
5
# Uncomment this to turn on verbose mode.
6
6
#export DH_VERBOSE=1
7
7
 
8
 
# This is the debhelper compatability version to use.
9
 
export DH_COMPAT=3
 
8
CFLAGS = -Wall -g
 
9
INSTALL = install
 
10
INSTALL_FILE    = $(INSTALL) -p    -o root -g root  -m  644
 
11
INSTALL_PROGRAM = $(INSTALL) -p    -o root -g root  -m  755
 
12
INSTALL_SCRIPT  = $(INSTALL) -p    -o root -g root  -m  755
 
13
INSTALL_DIR     = $(INSTALL) -p -d -o root -g root  -m  755
 
14
 
 
15
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
 
16
CFLAGS += -O0
 
17
else
 
18
CFLAGS += -O2
 
19
endif
 
20
ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
 
21
INSTALL_PROGRAM += -s
 
22
endif
 
23
 
10
24
 
11
25
configure: configure-stamp
12
 
configure-stamp:
 
26
configure-stamp: patch
13
27
        dh_testdir
14
28
        # Add here commands to configure the package.
15
29
 
16
30
        touch configure-stamp
17
31
 
18
32
build: configure-stamp build-stamp
19
 
build-stamp:
 
33
build-stamp: patch
20
34
        dh_testdir
21
35
 
22
 
        # Add here commands to compile the package.
23
 
        RPM_OPT_FLAGS=-O2 $(MAKE)
 
36
        #$(MAKE) RPM_OPT_FLAGS="$(CFLAGS)" VERSION="3.7" WITH_SELINUX="yes"
 
37
        #mv $(CURDIR)/logrotate $(CURDIR)/logrotate.selinux
 
38
        #rm $(CURDIR)/logrotate.o
 
39
 
 
40
        $(MAKE) RPM_OPT_FLAGS="$(CFLAGS)" VERSION="3.7"
24
41
 
25
42
        touch build-stamp
26
43
 
27
 
clean:
 
44
clean: clean-patched unpatch
 
45
clean-patched:
28
46
        dh_testdir
29
47
        dh_testroot
30
48
        rm -f build-stamp configure-stamp
31
49
 
32
 
        # Add here commands to clean up after the build process.
33
50
        -$(MAKE) clean
34
51
        rm -f .depend
35
52
 
36
 
        dh_clean
37
 
        rm -f debian/cron.daily
 
53
        dh_clean logrotate.selinux
38
54
 
39
55
install: build
40
56
        dh_testdir
43
59
        dh_installdirs
44
60
 
45
61
        # Add here commands to install the package into debian/logrotate.
46
 
        $(MAKE) install PREFIX=$(CURDIR)/debian/logrotate
47
 
        install -m 644 $(CURDIR)/examples/logrotate.cron \
48
 
          $(CURDIR)/debian/cron.daily
49
 
        install -m 644 $(CURDIR)/debian/logrotate.conf \
 
62
        $(INSTALL_PROGRAM) $(CURDIR)/logrotate \
 
63
          $(CURDIR)/debian/logrotate/usr/sbin/
 
64
        #$(INSTALL_PROGRAM) $(CURDIR)/logrotate.selinux \
 
65
        #  $(CURDIR)/debian/logrotate-selinux/usr/sbin/logrotate
 
66
 
 
67
        $(INSTALL_FILE) $(CURDIR)/debian/logrotate.conf \
50
68
          $(CURDIR)/debian/logrotate/etc/logrotate.conf
 
69
        #$(INSTALL_FILE) $(CURDIR)/debian/logrotate.conf \
 
70
        #  $(CURDIR)/debian/logrotate-selinux/etc/logrotate.conf
 
71
 
 
72
        # reportbug script
 
73
        $(INSTALL_SCRIPT) $(CURDIR)/debian/logrotate.bug \
 
74
          $(CURDIR)/debian/logrotate/usr/share/bug/logrotate/script
 
75
        #$(INSTALL_SCRIPT) $(CURDIR)/debian/logrotate.bug \
 
76
        #  $(CURDIR)/debian/logrotate-selinux/usr/share/bug/logrotate/script
51
77
 
52
78
 
53
79
 
69
95
#       dh_installmime
70
96
#       dh_installinit
71
97
        dh_installcron
72
 
        dh_installman
 
98
        dh_installman logrotate.8
73
99
#       dh_installinfo
74
100
#       dh_undocumented
75
101
        dh_installchangelogs CHANGES
86
112
        dh_builddeb
87
113
 
88
114
binary: binary-indep binary-arch
89
 
.PHONY: build clean binary-indep binary-arch binary install configure
 
115
 
 
116
patch: patch-stamp
 
117
patch-stamp:
 
118
        dpatch apply-all
 
119
        touch patch-stamp
 
120
        # dpatch call-all -a=pkg-info >patch-stamp
 
121
 
 
122
unpatch:
 
123
        dpatch deapply-all
 
124
        rm -rf patch-stamp debian/patched
 
125
 
 
126
.PHONY: build clean binary-indep binary-arch binary install configure \
 
127
 patch unpatch clean-patched