From 1e0a42d0979887fefcbb3918bd5cd5832afbecf0 Mon Sep 17 00:00:00 2001 From: Anibal Monsalve Salazar Date: Mon, 22 Oct 2007 19:16:49 +1000 Subject: [PATCH] Imported Debian patch 1.1.1-3 --- debian/changelog | 7 +++++++ debian/major.patch | 19 +++++++++++++++++++ debian/rules | 5 +++++ 3 files changed, 31 insertions(+) create mode 100644 debian/major.patch diff --git a/debian/changelog b/debian/changelog index eeb9aa2..30644af 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +nfs-utils (1:1.1.1-3) unstable; urgency=low + + * Fixed "FTBFS: error: called object 'major' is not a function" by + defining the missing called objects only on arm. Closes: #447578. + + -- Anibal Monsalve Salazar Mon, 22 Oct 2007 19:16:49 +1000 + nfs-utils (1:1.1.1-2) unstable; urgency=low * 07-amd64-logging-segfault.patch: New patch from Steve Langasek, fixes diff --git a/debian/major.patch b/debian/major.patch new file mode 100644 index 0000000..f9aca07 --- /dev/null +++ b/debian/major.patch @@ -0,0 +1,19 @@ +--- utils/mountd/cache.c 2007-10-19 13:07:28.000000000 +1000 ++++ utils/mountd/cache.c 2007-10-22 19:24:07.274232106 +1000 +@@ -36,6 +36,16 @@ + #include "blkid/blkid.h" + #endif + ++#ifdef major /* Might be defined in sys/types.h. */ ++#define HAVE_MAJOR ++#endif ++ ++#ifndef HAVE_MAJOR ++#define major(dev) (((dev) >> 8) & 0xff) ++#define minor(dev) ((dev) & 0xff) ++#define makedev(maj, min) (((maj) << 8) | (min)) ++#endif ++#undef HAVE_MAJOR + + enum nfsd_fsid { + FSID_DEV = 0, diff --git a/debian/rules b/debian/rules index ca12257..81659a4 100755 --- a/debian/rules +++ b/debian/rules @@ -2,12 +2,17 @@ include /usr/share/quilt/quilt.make +DEB_HOST_ARCH := $(shell dpkg-architecture -qDEB_HOST_ARCH) + # Temporary root DEBTMP := $(CURDIR)/debian/tmp build: patch build-stamp build-stamp: dh_testdir +ifeq ($(DEB_HOST_ARCH),arm) + patch -p0 -i debian/major.patch +endif CFLAGS="-g -O2 -Wall" ./configure \ --mandir='$${prefix}/share/man' \ --enable-secure-statd \ -- 2.39.2