aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTheodore Ts'o <tytso@mit.edu>2002-06-25 23:26:34 -0400
committerTheodore Ts'o <tytso@mit.edu>2002-06-25 23:26:34 -0400
commit8fdc9985c1e2a4467630b33719b7feb281b7b33b (patch)
tree62568b09c49c9df3d49fe5e3cec0f6b6b446695e
parent88372d5c4b2ebd0405446b42de65bf2b0ebb2408 (diff)
downloade2fsprogs-8fdc9985c1e2a4467630b33719b7feb281b7b33b.tar.gz
e2fsprogs-8fdc9985c1e2a4467630b33719b7feb281b7b33b.tar.xz
e2fsprogs-8fdc9985c1e2a4467630b33719b7feb281b7b33b.zip
Add initial support for htree directories.
-rw-r--r--ChangeLog6
-rw-r--r--configure435
-rw-r--r--configure.in39
-rw-r--r--e2fsck/ChangeLog27
-rw-r--r--e2fsck/Makefile.in14
-rw-r--r--e2fsck/dx_dirinfo.c150
-rw-r--r--e2fsck/e2fsck.c3
-rw-r--r--e2fsck/e2fsck.h49
-rw-r--r--e2fsck/message.c4
-rw-r--r--e2fsck/pass1.c16
-rw-r--r--e2fsck/pass2.c256
-rw-r--r--e2fsck/problem.c39
-rw-r--r--e2fsck/problem.h24
-rw-r--r--e2fsck/unix.c11
-rw-r--r--tests/ChangeLog9
-rw-r--r--tests/Makefile.in2
-rw-r--r--tests/f_h_badnode/expect.116
-rw-r--r--tests/f_h_badnode/expect.27
-rw-r--r--tests/f_h_badnode/image.gzbin0 -> 467065 bytes
-rw-r--r--tests/f_h_badnode/name1
-rw-r--r--tests/f_h_badnode/script6
-rw-r--r--tests/f_h_normal/expect.17
-rw-r--r--tests/f_h_normal/expect.27
-rw-r--r--tests/f_h_normal/image.gzbin0 -> 466817 bytes
-rw-r--r--tests/f_h_normal/name1
-rw-r--r--tests/f_h_normal/script6
-rw-r--r--tests/f_h_normal/script~3
27 files changed, 936 insertions, 202 deletions
diff --git a/ChangeLog b/ChangeLog
index 9506d932..1fc70bb0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,8 @@
-2002-05-24 <tytso@snap.thunk.org>
+2002-06-25 Theodore Ts'o <tytso@mit.edu>
+
+ * configure.in, configure: Add --enable-htree and --enable-clear-htree
+
+2002-05-24 Theodore Ts'o <tytso@mit.edu>
* configure.in: Add makefile for lib/evms for the EVMS FSIM
plugin. Add --enable-old-evms configure option which uses
diff --git a/configure b/configure
index 57d13488..59708787 100644
--- a/configure
+++ b/configure
@@ -24,6 +24,10 @@ ac_help="$ac_help
ac_help="$ac_help
--enable-compression enable EXPERIMENTAL compression support"
ac_help="$ac_help
+ --enable-htree enable EXPERIMENTAL htree directory support"
+ac_help="$ac_help
+ --enable-htree-clear clear htree because we don't trust e2fsck"
+ac_help="$ac_help
--enable-old-evms use EVMS 1.0 ABI (instead of EVMS 1.1)"
ac_help="$ac_help
--enable-dll-shlibs select DLL libraries"
@@ -634,7 +638,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:638: checking host system type" >&5
+echo "configure:642: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -668,7 +672,7 @@ export CC
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:672: checking for $ac_word" >&5
+echo "configure:676: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -698,7 +702,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:702: checking for $ac_word" >&5
+echo "configure:706: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -749,7 +753,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:753: checking for $ac_word" >&5
+echo "configure:757: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -781,7 +785,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:785: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:789: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -792,12 +796,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 796 "configure"
+#line 800 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:801: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:805: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -823,12 +827,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:827: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:831: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:832: checking whether we are using GNU C" >&5
+echo "configure:836: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -837,7 +841,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:841: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:845: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -856,7 +860,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:860: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:864: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -905,7 +909,7 @@ if test "${with_ccopts+set}" = set; then
CFLAGS=$withval
fi
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:909: checking how to run the C preprocessor" >&5
+echo "configure:913: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
@@ -920,13 +924,13 @@ else
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 924 "configure"
+#line 928 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:930: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:934: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -937,13 +941,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 941 "configure"
+#line 945 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:947: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:951: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -954,13 +958,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 958 "configure"
+#line 962 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:964: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:968: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -986,17 +990,17 @@ echo "$ac_t""$CPP" 1>&6
ac_safe=`echo "linux/fs.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for linux/fs.h""... $ac_c" 1>&6
-echo "configure:990: checking for linux/fs.h" >&5
+echo "configure:994: checking for linux/fs.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 995 "configure"
+#line 999 "configure"
#include "confdefs.h"
#include <linux/fs.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1000: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1004: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -1061,6 +1065,53 @@ else
fi
+# Check whether --enable-htree or --disable-htree was given.
+if test "${enable_htree+set}" = set; then
+ enableval="$enable_htree"
+ if test "$enableval" = "no"
+then
+ HTREE_CMT=#
+ echo "Disabling htree directory support"
+else
+ HTREE_CMT=
+ cat >> confdefs.h <<\EOF
+#define ENABLE_HTREE 1
+EOF
+
+ echo "Enabling htree directory support"
+ echo "WARNING: htree support is experimental"
+fi
+
+else
+ HTREE_CMT=#
+echo "Disabling htree directory support by default"
+
+fi
+
+
+# Check whether --enable-htree-clear or --disable-htree-clear was given.
+if test "${enable_htree_clear+set}" = set; then
+ enableval="$enable_htree_clear"
+ if test "$enableval" = "no"
+then
+ HTREE_CLR_CMT=#
+ echo "Disabling htree clearing"
+else
+ HTREE_CLR_CMT=
+ cat >> confdefs.h <<\EOF
+#define ENABLE_HTREE_CLEAR 1
+EOF
+
+ echo "Enabling htree clearing"
+fi
+
+else
+ HTREE_CLR_CMT=#
+echo "Disabling htree clearing by default"
+
+fi
+
+
# Check whether --enable-old-evms or --disable-old-evms was given.
if test "${enable_old_evms+set}" = set; then
enableval="$enable_old_evms"
@@ -1391,7 +1442,7 @@ EOF
ALL_LINGUAS="it nyc tr"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:1395: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:1446: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1420,7 +1471,7 @@ fi
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1424: checking for $ac_word" >&5
+echo "configure:1475: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1448,7 +1499,7 @@ else
fi
echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:1452: checking for POSIXized ISC" >&5
+echo "configure:1503: checking for POSIXized ISC" >&5
if test -d /etc/conf/kconfig.d &&
grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
then
@@ -1469,12 +1520,12 @@ else
fi
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:1473: checking for ANSI C header files" >&5
+echo "configure:1524: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1478 "configure"
+#line 1529 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
@@ -1482,7 +1533,7 @@ else
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1486: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1537: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -1499,7 +1550,7 @@ rm -f conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 1503 "configure"
+#line 1554 "configure"
#include "confdefs.h"
#include <string.h>
EOF
@@ -1517,7 +1568,7 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 1521 "configure"
+#line 1572 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
@@ -1538,7 +1589,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
-#line 1542 "configure"
+#line 1593 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -1549,7 +1600,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
exit (0); }
EOF
-if { (eval echo configure:1553: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1604: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
@@ -1573,12 +1624,12 @@ EOF
fi
echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:1577: checking for working const" >&5
+echo "configure:1628: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1582 "configure"
+#line 1633 "configure"
#include "confdefs.h"
int main() {
@@ -1627,7 +1678,7 @@ ccp = (char const *const *) p;
; return 0; }
EOF
-if { (eval echo configure:1631: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1682: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
@@ -1648,21 +1699,21 @@ EOF
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:1652: checking for inline" >&5
+echo "configure:1703: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
-#line 1659 "configure"
+#line 1710 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
-if { (eval echo configure:1666: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1717: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
@@ -1688,12 +1739,12 @@ EOF
esac
echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:1692: checking for off_t" >&5
+echo "configure:1743: checking for off_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1697 "configure"
+#line 1748 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -1721,12 +1772,12 @@ EOF
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:1725: checking for size_t" >&5
+echo "configure:1776: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1730 "configure"
+#line 1781 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -1756,19 +1807,19 @@ fi
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:1760: checking for working alloca.h" >&5
+echo "configure:1811: checking for working alloca.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1765 "configure"
+#line 1816 "configure"
#include "confdefs.h"
#include <alloca.h>
int main() {
char *p = alloca(2 * sizeof(int));
; return 0; }
EOF
-if { (eval echo configure:1772: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1823: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_header_alloca_h=yes
else
@@ -1789,12 +1840,12 @@ EOF
fi
echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:1793: checking for alloca" >&5
+echo "configure:1844: checking for alloca" >&5
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1798 "configure"
+#line 1849 "configure"
#include "confdefs.h"
#ifdef __GNUC__
@@ -1822,7 +1873,7 @@ int main() {
char *p = (char *) alloca(1);
; return 0; }
EOF
-if { (eval echo configure:1826: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1877: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_func_alloca_works=yes
else
@@ -1854,12 +1905,12 @@ EOF
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:1858: checking whether alloca needs Cray hooks" >&5
+echo "configure:1909: checking whether alloca needs Cray hooks" >&5
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1863 "configure"
+#line 1914 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
@@ -1884,12 +1935,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1888: checking for $ac_func" >&5
+echo "configure:1939: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1893 "configure"
+#line 1944 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -1912,7 +1963,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:1916: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1967: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -1939,7 +1990,7 @@ done
fi
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:1943: checking stack direction for C alloca" >&5
+echo "configure:1994: checking stack direction for C alloca" >&5
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1947,7 +1998,7 @@ else
ac_cv_c_stack_direction=0
else
cat > conftest.$ac_ext <<EOF
-#line 1951 "configure"
+#line 2002 "configure"
#include "confdefs.h"
find_stack_direction ()
{
@@ -1966,7 +2017,7 @@ main ()
exit (find_stack_direction() < 0);
}
EOF
-if { (eval echo configure:1970: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2021: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_stack_direction=1
else
@@ -1991,17 +2042,17 @@ for ac_hdr in unistd.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1995: checking for $ac_hdr" >&5
+echo "configure:2046: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2000 "configure"
+#line 2051 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2005: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2056: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2030,12 +2081,12 @@ done
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2034: checking for $ac_func" >&5
+echo "configure:2085: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2039 "configure"
+#line 2090 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -2058,7 +2109,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:2062: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2113: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -2083,7 +2134,7 @@ fi
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:2087: checking for working mmap" >&5
+echo "configure:2138: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2091,7 +2142,7 @@ else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 2095 "configure"
+#line 2146 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
@@ -2231,7 +2282,7 @@ main()
}
EOF
-if { (eval echo configure:2235: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2286: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
@@ -2259,17 +2310,17 @@ unistd.h sys/param.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2263: checking for $ac_hdr" >&5
+echo "configure:2314: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2268 "configure"
+#line 2319 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2273: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2324: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2299,12 +2350,12 @@ done
strdup __argz_count __argz_stringify __argz_next
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2303: checking for $ac_func" >&5
+echo "configure:2354: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2308 "configure"
+#line 2359 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -2327,7 +2378,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:2331: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2382: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -2356,12 +2407,12 @@ done
for ac_func in stpcpy
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2360: checking for $ac_func" >&5
+echo "configure:2411: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2365 "configure"
+#line 2416 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -2384,7 +2435,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:2388: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2439: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -2418,19 +2469,19 @@ EOF
if test $ac_cv_header_locale_h = yes; then
echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:2422: checking for LC_MESSAGES" >&5
+echo "configure:2473: checking for LC_MESSAGES" >&5
if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2427 "configure"
+#line 2478 "configure"
#include "confdefs.h"
#include <locale.h>
int main() {
return LC_MESSAGES
; return 0; }
EOF
-if { (eval echo configure:2434: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2485: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
am_cv_val_LC_MESSAGES=yes
else
@@ -2451,7 +2502,7 @@ EOF
fi
fi
echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:2455: checking whether NLS is requested" >&5
+echo "configure:2506: checking whether NLS is requested" >&5
# Check whether --enable-nls or --disable-nls was given.
if test "${enable_nls+set}" = set; then
enableval="$enable_nls"
@@ -2471,7 +2522,7 @@ fi
EOF
echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:2475: checking whether included gettext is requested" >&5
+echo "configure:2526: checking whether included gettext is requested" >&5
# Check whether --with-included-gettext or --without-included-gettext was given.
if test "${with_included_gettext+set}" = set; then
withval="$with_included_gettext"
@@ -2490,17 +2541,17 @@ fi
ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:2494: checking for libintl.h" >&5
+echo "configure:2545: checking for libintl.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2499 "configure"
+#line 2550 "configure"
#include "confdefs.h"
#include <libintl.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2504: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2555: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2517,19 +2568,19 @@ fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:2521: checking for gettext in libc" >&5
+echo "configure:2572: checking for gettext in libc" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2526 "configure"
+#line 2577 "configure"
#include "confdefs.h"
#include <libintl.h>
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:2533: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2584: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libc=yes
else
@@ -2545,7 +2596,7 @@ echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
if test "$gt_cv_func_gettext_libc" != "yes"; then
echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:2549: checking for bindtextdomain in -lintl" >&5
+echo "configure:2600: checking for bindtextdomain in -lintl" >&5
ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2553,7 +2604,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lintl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2557 "configure"
+#line 2608 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2564,7 +2615,7 @@ int main() {
bindtextdomain()
; return 0; }
EOF
-if { (eval echo configure:2568: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2619: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2580,12 +2631,12 @@ fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:2584: checking for gettext in libintl" >&5
+echo "configure:2635: checking for gettext in libintl" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
echo $ac_n "checking for gettext in -lintl""... $ac_c" 1>&6
-echo "configure:2589: checking for gettext in -lintl" >&5
+echo "configure:2640: checking for gettext in -lintl" >&5
ac_lib_var=`echo intl'_'gettext | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2593,7 +2644,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lintl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2597 "configure"
+#line 2648 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2604,7 +2655,7 @@ int main() {
gettext()
; return 0; }
EOF
-if { (eval echo configure:2608: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2659: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2643,7 +2694,7 @@ EOF
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2647: checking for $ac_word" >&5
+echo "configure:2698: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2677,12 +2728,12 @@ fi
for ac_func in dcgettext
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2681: checking for $ac_func" >&5
+echo "configure:2732: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2686 "configure"
+#line 2737 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -2705,7 +2756,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:2709: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2760: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -2732,7 +2783,7 @@ done
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2736: checking for $ac_word" >&5
+echo "configure:2787: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2768,7 +2819,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2772: checking for $ac_word" >&5
+echo "configure:2823: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2800,7 +2851,7 @@ else
fi
cat > conftest.$ac_ext <<EOF
-#line 2804 "configure"
+#line 2855 "configure"
#include "confdefs.h"
int main() {
@@ -2808,7 +2859,7 @@ extern int _nl_msg_cat_cntr;
return _nl_msg_cat_cntr
; return 0; }
EOF
-if { (eval echo configure:2812: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2863: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
CATOBJEXT=.gmo
DATADIRNAME=share
@@ -2831,7 +2882,7 @@ fi
if test "$CATOBJEXT" = "NONE"; then
echo $ac_n "checking whether catgets can be used""... $ac_c" 1>&6
-echo "configure:2835: checking whether catgets can be used" >&5
+echo "configure:2886: checking whether catgets can be used" >&5
# Check whether --with-catgets or --without-catgets was given.
if test "${with_catgets+set}" = set; then
withval="$with_catgets"
@@ -2844,7 +2895,7 @@ fi
if test "$nls_cv_use_catgets" = "yes"; then
echo $ac_n "checking for main in -li""... $ac_c" 1>&6
-echo "configure:2848: checking for main in -li" >&5
+echo "configure:2899: checking for main in -li" >&5
ac_lib_var=`echo i'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2852,14 +2903,14 @@ else
ac_save_LIBS="$LIBS"
LIBS="-li $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2856 "configure"
+#line 2907 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:2863: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2914: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2887,12 +2938,12 @@ else
fi
echo $ac_n "checking for catgets""... $ac_c" 1>&6
-echo "configure:2891: checking for catgets" >&5
+echo "configure:2942: checking for catgets" >&5
if eval "test \"`echo '$''{'ac_cv_func_catgets'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2896 "configure"
+#line 2947 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char catgets(); below. */
@@ -2915,7 +2966,7 @@ catgets();
; return 0; }
EOF
-if { (eval echo configure:2919: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2970: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_catgets=yes"
else
@@ -2937,7 +2988,7 @@ EOF
# Extract the first word of "gencat", so it can be a program name with args.
set dummy gencat; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2941: checking for $ac_word" >&5
+echo "configure:2992: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GENCAT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2973,7 +3024,7 @@ fi
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2977: checking for $ac_word" >&5
+echo "configure:3028: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3010,7 +3061,7 @@ fi
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3014: checking for $ac_word" >&5
+echo "configure:3065: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3045,7 +3096,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3049: checking for $ac_word" >&5
+echo "configure:3100: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3103,7 +3154,7 @@ fi
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3107: checking for $ac_word" >&5
+echo "configure:3158: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3137,7 +3188,7 @@ fi
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3141: checking for $ac_word" >&5
+echo "configure:3192: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3173,7 +3224,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3177: checking for $ac_word" >&5
+echo "configure:3228: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3266,7 +3317,7 @@ fi
LINGUAS=
else
echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:3270: checking for catalogs to be installed" >&5
+echo "configure:3321: checking for catalogs to be installed" >&5
NEW_LINGUAS=
for lang in ${LINGUAS=$ALL_LINGUAS}; do
case "$ALL_LINGUAS" in
@@ -3294,17 +3345,17 @@ echo "configure:3270: checking for catalogs to be installed" >&5
if test "$CATOBJEXT" = ".cat"; then
ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:3298: checking for linux/version.h" >&5
+echo "configure:3349: checking for linux/version.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3303 "configure"
+#line 3354 "configure"
#include "confdefs.h"
#include <linux/version.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3308: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3359: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3370,7 +3421,7 @@ fi
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:3374: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:3425: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -3399,7 +3450,7 @@ fi
# Extract the first word of "ln", so it can be a program name with args.
set dummy ln; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3403: checking for $ac_word" >&5
+echo "configure:3454: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LN'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3433,7 +3484,7 @@ else
fi
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:3437: checking whether ln -s works" >&5
+echo "configure:3488: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3456,7 +3507,7 @@ fi
# Extract the first word of "mv", so it can be a program name with args.
set dummy mv; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3460: checking for $ac_word" >&5
+echo "configure:3511: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MV'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3492,7 +3543,7 @@ fi
# Extract the first word of "cp", so it can be a program name with args.
set dummy cp; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3496: checking for $ac_word" >&5
+echo "configure:3547: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3528,7 +3579,7 @@ fi
# Extract the first word of "rm", so it can be a program name with args.
set dummy rm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3532: checking for $ac_word" >&5
+echo "configure:3583: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RM'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3564,7 +3615,7 @@ fi
# Extract the first word of "chmod", so it can be a program name with args.
set dummy chmod; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3568: checking for $ac_word" >&5
+echo "configure:3619: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CHMOD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3600,7 +3651,7 @@ fi
# Extract the first word of "awk", so it can be a program name with args.
set dummy awk; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3604: checking for $ac_word" >&5
+echo "configure:3655: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AWK'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3636,7 +3687,7 @@ fi
# Extract the first word of "sed", so it can be a program name with args.
set dummy sed; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3640: checking for $ac_word" >&5
+echo "configure:3691: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SED'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3672,7 +3723,7 @@ fi
# Extract the first word of "perl", so it can be a program name with args.
set dummy perl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3676: checking for $ac_word" >&5
+echo "configure:3727: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3708,7 +3759,7 @@ fi
# Extract the first word of "ldconfig", so it can be a program name with args.
set dummy ldconfig; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3712: checking for $ac_word" >&5
+echo "configure:3763: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LDCONFIG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3742,7 +3793,7 @@ else
fi
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:3746: checking build system type" >&5
+echo "configure:3797: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -3768,7 +3819,7 @@ fi
# Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
set dummy ${ac_tool_prefix}ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3772: checking for $ac_word" >&5
+echo "configure:3823: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3800,7 +3851,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "ar", so it can be a program name with args.
set dummy ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3804: checking for $ac_word" >&5
+echo "configure:3855: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3835,7 +3886,7 @@ fi
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3839: checking for $ac_word" >&5
+echo "configure:3890: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3867,7 +3918,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3871: checking for $ac_word" >&5
+echo "configure:3922: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3902,7 +3953,7 @@ fi
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3906: checking for $ac_word" >&5
+echo "configure:3957: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3934,7 +3985,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3938: checking for $ac_word" >&5
+echo "configure:3989: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3978,7 +4029,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:3982: checking for a BSD compatible install" >&5
+echo "configure:4033: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -4040,7 +4091,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4044: checking for $ac_word" >&5
+echo "configure:4095: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_BUILD_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4074,17 +4125,17 @@ for ac_hdr in stdlib.h unistd.h stdarg.h errno.h malloc.h mntent.h paths.h diren
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4078: checking for $ac_hdr" >&5
+echo "configure:4129: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4083 "configure"
+#line 4134 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4088: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4139: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -4111,12 +4162,12 @@ fi
done
echo $ac_n "checking for vprintf""... $ac_c" 1>&6
-echo "configure:4115: checking for vprintf" >&5
+echo "configure:4166: checking for vprintf" >&5
if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4120 "configure"
+#line 4171 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char vprintf(); below. */
@@ -4139,7 +4190,7 @@ vprintf();
; return 0; }
EOF
-if { (eval echo configure:4143: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4194: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_vprintf=yes"
else
@@ -4163,12 +4214,12 @@ fi
if test "$ac_cv_func_vprintf" != yes; then
echo $ac_n "checking for _doprnt""... $ac_c" 1>&6
-echo "configure:4167: checking for _doprnt" >&5
+echo "configure:4218: checking for _doprnt" >&5
if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4172 "configure"
+#line 4223 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char _doprnt(); below. */
@@ -4191,7 +4242,7 @@ _doprnt();
; return 0; }
EOF
-if { (eval echo configure:4195: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4246: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func__doprnt=yes"
else
@@ -4216,12 +4267,12 @@ fi
fi
echo $ac_n "checking whether struct dirent has a d_namlen field""... $ac_c" 1>&6
-echo "configure:4220: checking whether struct dirent has a d_namlen field" >&5
+echo "configure:4271: checking whether struct dirent has a d_namlen field" >&5
if eval "test \"`echo '$''{'e2fsprogs_cv_struct_d_namlen'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4225 "configure"
+#line 4276 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <dirent.h>
@@ -4229,7 +4280,7 @@ int main() {
struct dirent de; de.d_namlen = 0;
; return 0; }
EOF
-if { (eval echo configure:4233: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4284: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
e2fsprogs_cv_struct_d_namlen=yes
else
@@ -4249,19 +4300,19 @@ EOF
fi
echo $ac_n "checking whether llseek declared in unistd.h""... $ac_c" 1>&6
-echo "configure:4253: checking whether llseek declared in unistd.h" >&5
+echo "configure:4304: checking whether llseek declared in unistd.h" >&5
if eval "test \"`echo '$''{'e2fsprogs_cv_have_llseek_prototype'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4258 "configure"
+#line 4309 "configure"
#include "confdefs.h"
#include <unistd.h>
int main() {
extern int llseek(int);
; return 0; }
EOF
-if { (eval echo configure:4265: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4316: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
e2fsprogs_cv_have_llseek_prototype=no
else
@@ -4281,12 +4332,12 @@ EOF
fi
echo $ac_n "checking whether lseek64 declared in unistd.h""... $ac_c" 1>&6
-echo "configure:4285: checking whether lseek64 declared in unistd.h" >&5
+echo "configure:4336: checking whether lseek64 declared in unistd.h" >&5
if eval "test \"`echo '$''{'e2fsprogs_cv_have_lseek64_prototype'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4290 "configure"
+#line 4341 "configure"
#include "confdefs.h"
#define _LARGEFILE_SOURCE
#define _LARGEFILE64_SOURCE
@@ -4295,7 +4346,7 @@ int main() {
extern int lseek64(int);
; return 0; }
EOF
-if { (eval echo configure:4299: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4350: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
e2fsprogs_cv_have_lseek64_prototype=no
else
@@ -4323,7 +4374,7 @@ if test "$cross_compiling" = yes -a "$ac_cv_sizeof_long" = ""; then
echo "configure: warning: Cross-compiling, so cannot check type sizes; assuming short=2, int=4, long=4, long long=8" 1>&2
fi
echo $ac_n "checking size of short""... $ac_c" 1>&6
-echo "configure:4327: checking size of short" >&5
+echo "configure:4378: checking size of short" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4331,7 +4382,7 @@ else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4335 "configure"
+#line 4386 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <sys/types.h>
@@ -4343,7 +4394,7 @@ main()
exit(0);
}
EOF
-if { (eval echo configure:4347: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4398: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_short=`cat conftestval`
else
@@ -4363,7 +4414,7 @@ EOF
echo $ac_n "checking size of int""... $ac_c" 1>&6
-echo "configure:4367: checking size of int" >&5
+echo "configure:4418: checking size of int" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4371,7 +4422,7 @@ else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4375 "configure"
+#line 4426 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <sys/types.h>
@@ -4383,7 +4434,7 @@ main()
exit(0);
}
EOF
-if { (eval echo configure:4387: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4438: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_int=`cat conftestval`
else
@@ -4403,7 +4454,7 @@ EOF
echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:4407: checking size of long" >&5
+echo "configure:4458: checking size of long" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4411,7 +4462,7 @@ else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4415 "configure"
+#line 4466 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <sys/types.h>
@@ -4423,7 +4474,7 @@ main()
exit(0);
}
EOF
-if { (eval echo configure:4427: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4478: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_long=`cat conftestval`
else
@@ -4443,7 +4494,7 @@ EOF
echo $ac_n "checking size of long long""... $ac_c" 1>&6
-echo "configure:4447: checking size of long long" >&5
+echo "configure:4498: checking size of long long" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4451,7 +4502,7 @@ else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4455 "configure"
+#line 4506 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <sys/types.h>
@@ -4463,7 +4514,7 @@ main()
exit(0);
}
EOF
-if { (eval echo configure:4467: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4518: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_long_long=`cat conftestval`
else
@@ -4491,14 +4542,14 @@ SIZEOF_LONG_LONG=$ac_cv_sizeof_long_long
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
-echo "configure:4495: checking whether byte ordering is bigendian" >&5
+echo "configure:4546: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_bigendian=unknown
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
-#line 4502 "configure"
+#line 4553 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
@@ -4509,11 +4560,11 @@ int main() {
#endif
; return 0; }
EOF
-if { (eval echo configure:4513: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4564: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
-#line 4517 "configure"
+#line 4568 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
@@ -4524,7 +4575,7 @@ int main() {
#endif
; return 0; }
EOF
-if { (eval echo configure:4528: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4579: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
else
@@ -4544,7 +4595,7 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4548 "configure"
+#line 4599 "configure"
#include "confdefs.h"
main () {
/* Are we little or big endian? From Harbison&Steele. */
@@ -4557,7 +4608,7 @@ main () {
exit (u.c[sizeof (long) - 1] == 1);
}
EOF
-if { (eval echo configure:4561: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4612: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
else
@@ -4581,19 +4632,19 @@ EOF
fi
echo $ac_n "checking whether struct stat has a st_flags field""... $ac_c" 1>&6
-echo "configure:4585: checking whether struct stat has a st_flags field" >&5
+echo "configure:4636: checking whether struct stat has a st_flags field" >&5
if eval "test \"`echo '$''{'e2fsprogs_cv_struct_st_flags'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4590 "configure"
+#line 4641 "configure"
#include "confdefs.h"
#include <sys/stat.h>
int main() {
struct stat stat; stat.st_flags = 0;
; return 0; }
EOF
-if { (eval echo configure:4597: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4648: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
e2fsprogs_cv_struct_st_flags=yes
else
@@ -4608,19 +4659,19 @@ fi
echo "$ac_t""$e2fsprogs_cv_struct_st_flags" 1>&6
if test "$e2fsprogs_cv_struct_st_flags" = yes; then
echo $ac_n "checking whether st_flags field is useful""... $ac_c" 1>&6
-echo "configure:4612: checking whether st_flags field is useful" >&5
+echo "configure:4663: checking whether st_flags field is useful" >&5
if eval "test \"`echo '$''{'e2fsprogs_cv_struct_st_flags_immut'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4617 "configure"
+#line 4668 "configure"
#include "confdefs.h"
#include <sys/stat.h>
int main() {
struct stat stat; stat.st_flags |= UF_IMMUTABLE;
; return 0; }
EOF
-if { (eval echo configure:4624: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4675: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
e2fsprogs_cv_struct_st_flags_immut=yes
else
@@ -4643,12 +4694,12 @@ fi
for ac_func in chflags getrusage llseek lseek64 open64 getmntinfo strcasecmp srandom fchown mallinfo fdatasync strnlen sysconf
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4647: checking for $ac_func" >&5
+echo "configure:4698: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4652 "configure"
+#line 4703 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -4671,7 +4722,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:4675: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -4697,7 +4748,7 @@ done
SOCKET_LIB=''
echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
-echo "configure:4701: checking for socket in -lsocket" >&5
+echo "configure:4752: checking for socket in -lsocket" >&5
ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -4705,7 +4756,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lsocket $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4709 "configure"
+#line 4760 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -4716,7 +4767,7 @@ int main() {
socket()
; return 0; }
EOF
-if { (eval echo configure:4720: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4771: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -4738,12 +4789,12 @@ fi
echo $ac_n "checking for optreset""... $ac_c" 1>&6
-echo "configure:4742: checking for optreset" >&5
+echo "configure:4793: checking for optreset" >&5
if eval "test \"`echo '$''{'ac_cv_have_optreset'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4747 "configure"
+#line 4798 "configure"
#include "confdefs.h"
#include <unistd.h>
EOF
@@ -4815,20 +4866,20 @@ fi
echo $ac_n "checking whether linker accepts -static""... $ac_c" 1>&6
-echo "configure:4819: checking whether linker accepts -static" >&5
+echo "configure:4870: checking whether linker accepts -static" >&5
if eval "test \"`echo '$''{'ac_cv_e2fsprogs_use_static'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
SAVE_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -static"
cat > conftest.$ac_ext <<EOF
-#line 4825 "configure"
+#line 4876 "configure"
#include "confdefs.h"
#include <stdio.h>
int main() {
fflush(stdout);
; return 0; }
EOF
-if { (eval echo configure:4832: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4883: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_e2fsprogs_use_static=yes
else
@@ -5034,6 +5085,8 @@ s%@CC@%$CC%g
s%@LD@%$LD%g
s%@CPP@%$CPP%g
s%@LINUX_INCLUDE@%$LINUX_INCLUDE%g
+s%@HTREE_CMT@%$HTREE_CMT%g
+s%@HTREE_CLR_CMT@%$HTREE_CLR_CMT%g
s%@DLL_CMT@%$DLL_CMT%g
/@MAKEFILE_DLL@/r $MAKEFILE_DLL
s%@MAKEFILE_DLL@%%g
diff --git a/configure.in b/configure.in
index cc8d5850..cfad88ea 100644
--- a/configure.in
+++ b/configure.in
@@ -125,6 +125,45 @@ fi
echo "Disabling compression support by default"
)
dnl
+dnl handle --enable-htree
+dnl
+AC_ARG_ENABLE([htree],
+[ --enable-htree enable EXPERIMENTAL htree directory support],
+if test "$enableval" = "no"
+then
+ HTREE_CMT=#
+ echo "Disabling htree directory support"
+else
+ HTREE_CMT=
+ AC_DEFINE(ENABLE_HTREE)
+ echo "Enabling htree directory support"
+ echo "WARNING: htree support is experimental"
+fi
+,
+HTREE_CMT=#
+echo "Disabling htree directory support by default"
+)
+AC_SUBST(HTREE_CMT)
+dnl
+dnl handle --enable-clear-htree
+dnl
+AC_ARG_ENABLE([htree-clear],
+[ --enable-htree-clear clear htree because we don't trust e2fsck],
+if test "$enableval" = "no"
+then
+ HTREE_CLR_CMT=#
+ echo "Disabling htree clearing"
+else
+ HTREE_CLR_CMT=
+ AC_DEFINE(ENABLE_HTREE_CLEAR)
+ echo "Enabling htree clearing"
+fi
+,
+HTREE_CLR_CMT=#
+echo "Disabling htree clearing by default"
+)
+AC_SUBST(HTREE_CLR_CMT)
+dnl
dnl handle --enable-old-evms
dnl
AC_ARG_ENABLE([old-evms],
diff --git a/e2fsck/ChangeLog b/e2fsck/ChangeLog
index c2e7e8d5..ca623e95 100644
--- a/e2fsck/ChangeLog
+++ b/e2fsck/ChangeLog
@@ -1,3 +1,30 @@
+2002-06-25 Theodore Ts'o <tytso@mit.edu>
+
+ * e2fsck.c (e2fsck_reset_context): Free the dx_dirinfo structure.
+
+ * message.c: Add new abbrevations @h and @p, "HTREE directory
+ inode" and "problem in".
+
+ * pass1.c (check_blocks): If the inode has the INDEX_FL flag,
+ register the block into the indexed directory data
+ structures. Or if the filesystem doesn't have the
+ DIR_INDEX flag, offer to clear the INDEX_FL.
+
+ * pass2.c (e2fsck_pass2, parse_int_node): Add support check htree
+ directories (we don't check all possible corruptions yet).
+
+ * problem.h, problem.h (PR_1_HTREE_SET, PR_2_HTREE_NOTREF,
+ PR_2_HTREE_DUPREF, PR_2_HTREE_MIN_HASH, PR_2_HTREE_MAX_HASH,
+ PR_2_HTREE_CLEAR, PR_2_HTREE_FCLR, PR_2_HTREE_BADBLK): Add
+ new problem codes.
+
+ * unix.c (main): If ENABLE_HTREE is not defined, complain if the
+ filesystem has the dir_index feature.
+
+ * Makefile.in, e2fsck.h, dx_dirinfo.c: New file (and group of
+ functions) which keeps track of blocks in HTREE directory
+ blocks.
+
2002-05-22 Andreas Dilger <adilger@clusterfs.com>
* super.c (check_superblock): Check that the number of inodes and
diff --git a/e2fsck/Makefile.in b/e2fsck/Makefile.in
index 1dd26aef..51c08212 100644
--- a/e2fsck/Makefile.in
+++ b/e2fsck/Makefile.in
@@ -55,17 +55,18 @@ PROFILED_DEPLIBS= $(PROFILED_LIBEXT2FS) $(PROFILED_LIBCOM_ERR) \
#MCHECK= -DMCHECK
OBJS= unix.o e2fsck.o super.o pass1.o pass1b.o pass2.o pass3.o pass4.o \
- pass5.o journal.o swapfs.o badblocks.o util.o dirinfo.o ehandler.o \
- problem.o message.o recovery.o region.o revoke.o ea_refcount.o \
- $(MTRACE_OBJ)
+ pass5.o journal.o swapfs.o badblocks.o util.o dirinfo.o dx_dirinfo.o \
+ ehandler.o problem.o message.o recovery.o region.o revoke.o \
+ ea_refcount.o $(MTRACE_OBJ)
PROFILED_OBJS= profiled/unix.o profiled/e2fsck.o profiled/super.o \
profiled/pass1.o profiled/pass1b.o \
profiled/pass2.o profiled/pass3.o profiled/pass4.o profiled/pass5.o \
profiled/journal.o profiled/badblocks.o profiled/util.o \
- profiled/dirinfo.o profiled/ehandler.o profiled/message.o \
- profiled/problem.o profiled/swapfs.o profiled/recovery.o \
- profiled/region.o profiled/revoke.o profiled/ea_refcount.o
+ profiled/dirinfo.o profiled/dx_dirinfo.o profiled/ehandler.o \
+ profiled/message.o profiled/problem.o profiled/swapfs.o \
+ profiled/recovery.o profiled/region.o profiled/revoke.o \
+ profiled/ea_refcount.o
SRCS= $(srcdir)/e2fsck.c \
$(srcdir)/super.c \
@@ -82,6 +83,7 @@ SRCS= $(srcdir)/e2fsck.c \
$(srcdir)/util.c \
$(srcdir)/unix.c \
$(srcdir)/dirinfo.c \
+ $(srcdir)/dx_dirinfo.c \
$(srcdir)/ehandler.c \
$(srcdir)/problem.c \
$(srcdir)/message.c \
diff --git a/e2fsck/dx_dirinfo.c b/e2fsck/dx_dirinfo.c
new file mode 100644
index 00000000..ff90e99f
--- /dev/null
+++ b/e2fsck/dx_dirinfo.c
@@ -0,0 +1,150 @@
+/*
+ * dirinfo.c --- maintains the directory information table for e2fsck.
+ *
+ * Copyright (C) 1993 Theodore Ts'o. This file may be redistributed
+ * under the terms of the GNU Public License.
+ */
+
+#include "e2fsck.h"
+#ifdef ENABLE_HTREE
+
+/*
+ * This subroutine is called during pass1 to create a directory info
+ * entry. During pass1, the passed-in parent is 0; it will get filled
+ * in during pass2.
+ */
+void e2fsck_add_dx_dir(e2fsck_t ctx, ext2_ino_t ino, int num_blocks)
+{
+ struct dx_dir_info *dir;
+ int i, j;
+ errcode_t retval;
+ unsigned long old_size;
+
+#if 0
+ printf("add_dx_dir_info for inode %lu...\n", ino);
+#endif
+ if (!ctx->dx_dir_info) {
+ ctx->dx_dir_info_count = 0;
+ ctx->dx_dir_info_size = 100; /* Guess */
+ ctx->dx_dir_info = (struct dx_dir_info *)
+ e2fsck_allocate_memory(ctx, ctx->dx_dir_info_size
+ * sizeof (struct dx_dir_info),
+ "directory map");
+ }
+
+ if (ctx->dx_dir_info_count >= ctx->dx_dir_info_size) {
+ old_size = ctx->dx_dir_info_size * sizeof(struct dx_dir_info);
+ ctx->dx_dir_info_size += 10;
+ retval = ext2fs_resize_mem(old_size, ctx->dx_dir_info_size *
+ sizeof(struct dx_dir_info),
+ (void **) &ctx->dx_dir_info);
+ if (retval) {
+ ctx->dx_dir_info_size -= 10;
+ return;
+ }
+ }
+
+ /*
+ * Normally, add_dx_dir_info is called with each inode in
+ * sequential order; but once in a while (like when pass 3
+ * needs to recreate the root directory or lost+found
+ * directory) it is called out of order. In those cases, we
+ * need to move the dx_dir_info entries down to make room, since
+ * the dx_dir_info array needs to be sorted by inode number for
+ * get_dx_dir_info()'s sake.
+ */
+ if (ctx->dx_dir_info_count &&
+ ctx->dx_dir_info[ctx->dx_dir_info_count-1].ino >= ino) {
+ for (i = ctx->dx_dir_info_count-1; i > 0; i--)
+ if (ctx->dx_dir_info[i-1].ino < ino)
+ break;
+ dir = &ctx->dx_dir_info[i];
+ if (dir->ino != ino)
+ for (j = ctx->dx_dir_info_count++; j > i; j--)
+ ctx->dx_dir_info[j] = ctx->dx_dir_info[j-1];
+ } else
+ dir = &ctx->dx_dir_info[ctx->dx_dir_info_count++];
+
+ dir->ino = ino;
+ dir->numblocks = num_blocks;
+ dir->hashversion = 0;
+ dir->dx_block = e2fsck_allocate_memory(ctx, num_blocks
+ * sizeof (struct dx_dirblock_info),
+ "dx_block info array");
+
+}
+
+/*
+ * get_dx_dir_info() --- given an inode number, try to find the directory
+ * information entry for it.
+ */
+struct dx_dir_info *e2fsck_get_dx_dir_info(e2fsck_t ctx, ext2_ino_t ino)
+{
+ int low, high, mid;
+
+ low = 0;
+ high = ctx->dx_dir_info_count-1;
+ if (!ctx->dx_dir_info)
+ return 0;
+ if (ino == ctx->dx_dir_info[low].ino)
+ return &ctx->dx_dir_info[low];
+ if (ino == ctx->dx_dir_info[high].ino)
+ return &ctx->dx_dir_info[high];
+
+ while (low < high) {
+ mid = (low+high)/2;
+ if (mid == low || mid == high)
+ break;
+ if (ino == ctx->dx_dir_info[mid].ino)
+ return &ctx->dx_dir_info[mid];
+ if (ino < ctx->dx_dir_info[mid].ino)
+ high = mid;
+ else
+ low = mid;
+ }
+ return 0;
+}
+
+/*
+ * Free the dx_dir_info structure when it isn't needed any more.
+ */
+void e2fsck_free_dx_dir_info(e2fsck_t ctx)
+{
+ int i;
+ struct dx_dir_info *dir;
+
+ if (ctx->dx_dir_info) {
+ dir = ctx->dx_dir_info;
+ for (i=0; i < ctx->dx_dir_info_count; i++) {
+ if (dir->dx_block) {
+ ext2fs_free_mem((void **) &dir->dx_block);
+ dir->dx_block = 0;
+ }
+ }
+ ext2fs_free_mem((void **) &ctx->dx_dir_info);
+ ctx->dx_dir_info = 0;
+ }
+ ctx->dx_dir_info_size = 0;
+ ctx->dx_dir_info_count = 0;
+}
+
+/*
+ * Return the count of number of directories in the dx_dir_info structure
+ */
+int e2fsck_get_num_dx_dirinfo(e2fsck_t ctx)
+{
+ return ctx->dx_dir_info_count;
+}
+
+/*
+ * A simple interator function
+ */
+struct dx_dir_info *e2fsck_dx_dir_info_iter(e2fsck_t ctx, int *control)
+{
+ if (*control >= ctx->dx_dir_info_count)
+ return 0;
+
+ return(ctx->dx_dir_info + (*control)++);
+}
+
+#endif /* ENABLE_HTREE */
diff --git a/e2fsck/e2fsck.c b/e2fsck/e2fsck.c
index 1ec8ffad..0abae190 100644
--- a/e2fsck/e2fsck.c
+++ b/e2fsck/e2fsck.c
@@ -72,6 +72,9 @@ errcode_t e2fsck_reset_context(e2fsck_t ctx)
ctx->fs->dblist = 0;
}
e2fsck_free_dir_info(ctx);
+#ifdef ENABLE_HTREE
+ e2fsck_free_dx_dir_info(ctx);
+#endif
if (ctx->refcount) {
ea_refcount_free(ctx->refcount);
ctx->refcount = 0;
diff --git a/e2fsck/e2fsck.h b/e2fsck/e2fsck.h
index 88490aa1..49097fe6 100644
--- a/e2fsck/e2fsck.h
+++ b/e2fsck/e2fsck.h
@@ -77,6 +77,40 @@ struct dir_info {
ext2_ino_t parent; /* Parent according to treewalk */
};
+
+/*
+ * The indexed directory information structure; stores information for
+ * directories which contain a hash tree index.
+ */
+struct dx_dir_info {
+ ext2_ino_t ino; /* Inode number */
+ int numblocks; /* number of blocks */
+ int hashversion;
+ struct dx_dirblock_info *dx_block; /* Array of size numblocks */
+};
+
+#define DX_DIRBLOCK_ROOT 1
+#define DX_DIRBLOCK_LEAF 2
+#define DX_DIRBLOCK_NODE 3
+#define DX_DIRBLOCK_CORRUPT 4
+#define DX_DIRBLOCK_CLEARED 8
+
+struct dx_dirblock_info {
+ int type;
+ blk_t phys;
+ int flags;
+ blk_t parent;
+ ext2_dirhash_t min_hash;
+ ext2_dirhash_t max_hash;
+ ext2_dirhash_t node_min_hash;
+ ext2_dirhash_t node_max_hash;
+};
+
+#define DX_FLAG_REFERENCED 1
+#define DX_FLAG_DUP_REF 2
+#define DX_FLAG_FIRST 4
+#define DX_FLAG_LAST 8
+
#ifdef RESOURCE_TRACK
/*
* This structure is used for keeping track of how much resources have
@@ -208,6 +242,13 @@ struct e2fsck_struct {
struct dir_info *dir_info;
/*
+ * Indexed directory information
+ */
+ int dx_dir_info_count;
+ int dx_dir_info_size;
+ struct dx_dir_info *dx_dir_info;
+
+ /*
* Tuning parameters
*/
int process_inode_size;
@@ -292,10 +333,16 @@ extern void test_disk(e2fsck_t ctx);
extern void e2fsck_add_dir_info(e2fsck_t ctx, ext2_ino_t ino, ext2_ino_t parent);
extern struct dir_info *e2fsck_get_dir_info(e2fsck_t ctx, ext2_ino_t ino);
extern void e2fsck_free_dir_info(e2fsck_t ctx);
-extern int e2fsck_get_num_dirs(e2fsck_t ctx);
extern int e2fsck_get_num_dirinfo(e2fsck_t ctx);
extern struct dir_info *e2fsck_dir_info_iter(e2fsck_t ctx, int *control);
+/* dx_dirinfo.c */
+extern void e2fsck_add_dx_dir(e2fsck_t ctx, ext2_ino_t ino, int num_blocks);
+extern struct dx_dir_info *e2fsck_get_dx_dir_info(e2fsck_t ctx, ext2_ino_t ino);
+extern void e2fsck_free_dx_dir_info(e2fsck_t ctx);
+extern int e2fsck_get_num_dx_dirinfo(e2fsck_t ctx);
+extern struct dx_dir_info *e2fsck_dx_dir_info_iter(e2fsck_t ctx, int *control);
+
/* ea_refcount.c */
extern errcode_t ea_refcount_create(int size, ext2_refcount_t *ret);
extern void ea_refcount_free(ext2_refcount_t refcount);
diff --git a/e2fsck/message.c b/e2fsck/message.c
index 991bbee8..6c81eeb2 100644
--- a/e2fsck/message.c
+++ b/e2fsck/message.c
@@ -63,12 +63,14 @@
* @f filesystem
* @F for @i %i (%Q) is
* @g group
+ * @h HTREE directory inode
* @i inode
* @I illegal
* @j journal
* @l lost+found
* @L is a link
* @o orphaned
+ * @p problem in
* @r root inode
* @s should be
* @S superblock
@@ -116,9 +118,11 @@ static const char *abbrevs[] = {
N_("ffilesystem"),
N_("Ffor @i %i (%Q) is"),
N_("ggroup"),
+ N_("hHTREE @d @i"),
N_("llost+found"),
N_("Lis a link"),
N_("oorphaned"),
+ N_("pproblem in"),
N_("rroot @i"),
N_("sshould be"),
N_("Ssuper@b"),
diff --git a/e2fsck/pass1.c b/e2fsck/pass1.c
index b15e120b..5bb99bcc 100644
--- a/e2fsck/pass1.c
+++ b/e2fsck/pass1.c
@@ -1208,6 +1208,22 @@ static void check_blocks(e2fsck_t ctx, struct problem_context *pctx,
ctx->flags |= E2F_FLAG_RESTART;
return;
}
+
+ if (inode->i_flags & EXT2_INDEX_FL) {
+ if (fs->super->s_feature_compat &
+ EXT2_FEATURE_COMPAT_DIR_INDEX) {
+#ifdef ENABLE_HTREE
+ e2fsck_add_dx_dir(ctx, ino, pb.last_block+1);
+#endif
+ } else {
+ if (fix_problem(ctx, PR_1_HTREE_SET, pctx)) {
+ inode->i_flags &= ~EXT2_INDEX_FL;
+ e2fsck_write_inode(ctx, ino, inode,
+ "check_blocks");
+ }
+ }
+ }
+
if (inode->i_file_acl && check_ext_attr(ctx, pctx, block_buf))
pb.num_blocks++;
diff --git a/e2fsck/pass2.c b/e2fsck/pass2.c
index 34c253d4..5ad52968 100644
--- a/e2fsck/pass2.c
+++ b/e2fsck/pass2.c
@@ -50,6 +50,8 @@
#define _INLINE_ inline
#endif
+#undef DX_DEBUG
+
/*
* Keeps track of how many times an inode is referenced.
*/
@@ -66,6 +68,7 @@ static int update_dir_block(ext2_filsys fs,
blk_t ref_block,
int ref_offset,
void *priv_data);
+static void clear_htree(e2fsck_t ctx, ext2_ino_t ino);
struct check_dir_struct {
char *buf;
@@ -85,7 +88,13 @@ void e2fsck_pass2(e2fsck_t ctx)
#endif
struct dir_info *dir;
struct check_dir_struct cd;
-
+ struct dx_dir_info *dx_dir;
+ struct dx_dirblock_info *dx_db, *dx_parent;
+ blk_t b;
+ int i;
+ problem_t code;
+ int bad_dir;
+
#ifdef RESOURCE_TRACK
init_resource_track(&rtrack);
#endif
@@ -136,7 +145,93 @@ void e2fsck_pass2(e2fsck_t ctx)
ctx->flags |= E2F_FLAG_ABORT;
return;
}
-
+
+#ifdef ENABLE_HTREE
+ for (i=0; (dx_dir = e2fsck_dx_dir_info_iter(ctx, &i)) != 0;) {
+ if (dx_dir->ino == 0)
+ continue;
+ clear_problem_context(&pctx);
+ bad_dir = 0;
+ pctx.dir = dx_dir->ino;
+ dx_db = dx_dir->dx_block;
+ if (dx_db->flags & DX_FLAG_REFERENCED)
+ dx_db->flags |= DX_FLAG_DUP_REF;
+ else
+ dx_db->flags |= DX_FLAG_REFERENCED;
+ /*
+ * Find all of the first and last leaf blocks, and
+ * update their parent's min and max hash values
+ */
+ for (b=0, dx_db = dx_dir->dx_block;
+ b < dx_dir->numblocks;
+ b++, dx_db++) {
+ if ((dx_db->type != DX_DIRBLOCK_LEAF) ||
+ !(dx_db->flags & (DX_FLAG_FIRST | DX_FLAG_LAST)))
+ continue;
+ dx_parent = &dx_dir->dx_block[dx_db->parent];
+ /*
+ * XXX Make sure dx_parent->min_hash > dx_db->min_hash
+ */
+ if (dx_db->flags & DX_FLAG_FIRST)
+ dx_parent->min_hash = dx_db->min_hash;
+ /*
+ * XXX Make sure dx_parent->max_hash < dx_db->max_hash
+ */
+ if (dx_db->flags & DX_FLAG_LAST)
+ dx_parent->max_hash = dx_db->max_hash;
+ }
+
+ for (b=0, dx_db = dx_dir->dx_block;
+ b < dx_dir->numblocks;
+ b++, dx_db++) {
+ pctx.blkcount = b;
+ pctx.group = dx_db->parent;
+ code = 0;
+ if (!(dx_db->flags & DX_FLAG_FIRST) &&
+ (dx_db->min_hash < dx_db->node_min_hash)) {
+ pctx.blk = dx_db->min_hash;
+ pctx.blk2 = dx_db->node_min_hash;
+ code = PR_2_HTREE_MIN_HASH;
+ fix_problem(ctx, code, &pctx);
+ bad_dir++;
+ }
+ /*
+ * This test doesn't apply for the root block
+ * at block #0
+ */
+ if (b &&
+ (dx_db->max_hash > dx_db->node_max_hash)) {
+ pctx.blk = dx_db->max_hash;
+ pctx.blk2 = dx_db->node_max_hash;
+ code = PR_2_HTREE_MAX_HASH;
+ fix_problem(ctx, code, &pctx);
+ }
+ if (!(dx_db->flags & DX_FLAG_REFERENCED)) {
+ code = PR_2_HTREE_NOTREF;
+ fix_problem(ctx, code, &pctx);
+ bad_dir++;
+ } else if (dx_db->flags & DX_FLAG_DUP_REF) {
+ code = PR_2_HTREE_DUPREF;
+ fix_problem(ctx, code, &pctx);
+ bad_dir++;
+ }
+ if (code == 0)
+ continue;
+ }
+ if (bad_dir && fix_problem(ctx, PR_2_HTREE_CLEAR, &pctx)) {
+ clear_htree(ctx, dx_dir->ino);
+ dx_dir->ino = 0;
+ break;
+ }
+#ifdef ENABLE_HTREE_CLEAR
+ if (dx_dir->ino) {
+ fix_problem(ctx, PR_2_HTREE_FCLR, &pctx);
+ clear_htree(ctx, dx_dir->ino);
+ dx_dir->ino = 0;
+ }
+#endif
+ }
+#endif
ext2fs_free_mem((void **) &buf);
ext2fs_free_dblist(fs->dblist);
@@ -353,13 +448,107 @@ static _INLINE_ int check_filetype(e2fsck_t ctx,
return 1;
}
+#ifdef ENABLE_HTREE
+static void parse_int_node(ext2_filsys fs,
+ struct ext2_db_entry *db,
+ struct check_dir_struct *cd,
+ struct dx_dir_info *dx_dir,
+ char *block_buf)
+{
+ struct ext2_dx_root_info *root;
+ struct ext2_dx_entry *ent;
+ struct ext2_dx_countlimit *limit;
+ struct dx_dirblock_info *dx_db;
+ int i;
+ blk_t blk;
+ ext2_dirhash_t min_hash = 0xffffffff;
+ ext2_dirhash_t max_hash = 0;
+ ext2_dirhash_t hash = 0;
+
+ if (db->blockcnt == 0) {
+ root = (struct ext2_dx_root_info *) (block_buf + 24);
+
+#ifdef DX_DEBUG
+ printf("Root node dump:\n");
+ printf("\t Reserved zero: %d\n", root->reserved_zero);
+ printf("\t Hash Version: %d\n", root->hash_version);
+ printf("\t Info length: %d\n", root->info_length);
+ printf("\t Indirect levels: %d\n", root->indirect_levels);
+ printf("\t Flags: %d\n", root->unused_flags);
+#endif
+
+ ent = (struct ext2_dx_entry *) (block_buf + 24 + root->info_length);
+ } else {
+ ent = (struct ext2_dx_entry *) (block_buf+8);
+ }
+ limit = (struct ext2_dx_countlimit *) ent;
+
+#ifdef DX_DEBUG
+ printf("Number of entries (count): %d\n", limit->count);
+ printf("Number of entries (limit): %d\n", limit->limit);
+#endif
+
+ for (i=0; i < limit->count; i++) {
+ hash = i ? (ent[i].hash & ~1) : 0;
+ /*
+ * XXX Check to make make sure the hash[i] < hash[i+1]
+ */
+#ifdef DX_DEBUG
+ printf("Entry #%d: Hash 0x%08x, block %d\n", i,
+ hash, ent[i].block);
+#endif
+ blk = ent[i].block & 0x0ffffff;
+ /* Check to make sure the block is valid */
+ if (blk > dx_dir->numblocks) {
+ if (fix_problem(cd->ctx, PR_2_HTREE_BADBLK,
+ cd->pctx)) {
+ clear_htree(cd->ctx, cd->pctx.ino);
+ dx_dir->ino = 0;
+ return;
+ }
+ }
+ dx_db = &dx_dir->dx_block[blk];
+ if (dx_db->flags & DX_FLAG_REFERENCED) {
+ dx_db->flags |= DX_FLAG_DUP_REF;
+ } else {
+ dx_db->flags |= DX_FLAG_REFERENCED;
+ dx_db->parent = db->blockcnt;
+ }
+ if (hash < min_hash)
+ min_hash = hash;
+ if (hash > max_hash)
+ max_hash = hash;
+ dx_db->node_min_hash = hash;
+ if ((i+1) < limit->count)
+ dx_db->node_max_hash = (ent[i+1].hash & ~1);
+ else {
+ dx_db->node_max_hash = 0xfffffffe;
+ dx_db->flags |= DX_FLAG_LAST;
+ }
+ if (i == 0)
+ dx_db->flags |= DX_FLAG_FIRST;
+ }
+#ifdef DX_DEBUG
+ printf("Blockcnt = %d, min hash 0x%08x, max hash 0x%08x\n",
+ db->blockcnt, min_hash, max_hash);
+#endif
+ dx_db = &dx_dir->dx_block[db->blockcnt];
+ dx_db->min_hash = min_hash;
+ dx_db->max_hash = max_hash;
+}
+#endif /* ENABLE_HTREE */
static int check_dir_block(ext2_filsys fs,
struct ext2_db_entry *db,
void *priv_data)
{
struct dir_info *subdir, *dir;
+ struct dx_dir_info *dx_dir;
+#ifdef ENABLE_HTREE
+ struct dx_dirblock_info *dx_db = 0;
+#endif /* ENABLE_HTREE */
struct ext2_dir_entry *dirent;
+ ext2_dirhash_t hash;
int offset = 0;
int dir_modified = 0;
int dot_state;
@@ -419,6 +608,32 @@ static int check_dir_block(ext2_filsys fs,
}
memset(buf, 0, fs->blocksize);
}
+#ifdef ENABLE_HTREE
+ dx_dir = e2fsck_get_dx_dir_info(ctx, ino);
+ if (dx_dir && dx_dir->ino) {
+ if (db->blockcnt >= dx_dir->numblocks) {
+ printf("XXX should never happen!!!\n");
+ abort();
+ }
+ dx_db = &dx_dir->dx_block[db->blockcnt];
+ dx_db->type = DX_DIRBLOCK_LEAF;
+ dx_db->phys = block_nr;
+ dx_db->min_hash = ~0;
+ dx_db->max_hash = 0;
+
+ dirent = (struct ext2_dir_entry *) buf;
+ /*
+ * XXX we need to check to make sure the root
+ * directory block is actually valid!
+ */
+ if (db->blockcnt == 0) {
+ dx_db->type = DX_DIRBLOCK_ROOT;
+ dx_db->flags |= DX_FLAG_FIRST | DX_FLAG_LAST;
+ } else if ((dirent->inode == 0) &&
+ (dirent->rec_len == fs->blocksize))
+ dx_db->type = DX_DIRBLOCK_NODE;
+ }
+#endif /* ENABLE_HTREE */
do {
dot_state++;
@@ -563,6 +778,17 @@ static int check_dir_block(ext2_filsys fs,
if (check_filetype(ctx, dirent, ino, &cd->pctx))
dir_modified++;
+#ifdef ENABLE_HTREE
+ if (dx_db) {
+ ext2fs_dirhash(dx_dir->hashversion, dirent->name,
+ (dirent->name_len & 0xFF), &hash);
+ if (hash < dx_db->min_hash)
+ dx_db->min_hash = hash;
+ if (hash > dx_db->max_hash)
+ dx_db->max_hash = hash;
+ }
+#endif
+
/*
* If this is a directory, then mark its parent in its
* dir_info structure. If the parent field is already
@@ -604,6 +830,18 @@ static int check_dir_block(ext2_filsys fs,
#if 0
printf("\n");
#endif
+#ifdef ENABLE_HTREE
+ if (dx_db) {
+#ifdef DX_DEBUG
+ printf("db_block %d, type %d, min_hash 0x%0x, max_hash 0x%0x\n",
+ db->blockcnt, dx_db->type,
+ dx_db->min_hash, dx_db->max_hash);
+#endif
+ if ((dx_db->type == DX_DIRBLOCK_ROOT) ||
+ (dx_db->type == DX_DIRBLOCK_NODE))
+ parse_int_node(fs, db, cd, dx_dir, buf);
+ }
+#endif /* ENABLE_HTREE */
if (offset != fs->blocksize) {
cd->pctx.num = dirent->rec_len - fs->blocksize + offset;
if (fix_problem(ctx, PR_2_FINAL_RECLEN, &cd->pctx)) {
@@ -696,6 +934,20 @@ static void deallocate_inode(e2fsck_t ctx, ext2_ino_t ino, char* block_buf)
}
}
+/*
+ * This fuction clears the htree flag on an inode
+ */
+static void clear_htree(e2fsck_t ctx, ext2_ino_t ino)
+{
+ struct ext2_inode inode;
+ struct problem_context pctx;
+
+ e2fsck_read_inode(ctx, ino, &inode, "clear_htree");
+ inode.i_flags = inode.i_flags & ~EXT2_INDEX_FL;
+ e2fsck_write_inode(ctx, ino, &inode, "clear_htree");
+}
+
+
extern int e2fsck_process_bad_inode(e2fsck_t ctx, ext2_ino_t dir,
ext2_ino_t ino, char *buf)
{
diff --git a/e2fsck/problem.c b/e2fsck/problem.c
index e786fa2b..1d4ffb16 100644
--- a/e2fsck/problem.c
+++ b/e2fsck/problem.c
@@ -665,6 +665,11 @@ static const struct e2fsck_problem problem_table[] = {
N_("@b #%B (%b) causes symlink to be too big. "),
PROMPT_CLEAR, PR_LATCH_TOOBIG },
+ /* INDEX_FL flag set on a non-HTREE filesystem */
+ { PR_1_HTREE_SET,
+ N_("@i %i has INDEX_FL flag set on @f without htree support.\n"),
+ PROMPT_CLEAR, 0 },
+
/* Pass 1b errors */
/* Pass 1B: Rescan for duplicate/bad blocks */
@@ -984,6 +989,40 @@ static const struct e2fsck_problem problem_table[] = {
N_("@f contains large files, but lacks LARGE_FILE flag in @S.\n"),
PROMPT_FIX, 0 },
+ /* Node in HTREE directory not referenced */
+ { PR_2_HTREE_NOTREF,
+ N_("@p @h %d: node (%B) not referenced\n"),
+ PROMPT_NONE, 0 },
+
+ /* Node in HTREE directory referenced twice */
+ { PR_2_HTREE_DUPREF,
+ N_("@p @h %d: node (%B) referenced twice\n"),
+ PROMPT_NONE, 0 },
+
+ /* Node in HTREE directory has bad min hash */
+ { PR_2_HTREE_MIN_HASH,
+ N_("@p @h %d: node (%B) has bad min hash\n"),
+ PROMPT_NONE, 0 },
+
+ /* Node in HTREE directory has bad max hash */
+ { PR_2_HTREE_MAX_HASH,
+ N_("@p @h %d: node (%B) has bad max hash\n"),
+ PROMPT_NONE, 0 },
+
+ /* Clear invalid HTREE directory */
+ { PR_2_HTREE_CLEAR,
+ N_("Invalid @h %d (%q). "), PROMPT_CLEAR, 0 },
+
+ /* Clear the htree flag forcibly */
+ { PR_2_HTREE_FCLR,
+ N_("Forcibly clearing HTREE flag on @i %d (%q). (Beta test code)\n"),
+ PROMPT_NONE, 0 },
+
+ /* Bad block in htree interior node */
+ { PR_2_HTREE_BADBLK,
+ N_("@p @h %d (%q): bad @b number %B.\n"),
+ PROMPT_CLEAR, 0 },
+
/* Pass 3 errors */
/* Pass 3: Checking directory connectivity */
diff --git a/e2fsck/problem.h b/e2fsck/problem.h
index 3c4b1620..1e511a3a 100644
--- a/e2fsck/problem.h
+++ b/e2fsck/problem.h
@@ -385,6 +385,9 @@ struct problem_context {
/* Symlink too big */
#define PR_1_TOOBIG_SYMLINK 0x010046
+/* INDEX_FL flag set on a non-HTREE filesystem */
+#define PR_1_HTREE_SET 0x010047
+
/*
* Pass 1b errors
*/
@@ -584,6 +587,27 @@ struct problem_context {
/* Filesystem contains large files, but has no such flag in sb */
#define PR_2_FEATURE_LARGE_FILES 0x020033
+/* Node in HTREE directory not referenced */
+#define PR_2_HTREE_NOTREF 0x020034
+
+/* Node in HTREE directory referenced twice */
+#define PR_2_HTREE_DUPREF 0x020035
+
+/* Node in HTREE directory has bad min hash */
+#define PR_2_HTREE_MIN_HASH 0x020036
+
+/* Node in HTREE directory has bad max hash */
+#define PR_2_HTREE_MAX_HASH 0x020037
+
+/* Clear invalid HTREE directory */
+#define PR_2_HTREE_CLEAR 0x020038
+
+/* Clear the htree flag forcibly */
+#define PR_2_HTREE_FCLR 0x020039
+
+/* Bad block in htree interior node */
+#define PR_2_HTREE_BADBLK 0x02003A
+
/*
* Pass 3 errors
*/
diff --git a/e2fsck/unix.c b/e2fsck/unix.c
index e231888d..18f2b2c7 100644
--- a/e2fsck/unix.c
+++ b/e2fsck/unix.c
@@ -876,7 +876,16 @@ restart:
com_err(ctx->program_name, 0,
_("Warning: compression support is experimental.\n"));
#endif
-
+#ifndef ENABLE_HTREE
+ if (sb->s_feature_compat & EXT2_FEATURE_COMPAT_DIR_INDEX) {
+ com_err(ctx->program_name, 0,
+ _("E2fsck not compiled with HTREE support,\n\t"
+ "but filesystem %s has HTREE directories.\n"),
+ ctx->device_name);
+ goto get_newer;
+ }
+#endif
+
/*
* If the user specified a specific superblock, presumably the
* master superblock has been trashed. So we mark the
diff --git a/tests/ChangeLog b/tests/ChangeLog
index 9df3d48d..ea83ad5b 100644
--- a/tests/ChangeLog
+++ b/tests/ChangeLog
@@ -1,3 +1,12 @@
+2002-06-25 Theodore Ts'o <tytso@mit.edu>
+
+ * Makefile.in (test_script): Add pass in the state of
+ --enable-htree and --enable-clear-htree to the test
+ script.
+
+ * f_h_normal, f_h_badnode: New test cases to test the htree
+ directory code.
+
2002-06-09 Andreas Dilger <adilger@clusterfs.com>
* f_8192_block, f_16384_block: Basic tests of 8192-byte block
diff --git a/tests/Makefile.in b/tests/Makefile.in
index 5800a5f8..fc3f67c4 100644
--- a/tests/Makefile.in
+++ b/tests/Makefile.in
@@ -16,6 +16,8 @@ all:: @DO_TEST_SUITE@
test_script: test_script.in Makefile
@echo "Creating test_script..."
@echo "#!/bin/sh" > test_script
+@HTREE_CMT@ @echo "HTREE=y" >> test_script
+@HTREE_CLR_CMT@ @echo "HTREE_CLR=y" >> test_script
@echo "SRCDIR=@srcdir@" >> test_script
@cat $(srcdir)/test_script.in >> test_script
@chmod +x test_script
diff --git a/tests/f_h_badnode/expect.1 b/tests/f_h_badnode/expect.1
new file mode 100644
index 00000000..6d45eab5
--- /dev/null
+++ b/tests/f_h_badnode/expect.1
@@ -0,0 +1,16 @@
+Pass 1: Checking inodes, blocks, and sizes
+Pass 2: Checking directory structure
+Problem in HTREE directory inode 12929: node (531) has bad max hash
+Problem in HTREE directory inode 12929: node (993) referenced twice
+Problem in HTREE directory inode 12929: node (1061) has bad min hash
+Problem in HTREE directory inode 12929: node (1062) has bad max hash
+Problem in HTREE directory inode 12929: node (1062) not referenced
+Invalid HTREE directory inode 12929 (/test2). Clear? yes
+
+Pass 3: Checking directory connectivity
+Pass 4: Checking reference counts
+Pass 5: Checking group summary information
+
+test_filesys: ***** FILE SYSTEM WAS MODIFIED *****
+test_filesys: 47730/100192 files (0.0% non-contiguous), 13689/31745 blocks
+Exit status is 1
diff --git a/tests/f_h_badnode/expect.2 b/tests/f_h_badnode/expect.2
new file mode 100644
index 00000000..4f8c0ac2
--- /dev/null
+++ b/tests/f_h_badnode/expect.2
@@ -0,0 +1,7 @@
+Pass 1: Checking inodes, blocks, and sizes
+Pass 2: Checking directory structure
+Pass 3: Checking directory connectivity
+Pass 4: Checking reference counts
+Pass 5: Checking group summary information
+test_filesys: 47730/100192 files (0.0% non-contiguous), 13689/31745 blocks
+Exit status is 0
diff --git a/tests/f_h_badnode/image.gz b/tests/f_h_badnode/image.gz
new file mode 100644
index 00000000..a3cf21d2
--- /dev/null
+++ b/tests/f_h_badnode/image.gz
Binary files differ
diff --git a/tests/f_h_badnode/name b/tests/f_h_badnode/name
new file mode 100644
index 00000000..ab077fd2
--- /dev/null
+++ b/tests/f_h_badnode/name
@@ -0,0 +1 @@
+hash directory with bad HTREE nodes
diff --git a/tests/f_h_badnode/script b/tests/f_h_badnode/script
new file mode 100644
index 00000000..9353ec77
--- /dev/null
+++ b/tests/f_h_badnode/script
@@ -0,0 +1,6 @@
+if test "$HTREE"x = yx -a "$HTREE_CLR"x = x; then
+. $cmd_dir/run_e2fsck
+else
+ rm -f $test_name.ok $test_name.failed
+ echo "skipped"
+fi
diff --git a/tests/f_h_normal/expect.1 b/tests/f_h_normal/expect.1
new file mode 100644
index 00000000..96ed2b02
--- /dev/null
+++ b/tests/f_h_normal/expect.1
@@ -0,0 +1,7 @@
+Pass 1: Checking inodes, blocks, and sizes
+Pass 2: Checking directory structure
+Pass 3: Checking directory connectivity
+Pass 4: Checking reference counts
+Pass 5: Checking group summary information
+test_filesys: 47729/100192 files (0.0% non-contiguous), 13687/31745 blocks
+Exit status is 0
diff --git a/tests/f_h_normal/expect.2 b/tests/f_h_normal/expect.2
new file mode 100644
index 00000000..96ed2b02
--- /dev/null
+++ b/tests/f_h_normal/expect.2
@@ -0,0 +1,7 @@
+Pass 1: Checking inodes, blocks, and sizes
+Pass 2: Checking directory structure
+Pass 3: Checking directory connectivity
+Pass 4: Checking reference counts
+Pass 5: Checking group summary information
+test_filesys: 47729/100192 files (0.0% non-contiguous), 13687/31745 blocks
+Exit status is 0
diff --git a/tests/f_h_normal/image.gz b/tests/f_h_normal/image.gz
new file mode 100644
index 00000000..c8eb163b
--- /dev/null
+++ b/tests/f_h_normal/image.gz
Binary files differ
diff --git a/tests/f_h_normal/name b/tests/f_h_normal/name
new file mode 100644
index 00000000..900493ff
--- /dev/null
+++ b/tests/f_h_normal/name
@@ -0,0 +1 @@
+Normal HTREE directory
diff --git a/tests/f_h_normal/script b/tests/f_h_normal/script
new file mode 100644
index 00000000..9353ec77
--- /dev/null
+++ b/tests/f_h_normal/script
@@ -0,0 +1,6 @@
+if test "$HTREE"x = yx -a "$HTREE_CLR"x = x; then
+. $cmd_dir/run_e2fsck
+else
+ rm -f $test_name.ok $test_name.failed
+ echo "skipped"
+fi
diff --git a/tests/f_h_normal/script~ b/tests/f_h_normal/script~
new file mode 100644
index 00000000..3024b041
--- /dev/null
+++ b/tests/f_h_normal/script~
@@ -0,0 +1,3 @@
+if test "$HTREE"x = yx ; then
+. $cmd_dir/run_e2fsck
+fi