Package: chrony
Version: 1.23-3
Severity: minor
Tags: patch
There are a number of little issues with chrony's debian/rules:
- It does not allow to build in unoptimized using
DEB_BUILD_OPTIONS=noopt
- there are no build-arch and build-indep targets (those are optional
but the more packages having them, the faster buildds might be able
to not waste space on indep stuff).
- there are a lot of confusing comments (like sayint to put stuff
in debian/tmp and then putting it in debian/chrony)
- setting prefix to '' is quite confusing. This way one thinks there
might be a reason it is not done the canonical way which I could not
find.
- it ignores make distclean errors
- is there a reason it does this faqen.pl in binary-indep hack?
It seems to be only perl and running fast.
- you tell it to create chrony.html and chrony.info via make doc
anyway. why not just remove them so the .diff gets cleaner?
Same for getdate.c
- dh_installmanpages is deprecated, and not used anyway in this
package
Hochachtungsvoll,
Bernhard R. Link
Index: chrony-1.23/debian/rules
===================================================================
--- chrony-1.23.orig/debian/rules 2008-05-04 17:08:43.000000000 +0200
+++ chrony-1.23/debian/rules 2008-05-04 17:14:30.000000000 +0200
@@ -6,13 +6,22 @@
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
+CFLAGS = -Wall -g
+ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+ CFLAGS += -O0
+else
+ CFLAGS += -O2
+endif
+
build: build-stamp
+build-arch: build-stamp
+build-indep:
+
build-stamp:
dh_testdir
- ./configure --prefix=''
- # Add here commands to compile the package.
- $(MAKE)
+ CFLAGS="$(CFLAGS)" ./configure --prefix=/usr --mandir=/usr/share/man
+ $(MAKE)
$(MAKE) docs
touch build-stamp
@@ -21,9 +30,8 @@
dh_testdir
dh_testroot
rm -f build-stamp install-stamp debian/substvars
-
- # Add here commands to clean up after the build process.
- -$(MAKE) distclean
+ rm -f faq.html chrony.html chrony.info getdate.c
+ if [ -e Makefile ] ; then $(MAKE) distclean ; fi
dh_clean
@@ -34,17 +42,16 @@
dh_clean -k
dh_installdirs
- # Add here commands to install the package into debian/tmp.
- $(MAKE) install DESTDIR=`pwd`/debian/chrony/usr MANDIR=/share/man
+ $(MAKE) install DESTDIR=$(CURDIR)/debian/chrony
+ chmod 755 faqgen.pl
+ ./faqgen.pl < faq.txt > faq.html
touch install-stamp
-# Build architecture-independent files here.
-binary-indep: build install
- chmod 755 faqgen.pl
- ./faqgen.pl < faq.txt > faq.html
+# Build architecture-independent files:
+binary-indep:
-# Build architecture-dependent files here.
+# Build architecture-dependent files:
binary-arch: build install
dh_testdir
dh_testroot
@@ -53,16 +60,10 @@
dh_installmenu -n
dh_installinit -n
dh_installcron
- dh_installmanpages
- dh_installchangelogs
+ dh_installchangelogs
cp chrony.conf debian/chrony/usr/share/chrony
cp debian/chrony.conf.md5sum debian/chrony/usr/share/chrony
-# cp chrony.keys debian/chrony/etc/chrony
cp chrony.info debian/chrony/usr/share/info
-# cp chrony.info-1 debian/chrony/usr/share/info
-# cp chrony.info-2 debian/chrony/usr/share/info
-# cp chrony.info-3 debian/chrony/usr/share/info
-# cp chrony.info-4 debian/chrony/usr/share/info
cp debian/ip-up debian/chrony/etc/ppp/ip-up.d/chrony
cp debian/ip-down debian/chrony/etc/ppp/ip-down.d/chrony
cp debian/apm debian/chrony/etc/apm/event.d/01chrony
@@ -70,7 +71,6 @@
dh_strip
dh_compress
dh_fixperms
-# chmod 640 debian/chrony/etc/chrony/chrony.keys
chmod 755 debian/chrony/etc/ppp/ip-up.d/chrony debian/chrony/etc/ppp/ip-down.d/chrony
dh_installdeb
dh_shlibdeps
@@ -78,8 +78,8 @@
dh_md5sums
dh_builddeb
-source diff:
+source diff:
@echo >&2 'source and diff are obsolete - use dpkg-source -b'; false
binary: binary-indep binary-arch
-.PHONY: build clean binary-indep binary-arch binary
+.PHONY: build build-arch build-indep clean binary-indep binary-arch binary