]> granicus.if.org Git - file/commitdiff
Various fixed.
authorChristos Zoulas <christos@zoulas.com>
Wed, 13 Jan 1999 15:43:58 +0000 (15:43 +0000)
committerChristos Zoulas <christos@zoulas.com>
Wed, 13 Jan 1999 15:43:58 +0000 (15:43 +0000)
15 files changed:
configure
configure.in
magic/Magdir/database
magic/Magdir/diff
magic/Magdir/elf
magic/Magdir/karma
src/Makefile
src/config.h
src/file.c
src/file.h
src/fsmagic.c
src/is_tar.c
src/names.h
src/print.c
src/tar.h

index b252ac92eaa0fb12a7ac5cbca0b9d470750e1c26..d619338829f1ce09171e6823217e3b87999f2257 100755 (executable)
--- a/configure
+++ b/configure
@@ -181,7 +181,7 @@ Features and packages:
   --x-libraries=DIR       X library files are in DIR
 EOF
     if test -n "$ac_help"; then
-      echo "--enable and --with options known (Default: + yes, - no, s system-specific):$ac_help"
+      echo "--enable and --with options recognized:$ac_help"
     fi
     exit 0 ;;
 
@@ -519,10 +519,11 @@ fi
 
 
 
+
 # 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:526: checking for $ac_word" >&5
+echo "configure:527: 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
@@ -551,7 +552,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:555: checking for $ac_word" >&5
+echo "configure:556: 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
@@ -599,7 +600,7 @@ fi
 fi
 
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:603: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:604: 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.
@@ -609,11 +610,11 @@ ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS
 cross_compiling=$ac_cv_prog_cc_cross
 
 cat > conftest.$ac_ext <<EOF
-#line 613 "configure"
+#line 614 "configure"
 #include "confdefs.h"
 main(){return(0);}
 EOF
-if { (eval echo configure:617: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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
@@ -633,12 +634,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:637: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:638: 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:642: checking whether we are using GNU C" >&5
+echo "configure:643: 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
@@ -647,7 +648,7 @@ else
   yes;
 #endif
 EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:651: \"$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:652: \"$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
@@ -662,7 +663,7 @@ if test $ac_cv_prog_gcc = yes; then
   ac_save_CFLAGS="$CFLAGS"
   CFLAGS=
   echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:666: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:667: 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
@@ -719,7 +720,7 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
 # 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:723: checking for a BSD compatible install" >&5
+echo "configure:724: 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
@@ -769,7 +770,7 @@ test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
 
 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:773: checking whether ln -s works" >&5
+echo "configure:774: 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
@@ -791,12 +792,12 @@ fi
 
 
 echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:795: checking for working const" >&5
+echo "configure:796: 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 800 "configure"
+#line 801 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -845,7 +846,7 @@ ccp = (char const *const *) p;
 
 ; return 0; }
 EOF
-if { (eval echo configure:849: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:850: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_const=yes
 else
@@ -866,7 +867,7 @@ EOF
 fi
 
 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:870: checking how to run the C preprocessor" >&5
+echo "configure:871: checking how to run the C preprocessor" >&5
 # On Suns, sometimes $CPP names a directory.
 if test -n "$CPP" && test -d "$CPP"; then
   CPP=
@@ -881,13 +882,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 885 "configure"
+#line 886 "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:891: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:892: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   :
@@ -898,13 +899,13 @@ else
   rm -rf conftest*
   CPP="${CC-cc} -E -traditional-cpp"
   cat > conftest.$ac_ext <<EOF
-#line 902 "configure"
+#line 903 "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:908: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:909: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   :
@@ -927,12 +928,12 @@ fi
 echo "$ac_t""$CPP" 1>&6
 
 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:931: checking for ANSI C header files" >&5
+echo "configure:932: 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 936 "configure"
+#line 937 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 #include <stdarg.h>
@@ -940,7 +941,7 @@ else
 #include <float.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:944: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:945: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -957,7 +958,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 961 "configure"
+#line 962 "configure"
 #include "confdefs.h"
 #include <string.h>
 EOF
@@ -975,7 +976,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 979 "configure"
+#line 980 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -996,7 +997,7 @@ if test "$cross_compiling" = yes; then
   :
 else
   cat > conftest.$ac_ext <<EOF
-#line 1000 "configure"
+#line 1001 "configure"
 #include "confdefs.h"
 #include <ctype.h>
 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -1007,7 +1008,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
 exit (0); }
 
 EOF
-if { (eval echo configure:1011: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1012: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
 then
   :
 else
@@ -1031,12 +1032,12 @@ EOF
 fi
 
 echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:1035: checking for off_t" >&5
+echo "configure:1036: 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 1040 "configure"
+#line 1041 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -1064,12 +1065,12 @@ EOF
 fi
 
 echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:1068: checking for size_t" >&5
+echo "configure:1069: 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 1073 "configure"
+#line 1074 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -1097,12 +1098,12 @@ EOF
 fi
 
 echo $ac_n "checking for st_rdev in struct stat""... $ac_c" 1>&6
-echo "configure:1101: checking for st_rdev in struct stat" >&5
+echo "configure:1102: checking for st_rdev in struct stat" >&5
 if eval "test \"`echo '$''{'ac_cv_struct_st_rdev'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1106 "configure"
+#line 1107 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/stat.h>
@@ -1110,7 +1111,7 @@ int main() {
 struct stat s; s.st_rdev;
 ; return 0; }
 EOF
-if { (eval echo configure:1114: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1115: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_struct_st_rdev=yes
 else
@@ -1132,12 +1133,12 @@ fi
 
 
 echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
-echo "configure:1136: checking for sys/wait.h that is POSIX.1 compatible" >&5
+echo "configure:1137: checking for sys/wait.h that is POSIX.1 compatible" >&5
 if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1141 "configure"
+#line 1142 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/wait.h>
@@ -1153,7 +1154,7 @@ wait (&s);
 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
 ; return 0; }
 EOF
-if { (eval echo configure:1157: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1158: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_header_sys_wait_h=yes
 else
@@ -1237,19 +1238,7 @@ fi
 
 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
 
-# Transform confdefs.h into DEFS.
-# Protect against shell expansion while executing Makefile rules.
-# Protect against Makefile macro expansion.
-cat > conftest.defs <<\EOF
-s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
-s%[    `~#$^&*(){}\\|;'"<>?]%\\&%g
-s%\[%\\&%g
-s%\]%\\&%g
-s%\$%$$%g
-EOF
-DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
-rm -f conftest.defs
-
+DEFS=-DHAVE_CONFIG_H
 
 # Without the "./", some shells look in PATH for config.status.
 : ${CONFIG_STATUS=./config.status}
@@ -1363,7 +1352,7 @@ EOF
 
 cat >> $CONFIG_STATUS <<EOF
 
-CONFIG_FILES=\${CONFIG_FILES-"Makefile config.h"}
+CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
 EOF
 cat >> $CONFIG_STATUS <<\EOF
 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
@@ -1422,6 +1411,113 @@ s%@INSTALL@%$INSTALL%g
 fi; done
 rm -f conftest.s*
 
+# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
+# NAME is the cpp macro being defined and VALUE is the value it is being given.
+#
+# ac_d sets the value in "#define NAME VALUE" lines.
+ac_dA='s%^\([  ]*\)#\([        ]*define[       ][      ]*\)'
+ac_dB='\([     ][      ]*\)[^  ]*%\1#\2'
+ac_dC='\3'
+ac_dD='%g'
+# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
+ac_uA='s%^\([  ]*\)#\([        ]*\)undef\([    ][      ]*\)'
+ac_uB='\([     ]\)%\1#\2define\3'
+ac_uC=' '
+ac_uD='\4%g'
+# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
+ac_eA='s%^\([  ]*\)#\([        ]*\)undef\([    ][      ]*\)'
+ac_eB='$%\1#\2define\3'
+ac_eC=' '
+ac_eD='%g'
+
+if test "${CONFIG_HEADERS+set}" != set; then
+EOF
+cat >> $CONFIG_STATUS <<EOF
+  CONFIG_HEADERS="config.h"
+EOF
+cat >> $CONFIG_STATUS <<\EOF
+fi
+for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
+  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
+  case "$ac_file" in
+  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
+       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
+  *) ac_file_in="${ac_file}.in" ;;
+  esac
+
+  echo creating $ac_file
+
+  rm -f conftest.frag conftest.in conftest.out
+  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
+  cat $ac_file_inputs > conftest.in
+
+EOF
+
+# Transform confdefs.h into a sed script conftest.vals that substitutes
+# the proper values into config.h.in to produce config.h.  And first:
+# Protect against being on the right side of a sed subst in config.status.
+# Protect against being in an unquoted here document in config.status.
+rm -f conftest.vals
+cat > conftest.hdr <<\EOF
+s/[\\&%]/\\&/g
+s%[\\$`]%\\&%g
+s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
+s%ac_d%ac_u%gp
+s%ac_u%ac_e%gp
+EOF
+sed -n -f conftest.hdr confdefs.h > conftest.vals
+rm -f conftest.hdr
+
+# This sed command replaces #undef with comments.  This is necessary, for
+# example, in the case of _POSIX_SOURCE, which is predefined and required
+# on some systems where configure will not decide to define it.
+cat >> conftest.vals <<\EOF
+s%^[   ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
+EOF
+
+# Break up conftest.vals because some shells have a limit on
+# the size of here documents, and old seds have small limits too.
+
+rm -f conftest.tail
+while :
+do
+  ac_lines=`grep -c . conftest.vals`
+  # grep -c gives empty output for an empty file on some AIX systems.
+  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
+  # Write a limited-size here document to conftest.frag.
+  echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
+  sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
+  echo 'CEOF
+  sed -f conftest.frag conftest.in > conftest.out
+  rm -f conftest.in
+  mv conftest.out conftest.in
+' >> $CONFIG_STATUS
+  sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
+  rm -f conftest.vals
+  mv conftest.tail conftest.vals
+done
+rm -f conftest.vals
+
+cat >> $CONFIG_STATUS <<\EOF
+  rm -f conftest.frag conftest.h
+  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
+  cat conftest.in >> conftest.h
+  rm -f conftest.in
+  if cmp -s $ac_file conftest.h 2>/dev/null; then
+    echo "$ac_file is unchanged"
+    rm -f conftest.h
+  else
+    # Remove last slash and all that follows it.  Not all systems have dirname.
+      ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
+      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
+      # The file is in a subdirectory.
+      test ! -d "$ac_dir" && mkdir "$ac_dir"
+    fi
+    rm -f $ac_file
+    mv conftest.h $ac_file
+  fi
+fi; done
+
 EOF
 cat >> $CONFIG_STATUS <<EOF
 
index 74f2894c345df80dbb88ef322feb804c396c176e..557404cf7e2c4a0e8fa8a3860138f35023f0ab19 100644 (file)
@@ -1,5 +1,6 @@
 dnl Process this file with autoconf to produce a configure script.
 AC_INIT(file.c)
+AC_CONFIG_HEADER(config.h)
 
 dnl Checks for programs.
 AC_PROG_CC
@@ -15,4 +16,4 @@ AC_STRUCT_ST_RDEV
 dnl Checks for headers
 AC_HEADER_SYS_WAIT
 
-AC_OUTPUT(Makefile config.h)
+AC_OUTPUT(Makefile)
index ee8b691223ecbae8176c3eac43350245aa4b7130..a4c706191770904071f296b914cc8835cc7bb2a5 100644 (file)
 0      lelong  0x13579ace      GNU dbm 1.x or ndbm database, little endian
 0      string  GDBM            GNU dbm 2.x database
 #
-0      belong  0x061561        Berkeley DB Hash file
+0      belong  0x061561        Berkeley DB
+>4     belong  >2              1.86
+>4     belong  <3              1.85
+>8     belong  4321            Hash/Big Endian
+>8     belong  1234            Hash/Little Endian
 >4     belong  >0              (Version %d,
->8     belong  1234            Little Endian,
->8     belong  4321            Big Endian,
 >12    belong  x               Bucket Size %d,
 >16    belong  x               Bucket Shift %d,
 >20    belong  x               Directory Size %d,
 >56    belong  x               Number of Keys %d)
 #
 #
-0      belong  0x053162        Berkeley DB Btree file/Big Endian
+0      belong  0x053162        Berkeley DB 1.85/1.86 Btree/Big Endian
 >4     belong  >0              (Version %d,
 >8     belong  x               Page Size %d,
 >12    belong  x               Free Page %d,
 >16    belong  x               Number of Records %d,
 >20    belong  x               Flags 0x%x)
-0      lelong  0x053162        Berkeley DB Btree file/Little Endian
+0      lelong  0x053162        Berkeley DB 1.85/1.86 Btree/Little Endian
 >4     lelong  >0              (Version %d,
 >8     lelong  x               Page Size %d,
 >12    lelong  x               Free Page %d,
 >16    lelong  x               Number of Records %d,
 >20    lelong  x               Flags 0x%x)
+#
+#
+12     belong  0x061561        Berkeley DB 2.X Hash/Big Endian
+>16    belong  >0              (Version %d)
+12     lelong  0x061561        Berkeley DB 2.X Hash/Little Endian
+>16    lelong  >0              (Version %d)
+
+12     belong  0x053162        Berkeley DB 2.X Btree/Big Endian
+>16    belong  >0              (Version %d)
+12     lelong  0x053162        Berkeley DB 2.X Btree/Little Endian
+>16    lelong  >0              (Version %d)
index 9e651465efd1b6a296cf75f798e8ae3b5bc4f4ad..81a9b82ab8d87860b4109d376cea29d2b88d9139 100644 (file)
@@ -6,3 +6,8 @@
 0      string          ***\            'diff' output text
 0      string          Only\ in\       'diff' output text
 0      string          Common\ subdirectories:\        'diff' output text
+
+# xdelta is like diff(1) for binary files (works for text, too).
+# Available from: ftp://ftp.xcf.berkeley.edu/pub/xdelta/
+0       string          %XDZ            xdelta diff file
+>4      string          >%              version %.3s
index e1408ed5dd7ec181670e2b3d01a6a78b5b0e3930..411a9ba3970a29c35043f1f313bbb402bc4a2b40 100644 (file)
 >>18   beshort         39              Motorola RCE,
 >>18   beshort         40              Advanced RISC Machines ARM,
 >>18   beshort         41              Alpha,
->>18   leshort         42              Hitachi SH,
->>18   beshort         43              SPARC V9 - invalid byte order,
+>>18   beshort         42              Hitachi SH,
+>>18   beshort         43              SPARC V9,
 >>18   beshort         44              Siemens Tricore Embedded Processor,
 >>18   beshort         45              Argonaut RISC Core, Argonaut Technologies Inc.,
 >>18   beshort         46              Hitachi H8/300,
index e256abfd05a13e76383df4871434a34e659d5729..89e77727ea4e40dfd00ea56c172d6994772caad9 100644 (file)
@@ -5,4 +5,4 @@
 # From <rgooch@atnf.csiro.au>
 
 0      string          KarmaRHD Version        Karma Data Structure Version
->16    long            x               %lu
+>16    belong          x               %lu
index 40aeb61b65648321d18664becd36959873790443..ffe5a6bba023b529f2281591b99c698b39ef00d5 100644 (file)
@@ -1,7 +1,7 @@
 # Generated automatically from Makefile.in by configure.
 # Makefile for file(1) cmd. 
 # Copyright (c) Ian F. Darwin 86/09/01 - see LEGAL.NOTICE.
-# @(#)$Id: Makefile,v 1.57 1998/06/27 14:01:39 christos Exp $
+# @(#)$Id: Makefile,v 1.58 1999/01/13 15:43:58 christos Exp $
 #
 # This software is not subject to any license of the American Telephone
 # and Telegraph Company or of the Regents of the University of California.
 #    ever read sources, credits must appear in the documentation.
 #
 # 4. This notice may not be removed or altered.
-VERSION        = 3.25
+VERSION        = 3.26
 SHELL  = /bin/sh
 #MAGIC = /etc/magic
 prefix = /usr/local
 INSTALLCMD = /usr/bin/install -c
 MAGICDIR = ${prefix}/share
 MAGIC  = $(MAGICDIR)/magic
-DEFS   = -DMAGIC='"$(MAGIC)"' -DBUILTIN_ELF -DHAVE_CONFIG_H
+DEFS   = -DMAGIC='"$(MAGIC)"' -DBUILTIN_ELF -DELFCORE -DHAVE_CONFIG_H
 CPPFLAGS = $(DEFS)
 CC     = gcc
 #COPTS = -O -g         # newer compilers allow both; else drop -O
@@ -85,8 +85,9 @@ HDRS = file.h names.h patchlevel.h readelf.h tar.h
 
 AUTOSRC=configure configure.in install-sh config.h.in Makefile.in
 ALLSRC = LEGAL.NOTICE README MAINT PORTING $(SRCS) $(HDRS) \
-        Makefile.std file.man magic.man magic2mime $(AUTOSRC)
-ALLMAGIC =   Magdir/Makefile Magdir/Localstuff Magdir/Header Magdir/[a-z]*
+        Makefile.std file.man magic.man magic2mime $(AUTOSRC) \
+        Localstuff Header
+ALLMAGIC =   Magdir/[a-z]*
 
 all:           file magic file.${MANCEXT} magic.${MANFEXT}
 
@@ -102,9 +103,8 @@ file:               $(OBJS)
                $(CC) $(CFLAGS) $(LDFLAGS) $(OBJS) -o $@
 lint:          $(SRCS)
                lint -ha $(DEFS) $(SRCS) | tee $@
-magic:         Magdir
-#              Magdir/Makefile's "install" mv's magic to here for testing.
-               cd Magdir; $(MAKE) install
+magic:         Header Localstuff Magdir
+               cat Header Localstuff Magdir/[a-z]* > $@
 
 ascmagic.o:    names.h
 
index efd00d4ead242e7957a55e368d9c115bf167a8a2..160ec267b6c6ce7d1fcb88793f56998a267557a5 100644 (file)
@@ -1,19 +1,20 @@
+/* config.h.  Generated automatically by configure.  */
 /* config.h.in.  Generated automatically from configure.in by autoheader.  */
 
 /* Define to empty if the keyword does not work.  */
-#undef const
+/* #undef const */
 
 /* Define if your struct stat has st_rdev.  */
-#undef HAVE_ST_RDEV
+#define HAVE_ST_RDEV 1
 
 /* Define if you have <sys/wait.h> that is POSIX.1 compatible.  */
-#undef HAVE_SYS_WAIT_H
+#define HAVE_SYS_WAIT_H 1
 
 /* Define to `long' if <sys/types.h> doesn't define.  */
-#undef off_t
+/* #undef off_t */
 
 /* Define to `unsigned' if <sys/types.h> doesn't define.  */
-#undef size_t
+/* #undef size_t */
 
 /* Define if you have the ANSI C header files.  */
-#undef STDC_HEADERS
+#define STDC_HEADERS 1
index ed102b658e411ce9677c9f420404517683982fa3..1347549fef79967846b523afb2670162db56f39d 100644 (file)
@@ -50,7 +50,7 @@
 #include "file.h"
 
 #ifndef        lint
-FILE_RCSID("@(#)$Id: file.c,v 1.42 1998/09/12 13:17:52 christos Exp $")
+FILE_RCSID("@(#)$Id: file.c,v 1.43 1999/01/13 15:44:03 christos Exp $")
 #endif /* lint */
 
 
@@ -94,8 +94,8 @@ int main __P((int, char *[]));
  */
 int
 main(argc, argv)
-int argc;
-char *argv[];
+       int argc;
+       char *argv[];
 {
        int c;
        int check = 0, didsomefiles = 0, errflg = 0, ret = 0, app = 0;
index 60cd42d0ff61a240d8ec77631eca0f535c765156..0adceea9cdd2489916e29b048874f1ee5a592c87 100644 (file)
@@ -1,6 +1,6 @@
 /*
  * file.h - definitions for file(1) program
- * @(#)$Id: file.h,v 1.27 1998/06/27 13:57:23 christos Exp $
+ * @(#)$Id: file.h,v 1.28 1999/01/13 15:44:05 christos Exp $
  *
  * Copyright (c) Ian F. Darwin, 1987.
  * Written by Ian F. Darwin.
@@ -46,12 +46,12 @@ struct magic {
 #define ADD    4               /* if '>&' appears,  */
        short cont_level;       /* level of ">" */
        struct {
-               char type;      /* byte short long */
+               unsigned char type;     /* byte short long */
                int32 offset;   /* offset from indirection */
        } in;
        int32 offset;           /* offset to magic number */
        unsigned char reln;     /* relation (0=eq, '>'=gt, etc) */
-       char type;              /* int, short, long or string. */
+       unsigned char type;     /* int, short, long or string. */
        char vallen;            /* length of string value, if any */
 #define                        BYTE    1
 #define                                SHORT   2
index addbc196973b86383756c72788863f7077c75254..00af8e3c0f31773179d1c016ab191e977e21ee78 100644 (file)
@@ -53,7 +53,7 @@
 #include "file.h"
 
 #ifndef        lint
-FILE_RCSID("@(#)$Id: fsmagic.c,v 1.27 1998/06/27 13:23:39 christos Exp $")
+FILE_RCSID("@(#)$Id: fsmagic.c,v 1.28 1999/01/13 15:44:06 christos Exp $")
 #endif /* lint */
 
 int
@@ -92,16 +92,30 @@ struct stat *sb;
                return 1;
        case S_IFCHR:
 #ifdef HAVE_ST_RDEV
+# ifdef dv_unit
+               (void) printf("character special (%d/%d/%d)",
+                       major(sb->st_rdev),
+                       dv_unit(sb->st_rdev),
+                       dv_subunit(sb->st_rdev));
+# else
                (void) printf("character special (%ld/%ld)",
                        (long) major(sb->st_rdev), (long) minor(sb->st_rdev));
+# endif
 #else
                (void) printf("character special");
 #endif
                return 1;
        case S_IFBLK:
 #ifdef HAVE_ST_RDEV
+# ifdef dv_unit
+               (void) printf("block special (%d/%d/%d)",
+                       major(sb->st_rdev),
+                       dv_unit(sb->st_rdev),
+                       dv_subunit(sb->st_rdev));
+# else
                (void) printf("block special (%ld/%ld)",
                        (long) major(sb->st_rdev), (long) minor(sb->st_rdev));
+# endif
 #else
                (void) printf("block special");
 #endif
index c905d73726298282d037bce5d5ae04444fb2601f..de93e9e07002925146992c87a2aef2d23f7abd18 100644 (file)
@@ -5,7 +5,7 @@
  * Pubic Domain version written 26 Aug 1985 John Gilmore (ihnp4!hoptoad!gnu).
  *
  * @(#)list.c 1.18 9/23/86 Public Domain - gnu
- * $Id: is_tar.c,v 1.10 1998/06/27 13:23:39 christos Exp $
+ * $Id: is_tar.c,v 1.11 1999/01/13 15:44:07 christos Exp $
  *
  * Comments changed and some code/comments reformatted
  * for file command by Ian Darwin.
@@ -18,7 +18,7 @@
 #include "file.h"
 
 #ifndef lint
-FILE_RCSID("@(#)$Id: is_tar.c,v 1.10 1998/06/27 13:23:39 christos Exp $")
+FILE_RCSID("@(#)$Id: is_tar.c,v 1.11 1999/01/13 15:44:07 christos Exp $")
 #endif
 
 #define        isodigit(c)     ( ((c) >= '0') && ((c) <= '7') )
@@ -87,7 +87,7 @@ from_oct(digs, where)
 {
        register int    value;
 
-       while (isspace(*where)) {               /* Skip spaces */
+       while (isspace((unsigned char)*where)) {                /* Skip spaces */
                where++;
                if (--digs <= 0)
                        return -1;              /* All blank field */
@@ -98,7 +98,7 @@ from_oct(digs, where)
                --digs;
        }
 
-       if (digs > 0 && *where && !isspace(*where))
+       if (digs > 0 && *where && !isspace((unsigned char)*where))
                return -1;                      /* Ended on non-space/nul */
 
        return value;
index 9090652d56b7d0791896f2bce1bc678d3552fd7a..a5d339d60c2256298c067c609380d363b14c1980 100644 (file)
@@ -10,7 +10,7 @@
  *
  * See LEGAL.NOTICE
  *
- * $Id: names.h,v 1.15 1998/09/12 13:17:52 christos Exp $
+ * $Id: names.h,v 1.16 1999/01/13 15:44:08 christos Exp $
  */
 
 /* these types are used to index the table 'types': keep em in sync! */
@@ -104,7 +104,6 @@ static struct names {
        {"double",      L_C},
        {"extern",      L_C},
        {"float",       L_C},
-       {"real",        L_C},
        {"struct",      L_C},
        {"union",       L_C},
        {"CFLAGS",      L_MAKE},
index 511955306ac5fe63dbe0bf10ced0d8e70353f5eb..5814de52bb6c4daa91a686aebb3480d7f15534fb 100644 (file)
@@ -39,7 +39,7 @@
 #include "file.h"
 
 #ifndef lint
-FILE_RCSID("@(#)$Id: print.c,v 1.26 1998/06/27 13:57:23 christos Exp $")
+FILE_RCSID("@(#)$Id: print.c,v 1.27 1999/01/13 15:44:09 christos Exp $")
 #endif  /* lint */
 
 #define SZOF(a)        (sizeof(a) / sizeof(a[0]))
@@ -58,15 +58,14 @@ struct magic *m;
 
        if (m->flag & INDIR)
                (void) fprintf(stderr, "(%s,%d),",
-                              (m->in.type >= 0 && m->in.type < SZOF(typ)) ? 
-                                       typ[(unsigned char) m->in.type] :
-                                       "*bad*",
+                              /* Note: in.type is unsigned */
+                              (m->in.type < SZOF(typ)) ? 
+                                       typ[m->in.type] : "*bad*",
                               m->in.offset);
 
        (void) fprintf(stderr, " %s%s", (m->flag & UNSIGNED) ? "u" : "",
-                      (m->type >= 0 && m->type < SZOF(typ)) ? 
-                               typ[(unsigned char) m->type] : 
-                               "*bad*");
+                      /* Note: type is unsigned */
+                      (m->type < SZOF(typ)) ? typ[m->type] : "*bad*");
        if (m->mask != ~((uint32)0))
                (void) fprintf(stderr, " & %.8x", m->mask);
 
index 162459f5199f98311e52f35699de21d900cc9d32..c5fce4ed7198e8c957be3bed0c00d104759374d4 100644 (file)
--- a/src/tar.h
+++ b/src/tar.h
@@ -5,7 +5,7 @@
  *
  * Created 25 August 1985 by John Gilmore, ihnp4!hoptoad!gnu.
  *
- * $Id: tar.h,v 1.4 1998/06/27 13:57:23 christos Exp $ # checkin only
+ * $Id: tar.h,v 1.5 1999/01/13 15:44:10 christos Exp $ # checkin only
  */
 
 /*
@@ -172,10 +172,6 @@ TAR_EXTERN char            read_error_flag;
  * Declarations of functions available to the world.
  */
 /*LINTLIBRARY*/
-union record *findrec();
-void userec();
-union record *endofrecs();
-void anno();
 #define         annorec(stream, msg)   anno(stream, msg, 0)    /* Cur rec */
 #define        annofile(stream, msg)   anno(stream, msg, 1)    /* Saved rec */
 #endif