Guillem Jover wrote:
OK, attempt #2. Better or should I not use two var and use like DEB_EXTRA_CONFIGURE_FLAGS or some such?Hey Barry, On Tue, 2007-04-10 at 17:27:10 -0400, Barry deFreese wrote:<snip>build: config build-stamp build-stamp: config.statusGiven that the difference should be minimal it's better to set a variable instead and use it on the configure argument line instead of duping the whole thing, this way it will be easy to maintin (you can check qemu for example on how to do something like that). Also is that «--enable-linuxcaps» there right?<snip> install -D -m 0755 debian/ntp.ifup debian/ntp/etc/network/if-up.d/ntpinstall -D -m 0755 debian/ntpdate.ifup debian/ntpdate/etc/network/if-up.d/ntpdateThe same here, you could use a varuable with the list instead, so no code is duped. regards, guillem
--- ntp/ntp-4.2.2.p4+dfsg/debian/rules 2007-04-10 16:07:45.000000000 +0000 +++ ntp2/ntp-4.2.2.p4+dfsg/debian/rules 2007-04-10 20:17:45.000000000 +0000 @@ -4,6 +4,16 @@ include /usr/share/quilt/quilt.make +ifeq ($(DEB_HOST_ARCH_OS),hurd) + IPV6_OPT = --enable-ipv6=no + LINUXCAP_OPT = --disable-linuxcaps + NTP_BINARIES = ntpdate ntp-wait ntpd tickadj ntp-keygen +else + IPV6_OPT = --enable-ipv6 + LINUXCAP_OPT = --enable-linuxcaps + NTP_BINARIES = ntpdate ntp-wait ntpd ntptime tickadj ntp-keygen +endif + # hacks to avoid running these things during the build export ACLOCAL = : aclocal export AUTOCONF = : autoconf @@ -20,24 +30,14 @@ config: patch config.status config.status: $(QUILT_STAMPFN) dh_testdir -ifeq ($(DEB_HOST_ARCH_OS),hurd) - ./configure CFLAGS='$(CFLAGS)' \ - --prefix=/usr \ - --enable-all-clocks --enable-parse-clocks --enable-SHM \ - --disable-debugging --sysconfdir=/var/lib/ntp \ - --with-sntp=no \ - --enable-linuxcaps \ - --enable-ipv6=no \ - --disable-dependency-tracking -else ./configure CFLAGS='$(CFLAGS)' \ --prefix=/usr \ --enable-all-clocks --enable-parse-clocks --enable-SHM \ --disable-debugging --sysconfdir=/var/lib/ntp \ --with-sntp=no \ - --enable-linuxcaps \ + $(LINUXCAP_OPT) \ + $(IPV6_OPT) \ --disable-dependency-tracking -endif build: config build-stamp build-stamp: config.status @@ -68,15 +68,9 @@ $(MAKE) install DESTDIR=$(CURDIR)/debian/ntp # move the administrator programs from /usr/bin to /usr/sbin -ifeq ($(DEB_HOST_ARCH_OS),hurd) - for file in ntpdate ntp-wait ntpd tickadj ntp-keygen; do \ + for file in $(NTP_BINARIES); do \mv debian/ntp/usr/bin/$$file debian/ntp/usr/sbin/$$file || exit; \
done -else - for file in ntpdate ntp-wait ntpd ntptime tickadj ntp-keygen; do \- mv debian/ntp/usr/bin/$$file debian/ntp/usr/sbin/$$file || exit; \
- done -endifinstall -D -m 0755 debian/ntp.ifup debian/ntp/etc/network/if-up.d/ntp install -D -m 0755 debian/ntpdate.ifup debian/ntpdate/etc/network/if-up.d/ntpdate
Thanks, Barry