Hi,
I did this merge with 3a382320e8d0b52a250efd8907f8429497de2335
and bities.
the package seems to work again on linux 3.11.
I have attached patch on debian directory, and the extra work on ylwrap.
Christian Montanari.
>From f51880a4d88a5a49aae5fd7297831dc7b4c62818 Mon Sep 17 00:00:00 2001
From: Christian Montanari <cp.montan...@tiscali.co.uk>
Date: Mon, 28 Oct 2013 06:55:02 +0000
Subject: [PATCH] compiled for debian package 6.2+rc20130922-1.
---
debian/changelog | 25 +++++++++++++++++++++++++
debian/control | 2 +-
debian/patches/series | 6 +++---
debian/rules | 2 +-
4 files changed, 30 insertions(+), 5 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 285506a..af8f67e 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,28 @@
+am-utils (6.2+rc20130922-1) unstable; urgency=low
+
+ * Merge master of git://git.fsl.cs.sunysb.edu/am-utils-6.2.git
+ fix flaw when kernel version is 3.x
+ update copyright notice for 2013
+ Regen, and recent changes
+ adjust to new autoconf requirements
+ INCLUDES -> AM_CPPFLAGS in new autoconf
+ Fix macro names
+ Regen from newer autoconf
+ recognize noacl
+ Instead of calling each autoconf program individually to regen files, blow everything away and start clean using autoreconf -f -i. We apply our patch to ylwrap once we are done. This is because different versions of libtool don't interoperate well.
+ recognize a few more nfs flags; specifically noacl amongst others.
+ add a bit of debugging for the mount port
+ recognize the mountport= that specifies an explicit port to contact for mountd, instead of resolving it via RPC.
+ mention Makefile change
+ add ops_nfs4.c
+ - add handling for noatime,nodiratime,mandlock for linux - add locking keyword support for lustre
+ fixed bugs parsing lustre mount strings.
+ mention sun map change
+ disable sun maps to avoid segmentation fault.
+ * updated ypwrap bootfile patch
+
+ -- Christian Montanari <cp.montan...@tiscali.co.uk> Sun, 27 Oct 2013 13:10:02 +0000
+
am-utils (6.2+rc20110530-3) unstable; urgency=low
* Fixed missing build dependency on dpkg-dev
diff --git a/debian/control b/debian/control
index 2a74ff1..5aa88c0 100644
--- a/debian/control
+++ b/debian/control
@@ -2,7 +2,7 @@ Source: am-utils
Section: net
Priority: extra
Maintainer: Tim Cutts <t...@chiark.greenend.org.uk>
-Build-Depends: debhelper (>= 7.0.0), bison, flex, texlive, texi2html (>= 1.76), texinfo, libgdbm-dev, libwrap0-dev, libhesiod-dev, libldap2-dev, autotools-dev, linux-kernel-headers, po-debconf, autoconf, automake1.9, quilt, libtool, dpkg-dev (>= 1.16.1~)
+Build-Depends: debhelper (>= 7.0.0), bison, flex, texlive, texi2html (>= 1.76), texinfo, libgdbm-dev, libwrap0-dev, libhesiod-dev, libldap2-dev, autotools-dev, linux-kernel-headers, po-debconf, autoconf, automake, quilt, libtool, dpkg-dev (>= 1.16.1~)
Build-Conflicts: autoconf2.13, automake1.4
Homepage: http://www.am-utils.org/
Standards-Version: 3.9.2
diff --git a/debian/patches/series b/debian/patches/series
index ce8b830..9af8381 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -3,7 +3,7 @@ localconfig-link.patch
mk-amd-map_tmpfile.patch
pawd.patch
localconfig.h.patch
-force-nfs-mount-version-4.patch
+#force-nfs-mount-version-4.patch
use-real-hostname-in-mount-struct.patch
-force-autofs4.patch
-recent_libtool.patch
+#force-autofs4.patch
+#recent_libtool.patch
diff --git a/debian/rules b/debian/rules
index fa3567c..d090d17 100755
--- a/debian/rules
+++ b/debian/rules
@@ -10,7 +10,7 @@
include /usr/share/quilt/quilt.make
# Uncomment this to turn on verbose mode.
-#export DH_VERBOSE=1
+export DH_VERBOSE=1
# This has to be exported to make some magic below work.
export DH_OPTIONS
>From f51880a4d88a5a49aae5fd7297831dc7b4c62818 Mon Sep 17 00:00:00 2001
From: Christian Montanari <cp.montan...@tiscali.co.uk>
Date: Mon, 28 Oct 2013 06:55:02 +0000
Subject: [PATCH] compiled for debian package 6.2+rc20130922-1.
---
.gitignore | 209 +
INSTALL | 2 +-
amd/amd.h | 2 +-
amd/autil.c | 4 +-
amd/get_args.c | 4 +-
amd/sun2amd.8 | 2 +-
amd/sun_map_parse.y | 2 +-
amq/pawd.c | 2 +-
bootstrap | 44 +-
buildall | 8 +
config.guess | 1502 -------
config.sub | 1708 --------
configure.ac | 4 +
debian/changelog | 25 +
debian/control | 2 +-
debian/patches/series | 6 +-
debian/rules | 2 +-
depcomp | 780 ----
doc/Makefile.am | 2 +-
doc/mdate-sh | 224 --
doc/texinfo.tex | 10062 ----------------------------------------------
install-sh | 301 --
ltmain.sh | 8410 --------------------------------------
m4/macros/libtool.m4 | 7357 ---------------------------------
missing | 330 --
mk-amd-map/mk-amd-map.c | 56 +-
ylwrap | 240 --
27 files changed, 320 insertions(+), 30970 deletions(-)
create mode 100644 .gitignore
delete mode 100755 config.guess
delete mode 100755 config.sub
delete mode 100755 depcomp
delete mode 100755 doc/mdate-sh
delete mode 100644 doc/texinfo.tex
delete mode 100755 install-sh
delete mode 100755 ltmain.sh
delete mode 100644 m4/macros/libtool.m4
delete mode 100755 missing
delete mode 100755 ylwrap
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..fc9a626
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,209 @@
+*~
+*.old
+*.orig
+*.rej
+
+/debian
+/.pc
+/m4
+
+
+config.guess
+config.sub
+depcomp
+doc/mdate-sh
+doc/texinfo.tex
+install-sh
+ltmain.sh
+m4/macros/libtool.m4
+missing
+
+build-stamp
+compile
+doc/am-utils.info
+doc/am-utils.info-1
+doc/am-utils.info-2
+doc/version.texi
+localconfig.h
+test-driver
+ylwrap
+
+#from .cvsignore
+2be-mirror.txt
+A.alpha-dec-osf2.1
+A.alpha-dec-osf4.0
+A.alphaev5-unknown-linux-gnu-rh5.2
+A.hppa1.1-hp-hpux10.10
+A.hppa1.1-hp-hpux10.20
+A.hppa1.1-hp-hpux11.00
+A.hppa1.1-hp-hpux9.01
+A.hppa1.1-hp-hpux9.05
+A.hppa1.1-hp-hpux9.07
+A.i386-apple-darwin6.0
+A.i386-pc-bsdi2.1
+A.i386-pc-bsdi3.1
+A.i386-pc-bsdi4.1
+A.i386-pc-solaris2.5.1
+A.i386-pc-solaris2.6
+A.i386-pc-solaris2.7
+A.i386-unknown-freebsd2.2.7
+A.i386-unknown-freebsd2.2.8
+A.i386-unknown-freebsdelf3.2
+A.i386-unknown-freebsdelf3.3
+A.i386-unknown-freebsdelf4.0
+A.i386-unknown-netbsd1.3.3
+A.i386-unknown-netbsd1.4.1
+A.i386-unknown-openbsd2.5
+A.i486-ncr-sysv4.3.03
+A.i486-pc-linux-gnu-rh6.0
+A.i486-pc-linux-gnulibc1
+A.i486-pc-linux-gnulibc1-rh4.2
+A.i586-pc-linux-gnu-rh5.2
+A.i586-pc-linux-gnu-rh6.0
+A.i586-pc-linux-gnu-rh6.1
+A.i586-pc-linux-gnu-rh6.1.92
+A.i586-pc-linux-gnulibc1
+A.i586-pc-linux-gnulibc1-rh4.2
+A.i686-pc-linux-gnu-rh5.2
+A.i686-pc-linux-gnu-rh6.0
+A.i686-pc-linux-gnu-rh6.1
+A.m68k-next-nextstep3
+A.m68k-sun-sunos4.1.1
+A.mips-sgi-irix5.3
+A.mips-sgi-irix6.2
+A.mips-sgi-irix6.4
+A.mips-sgi-irix6.5
+A.powerpc-ibm-aix4.1.5.0
+A.powerpc-ibm-aix4.2.1.0
+A.powerpc-ibm-aix4.3.1.0
+A.rs6000-ibm-aix4.1.4.0
+A.rs6000-ibm-aix4.1.5.0
+A.sparc-sun-solaris2.3
+A.sparc-sun-solaris2.5
+A.sparc-sun-solaris2.5.1
+A.sparc-sun-solaris2.6
+A.sparc-sun-solaris2.7
+A.sparc-sun-sunos4.1.3
+A.sparc-sun-sunos4.1.3C
+A.sparc-sun-sunos4.1.3_U1
+A.sparc-sun-sunos4.1.4
+A.sparc-unknown-linux-gnulibc1-rh4.2
+A.sparc64-unknown-linux-gnu-rh5.2
+Makefile.in
+OLD
+ORIG
+configure
+diffs.txt
+reply-to
+signature
+tmp
+tutorial.txt
+A.i686-pc-linux-gnu-rh6.1.92
+A.i686-pc-linux-gnu-rh6.2
+A.i386-unknown-freebsdelf3.4
+A.i586-pc-linux-gnu-rh6.2
+acinclude.m4
+aclocal.m4
+config.h.in
+stamp-h.in
+A.i386-pc-linux-rh6.1
+A.sparc64-unknown-linux-rh6.2
+A.i386-pc-linux-rh6.2
+A.i386-pc-linux-rh7.0
+A.i386-pc-linux-rh7.1
+buildall.log
+autom4te.cache
+A.sparc-sun-solaris2.8
+A.ia64-unknown-linux-rh7.1
+A.ia64-hp-hpux11.20
+A.i386-unknown-freebsd4.4
+A.i386-unknown-netbsdelf1.5.1
+A.i386-pc-bsdi4.2
+A.i386-pc-linux-rh7.2
+A.i386-unknown-freebsd5.0
+A.i386-pc-linuxlibc1-rh4.2
+A.i386-pc-solaris2.8
+A.i386-unknown-freebsd4.5
+A.i386-unknown-openbsd2.9
+A.i386-pc-linux-rh7.3
+A.i386-unknown-freebsd4.6
+A.sparc64-unknown-linux-suse7.3
+A.ia64-unknown-linux-rh2.1AW
+A.sparc-sun-solaris2.9
+A.i386-pc-linux-rh8.0
+autom4te-2.53.cache
+A.powerpc-ibm-aix5.1.0.0
+A.ia64-unknown-linux-rh2.1AS
+A.ia64-unknown-linux-rh7.2
+A.i386-unknown-freebsd4.7
+A.i386-pc-linux-rh9
+A.powerpc-ibm-aix5.2.0.0
+A.i386-unknown-netbsdelf1.6.1
+A.i386-unknown-openbsd3.3
+A.i386-pc-solaris2.9
+A.i386-unknown-freebsd5.1
+A.i686-apple-darwin6.6
+A.i386-unknown-freebsd4.8
+A.x86_64-unknown-linux-rh2.9.5AS
+A.mipsel-unknown-linux-rhPS2
+A.i386-unknown-freebsd4.9
+A.i386-unknown-freebsd5.2
+A.sparc64-unknown-linux-deb3.0
+A.i386-unknown-freebsd5.2.1
+A.i386-pc-linux-suse9.1
+A.i386-unknown-freebsd4.10
+A.i386-pc-linux-suse8.2
+A.i386-pc-linux-fc2
+A.i386-pc-linux-fc3
+A.i386-pc-solaris2.10
+A.i386-unknown-freebsd4.11
+A.i386-unknown-freebsd5.3
+A.i386-unknown-netbsdelf1.6.2
+A.i386-unknown-netbsdelf2.0
+A.i386-unknown-openbsd3.6
+A.powerpc-apple-darwin7.6.0
+A.powerpc-ibm-aix5.3.0.0
+A.powerpc-ibm-aix5.3.0.0-cc
+A.i386-pc-linux-rhel3
+A.powerpc-apple-darwin7.7.0
+A.powerpc-apple-darwin7.8.0
+A.i386-unknown-freebsd6.0
+A.ia64-unknown-linux-rhel4
+A.i386-pc-linux-rhel4
+A.sparc-sun-solaris2.10
+A.powerpc64-unknown-linux-rhel4
+A.powerpc64-unknown-linux-sles9
+A.powerpc-apple-darwin7.9.0
+A.i386-pc-linux-suse9.2
+A.i386-unknown-freebsd5.4
+A.i386-pc-linux-gentoo1.4.16
+A.powerpc-unknown-linux-yellowdog2.3
+A.i386-unknown-netbsdelf2.0.2
+A.i386-unknown-openbsd3.7
+A.i386-pc-linux-deb3.0
+A.alpha-unknown-linux-gentoo1.4.16
+A.alphaev56-dec-osf4.0f
+A.mips-unknown-linux-gentoo1.4.16
+A.sparc64-unknown-linux-gentoo1.4.16
+A.i386-pc-linux-fc4
+A.i386-pc-linux-suse9.3
+A.i386-pc-linuxoldld-deb3.1
+A.i386-pc-linux-deb3.1
+A.powerpc-apple-darwin8.2.0
+A.i386-unknown-netbsdelf3.0
+A.i386-unknown-netbsdelf2.1
+A.i386-unknown-openbsd3.8
+A.powerpc-ibm-aix5.2.0.0-cc
+A.i386-pc-linux-fc5
+A.i386-pc-linux-suse10.1
+A.powerpc-apple-darwin8.5.0
+A.powerpc-apple-darwin8.6.0
+A.i386-unknown-freebsd6.1
+A.i386-unknown-openbsd3.9
+A.i386-pc-solaris2.11-nexentaos
+A.i386-pc-linux-centos4.4
+A.powerpc-apple-darwin8.7.0
+A.i386-pc-linux-fc6
+A.i386-apple-darwin8.8.1
+A.ia64-hp-hpux11.23
+A.x86_64-unknown-linux-deb
diff --git a/INSTALL b/INSTALL
index 6e90e07..007e939 100644
--- a/INSTALL
+++ b/INSTALL
@@ -1,7 +1,7 @@
Installation Instructions
*************************
-Copyright (C) 1994-1996, 1999-2002, 2004-2012 Free Software Foundation,
+Copyright (C) 1994-1996, 1999-2002, 2004-2013 Free Software Foundation,
Inc.
Copying and distribution of this file, with or without modification,
diff --git a/amd/amd.h b/amd/amd.h
index 5de090b..96f268a 100644
--- a/amd/amd.h
+++ b/amd/amd.h
@@ -561,7 +561,7 @@ extern int set_conf_kv(const char *section, const char *k, const char *v);
extern int mount_node(opaque_t arg);
extern int unmount_mp(am_node *mp);
extern int conf_parse(void); /* "yyparse" renamed */
-extern FILE *conf_in; /* "yyin" renamed */
+extern FILE *conf_yyin; /* "yyin" renamed */
extern void amfs_mkcacheref(mntfs *mf);
extern int amfs_mount(am_node *mp, mntfs *mf, char *opts);
diff --git a/amd/autil.c b/amd/autil.c
index b4e60f0..5990c21 100644
--- a/amd/autil.c
+++ b/amd/autil.c
@@ -494,8 +494,8 @@ amfs_mount(am_node *mp, mntfs *mf, char *opts)
/*
* Make a ``hostname'' string for the kernel
*/
- xsnprintf(fs_hostname, sizeof(fs_hostname), "pid%ld@%s:%s",
- get_server_pid(), am_get_hostname(), dir);
+ xsnprintf(fs_hostname, sizeof(fs_hostname), "%s",
+ am_get_hostname());
/*
* Most kernels have a name length restriction (64 bytes)...
*/
diff --git a/amd/get_args.c b/amd/get_args.c
index a584386..f23b967 100644
--- a/amd/get_args.c
+++ b/amd/get_args.c
@@ -331,8 +331,8 @@ get_args(int argc, char *argv[])
perror(buf);
exit(1);
}
- conf_in = fp;
- conf_parse();
+ conf_yyin = fp;
+ conf_yyparse();
fclose(fp);
if (process_all_regular_maps() != 0)
exit(1);
diff --git a/amd/sun2amd.8 b/amd/sun2amd.8
index aa5dd6e..c005ab3 100644
--- a/amd/sun2amd.8
+++ b/amd/sun2amd.8
@@ -40,7 +40,7 @@
.\"
.\" File: am-utils/amd/sun2amd.8
.\"
-.TH SUN2AMD 8L "14 August 2005"
+.TH SUN2AMD 8 "14 August 2005"
.SH NAME
sun2amd \- converts Sun automount maps to Amd maps
diff --git a/amd/sun_map_parse.y b/amd/sun_map_parse.y
index d7d3b2a..c62af00 100644
--- a/amd/sun_map_parse.y
+++ b/amd/sun_map_parse.y
@@ -431,7 +431,7 @@ sun_map_parse_read(const char *map_data)
sun_map_tok_setbuff(map_data);
/* call yacc */
- sun_map_parse();
+ yyparse();
if (sun_entry_list != NULL) {
/* return the first Sun entry in the list */
diff --git a/amq/pawd.c b/amq/pawd.c
index aae501b..cd779e9 100644
--- a/amq/pawd.c
+++ b/amq/pawd.c
@@ -246,7 +246,7 @@ main(int argc, char *argv[])
if (argc == 1) {
wd = getawd(tmp_buf, sizeof(tmp_buf));
if (wd == NULL) {
- fprintf(stderr, "pawd: %s\n", tmp_buf);
+ perror("pawd");
exit(1);
} else {
fprintf(stdout, "%s\n", wd);
diff --git a/bootstrap b/bootstrap
index e614ff6..7d9be99 100755
--- a/bootstrap
+++ b/bootstrap
@@ -50,31 +50,33 @@ fi
echo "AMU: Fixing ylwrap..."
patch << \EOF
---- ylwrap.orig 2013-05-14 20:00:39.000000000 -0400
-+++ ylwrap 2013-05-14 20:06:06.000000000 -0400
-@@ -199,8 +199,24 @@
+--- ylwrap.orig 2013-10-27 07:30:32.000000000 +0000
++++ ylwrap 2013-10-27 07:34:26.000000000 +0000
+@@ -203,11 +203,26 @@
+ # debug information point at an absolute srcdir. Use the real
+ # output file name, not yy.lex.c for instance. Adjust the
# include guards too.
- FROM=`guard "$from"`
- TARGET=`guard "$to"`
++
++ code_prefix=`echo $input \
++ | sed -e 's,^.*/,,g;s/_\(parse\|tok\)\.[yl]$/_/g'`
+
-+ prefix=`echo $input | sed \
-+ -e 's,^.*/,,g' \
-+ -e 's/_parse.[yl]$/_/g' \
-+ -e 's/_tok.[yl]$/_/g'`
-+
-+ case $prefix in
-+ *.y)
-+ code_prefix="$(basename $prefix _gram.y)_yy";;
-+ *.l)
-+ code_prefix="$(basename $prefix _lex.l)_yy";;
-+ *)
-+ code_prefix="$prefix";;
++ case $code_prefix in
++ *.y)
++ code_prefix="$(basename $code_prefix _gram.y)_yy";;
++ *.l)
++ code_prefix="$(basename $code_prefix _lex.l)_yy";;
++ *)
++ code_prefix="${code_prefix}yy";;
+ esac
+
- sed -e "/^#/!b" -e "s|$input_rx|$input_sub_rx|" -e "$rename_sed" \
-- -e "s|$FROM|$TARGET|" "$from" >"$target" || ret=$?
-+ -e "s|$FROM|$TARGET|" "$from" | sed -e "s|yy|$code_prefix|g" > \
-+ "$target" || ret=$?
+ sed -e "/^#/!b" \
+ -e "s|$input_rx|$input_sub_rx|" \
+ -e "$sed_fix_filenames" \
+ -e "$sed_fix_header_guards" \
+- "$from" >"$target" || ret=$?
++ "$from" \
++ | sed -e "s|yy|${code_prefix}|g" \
++ >"$target" || ret=$?
# Check whether files must be updated.
if test "$from" != "$parser"; then
diff --git a/buildall b/buildall
index f5aaf3a..33e28a5 100755
--- a/buildall
+++ b/buildall
@@ -276,6 +276,14 @@ echo cd ./A.${host_alias}
cd ./A.${host_alias} || exit 1
##############################################################################
+# create a link to the localconfig.h file, if needed
+if test -e ../localconfig.h; then
+ if test ! -e localconfig.h; then
+ ln -s ../localconfig.h localconfig.h || exit 1
+ fi
+fi
+
+##############################################################################
# this is for developers only (remove config.cache entries)
if test -n "$pat"; then
if test -f config.cache; then
diff --git a/config.guess b/config.guess
deleted file mode 100755
index c2246a4..0000000
diff --git a/config.sub b/config.sub
deleted file mode 100755
index 8518609..0000000
diff --git a/configure.ac b/configure.ac
index 9dcaa09..2c671a6 100644
--- a/configure.ac
+++ b/configure.ac
@@ -65,6 +65,10 @@ AC_CANONICAL_HOST
AMU_HOST_MACROS
dnl ======================================================================
+dnl Need to initialise libtool properly
+AC_USE_SYSTEM_EXTENSIONS
+LT_INIT
+
dnl ######################################################################
dnl PACKAGE NAME AND VERSION
AC_MSG_NOTICE(*** PACKAGE NAME AND VERSION ***)
diff --git a/debian/changelog b/debian/changelog
index 285506a..af8f67e 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,28 @@
+am-utils (6.2+rc20130922-1) unstable; urgency=low
+
+ * Merge master of git://git.fsl.cs.sunysb.edu/am-utils-6.2.git
+ fix flaw when kernel version is 3.x
+ update copyright notice for 2013
+ Regen, and recent changes
+ adjust to new autoconf requirements
+ INCLUDES -> AM_CPPFLAGS in new autoconf
+ Fix macro names
+ Regen from newer autoconf
+ recognize noacl
+ Instead of calling each autoconf program individually to regen files, blow everything away and start clean using autoreconf -f -i. We apply our patch to ylwrap once we are done. This is because different versions of libtool don't interoperate well.
+ recognize a few more nfs flags; specifically noacl amongst others.
+ add a bit of debugging for the mount port
+ recognize the mountport= that specifies an explicit port to contact for mountd, instead of resolving it via RPC.
+ mention Makefile change
+ add ops_nfs4.c
+ - add handling for noatime,nodiratime,mandlock for linux - add locking keyword support for lustre
+ fixed bugs parsing lustre mount strings.
+ mention sun map change
+ disable sun maps to avoid segmentation fault.
+ * updated ypwrap bootfile patch
+
+ -- Christian Montanari <cp.montan...@tiscali.co.uk> Sun, 27 Oct 2013 13:10:02 +0000
+
am-utils (6.2+rc20110530-3) unstable; urgency=low
* Fixed missing build dependency on dpkg-dev
diff --git a/debian/control b/debian/control
index 2a74ff1..5aa88c0 100644
--- a/debian/control
+++ b/debian/control
@@ -2,7 +2,7 @@ Source: am-utils
Section: net
Priority: extra
Maintainer: Tim Cutts <t...@chiark.greenend.org.uk>
-Build-Depends: debhelper (>= 7.0.0), bison, flex, texlive, texi2html (>= 1.76), texinfo, libgdbm-dev, libwrap0-dev, libhesiod-dev, libldap2-dev, autotools-dev, linux-kernel-headers, po-debconf, autoconf, automake1.9, quilt, libtool, dpkg-dev (>= 1.16.1~)
+Build-Depends: debhelper (>= 7.0.0), bison, flex, texlive, texi2html (>= 1.76), texinfo, libgdbm-dev, libwrap0-dev, libhesiod-dev, libldap2-dev, autotools-dev, linux-kernel-headers, po-debconf, autoconf, automake, quilt, libtool, dpkg-dev (>= 1.16.1~)
Build-Conflicts: autoconf2.13, automake1.4
Homepage: http://www.am-utils.org/
Standards-Version: 3.9.2
diff --git a/debian/patches/series b/debian/patches/series
index ce8b830..9af8381 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -3,7 +3,7 @@ localconfig-link.patch
mk-amd-map_tmpfile.patch
pawd.patch
localconfig.h.patch
-force-nfs-mount-version-4.patch
+#force-nfs-mount-version-4.patch
use-real-hostname-in-mount-struct.patch
-force-autofs4.patch
-recent_libtool.patch
+#force-autofs4.patch
+#recent_libtool.patch
diff --git a/debian/rules b/debian/rules
index fa3567c..d090d17 100755
--- a/debian/rules
+++ b/debian/rules
@@ -10,7 +10,7 @@
include /usr/share/quilt/quilt.make
# Uncomment this to turn on verbose mode.
-#export DH_VERBOSE=1
+export DH_VERBOSE=1
# This has to be exported to make some magic below work.
export DH_OPTIONS
diff --git a/depcomp b/depcomp
deleted file mode 100755
index 0544c68..0000000
diff --git a/doc/Makefile.am b/doc/Makefile.am
index 2ea1b45..6e1e6b6 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -15,7 +15,7 @@ EXTRA_DIST = hlfsd.ps
DVIPS = dvips -t letter -Pcmz
# Force version.texi to be rebuilt regardless of maintainer mode
-$(srcdir)/version.texi: am-utils.texi $(top_srcdir)/configure.in
+$(srcdir)/version.texi: am-utils.texi $(top_srcdir)/configure.ac
@(set `$(SHELL) $(srcdir)/mdate-sh $(srcdir)/am-utils.texi`; \
echo "@set UPDATED $$1 $$2 $$3"; \
echo "@set UPDATED-MONTH $$2 $$3"; \
diff --git a/doc/mdate-sh b/doc/mdate-sh
deleted file mode 100755
index 4614441..0000000
diff --git a/doc/texinfo.tex b/doc/texinfo.tex
deleted file mode 100644
index f458ba7..0000000
diff --git a/install-sh b/install-sh
deleted file mode 100755
index b12c0f7..0000000
diff --git a/ltmain.sh b/ltmain.sh
deleted file mode 100755
index c3098b5..0000000
diff --git a/m4/macros/libtool.m4 b/m4/macros/libtool.m4
deleted file mode 100644
index 39ba996..0000000
diff --git a/missing b/missing
deleted file mode 100755
index 9a55648..0000000
diff --git a/mk-amd-map/mk-amd-map.c b/mk-amd-map/mk-amd-map.c
index 73a02ef..1d93dff 100644
--- a/mk-amd-map/mk-amd-map.c
+++ b/mk-amd-map/mk-amd-map.c
@@ -212,6 +212,7 @@ main(int argc, char *argv[])
{
FILE *mapf; /* the input file to read from */
int error;
+ int exit_status = 0;
char *mapsrc;
DBM *db = NULL;
static char maptmp[] = "dbmXXXXXX";
@@ -242,7 +243,8 @@ main(int argc, char *argv[])
if (usage || optind != (argc - 1)) {
fputs("Usage: mk-amd-map [-p] file-map\n", stderr);
- exit(1);
+ exit_status = 1;
+ goto do_exit;
}
mapsrc = argv[optind];
@@ -253,7 +255,8 @@ main(int argc, char *argv[])
if (chdir(mapsrc) < 0) {
fputs("Can't chdir to ", stderr);
perror(mapsrc);
- exit(1);
+ exit_status = 1;
+ goto do_exit;
}
mapsrc = sl + 1;
}
@@ -263,7 +266,8 @@ main(int argc, char *argv[])
if (!mapf) {
fprintf(stderr, "cannot open source file ");
perror(mapsrc);
- exit(1);
+ exit_status = 1;
+ goto do_exit;
}
#ifndef DEBUG
@@ -283,7 +287,8 @@ main(int argc, char *argv[])
#endif /* not HAVE_DB_SUFFIX */
if (error) {
perror("mk-amd-map: malloc");
- exit(1);
+ exit_status = 1;
+ goto do_exit;
}
#ifdef HAVE_MKSTEMP
@@ -309,7 +314,8 @@ main(int argc, char *argv[])
if (remove_file(maptdb) < 0) {
fprintf(stderr, "Can't remove existing temporary file; ");
perror(maptdb);
- exit(1);
+ exit_status = 1;
+ goto cleanup_tmp_files;
}
#else /* not HAVE_DB_SUFFIX */
xsnprintf(maptpag, sizeof(maptpag), "%s.pag", maptmp);
@@ -317,14 +323,16 @@ main(int argc, char *argv[])
if (remove_file(maptpag) < 0 || remove_file(maptdir) < 0) {
fprintf(stderr, "Can't remove existing temporary files; %s and ", maptpag);
perror(maptdir);
- exit(1);
+ exit_status = 1;
+ goto cleanup_tmp_files;
}
#endif /* not HAVE_DB_SUFFIX */
db = dbm_open(maptmp, O_RDWR|O_CREAT|O_EXCL, 0444);
if (!db) {
fprintf(stderr, "cannot initialize temporary database: %s", maptmp);
- exit(1);
+ exit_status = 1;
+ goto cleanup_tmp_files;
}
}
@@ -336,11 +344,12 @@ main(int argc, char *argv[])
fprintf(stderr, "Error reading source file %s\n", mapsrc);
else
fprintf(stderr, "Error creating database map for %s\n", mapsrc);
- exit(1);
+ exit_status = 1;
+ goto cleanup_tmp_files;
}
if (printit)
- exit(0); /* nothing more to do */
+ goto cleanup_tmp_files; /* nothing more to do */
/* if gets here, we wrote to a database */
@@ -353,9 +362,8 @@ main(int argc, char *argv[])
if (rename(maptdb, map_name_db) < 0) {
fprintf(stderr, "Couldn't rename %s to ", maptdb);
perror(map_name_db);
- /* Throw away the temporary map */
- unlink(maptdb);
- exit(1);
+ exit_status = 1;
+ goto cleanup_tmp_files;
}
#else /* not HAVE_DB_SUFFIX */
/* sizeof(map_name_{pag,dir}) are malloc'ed above */
@@ -364,10 +372,8 @@ main(int argc, char *argv[])
if (rename(maptpag, map_name_pag) < 0) {
fprintf(stderr, "Couldn't rename %s to ", maptpag);
perror(map_name_pag);
- /* Throw away the temporary map */
- unlink(maptpag);
- unlink(maptdir);
- exit(1);
+ exit_status = 1;
+ goto cleanup_tmp_files;
}
if (rename(maptdir, map_name_dir) < 0) {
fprintf(stderr, "Couldn't rename %s to ", maptdir);
@@ -376,15 +382,25 @@ main(int argc, char *argv[])
unlink(map_name_pag);
/* throw away remaining part of original map */
unlink(map_name_dir);
- /* throw away the temporary map */
- unlink(maptdir);
fprintf(stderr, "WARNING: existing map \"%s.{dir,pag}\" destroyed\n",
mapsrc);
- exit(1);
+ exit_status = 1;
+ goto cleanup_tmp_files;
}
#endif /* not HAVE_DB_SUFFIX */
- exit(0);
+ cleanup_tmp_files:
+ /* Unlink temporary files, ignoring any errors */
+ unlink(maptmp);
+#ifdef HAVE_DB_SUFFIX
+ unlink(maptdb);
+#else /* not HAVE_DB_SUFFIX */
+ unlink(maptpag);
+ unlink(maptdir);
+#endif /* not HAVE_DB_SUFFIX */
+
+ do_exit:
+ exit(exit_status);
}
#else /* not HAVE_MAP_NDBM */
diff --git a/ylwrap b/ylwrap
deleted file mode 100755
index 7befa46..0000000