]> Dogcows Code - chaz/tar/commitdiff
tar: update ancient configure cruft
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 3 Jan 2014 19:48:40 +0000 (11:48 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 3 Jan 2014 19:48:57 +0000 (11:48 -0800)
* configure.ac: Use AC_PROG_CC_STDC, not just AC_PROG_CC.
Remove obsolete macros AC_ISC_POSIX, AC_HEADER_SYS_WAIT,
AC_HEADER_DIRENT, AC_HEADER_STAT, AC_HEADER_STDC, AC_TYPE_SIGNAL,
AC_TYPE_SIZE_T.
* lib/prepargs.c (IN_CTYPE_DOMAIN): Remove.  All uses removed.
* src/list.c (from_header): Use isspace, not ISSPACE.
* src/system.c (pipe_handler, sys_exec_info_script):
* src/tar.c (sigstat):
Use void, not RETSIGTYPE.

configure.ac
lib/prepargs.c
src/list.c
src/system.c
src/tar.c

index c9d1250ebf83236170457252bd2decb000fd644e..cf97df16ec3a97acaee21128c89d5d023a21d0e3 100644 (file)
@@ -27,14 +27,13 @@ AM_INIT_AUTOMAKE([1.11 gnits tar-ustar dist-bzip2 dist-xz dist-shar std-options
 # Enable silent rules by default:
 AM_SILENT_RULES([yes])
 
-AC_PROG_CC
+AC_PROG_CC_STDC
 AC_EXEEXT
 AC_PROG_RANLIB
 AC_PROG_YACC
 gl_EARLY
 
 AC_SYS_LARGEFILE
-AC_ISC_POSIX
 AC_C_INLINE
 
 AC_CHECK_HEADERS_ONCE(fcntl.h linux/fd.h memory.h net/errno.h \
@@ -49,12 +48,7 @@ AC_CHECK_HEADERS([sys/buf.h], [], [],
 #include <sys/param.h>
 #endif])
 
-AC_HEADER_SYS_WAIT
-
-AC_HEADER_DIRENT
 AC_HEADER_MAJOR
-AC_HEADER_STAT
-AC_HEADER_STDC
 
 AC_MSG_CHECKING([for st_fstype string in struct stat])
 AC_CACHE_VAL(diff_cv_st_fstype_string,
@@ -91,11 +85,9 @@ else
   export enable_acl=no
 fi
 
-AC_TYPE_SIGNAL
 AC_TYPE_MODE_T
 AC_TYPE_PID_T
 AC_TYPE_OFF_T
-AC_TYPE_SIZE_T
 AC_TYPE_UID_T
 AC_CHECK_TYPE(major_t, , AC_DEFINE(major_t, int,
                                   [Type of major device numbers.]))
index 9b30d2493bffad74ef5718e50985b916b4e05b92..068688b1afdf902310718cbf4a8e9a5a396e476a 100644 (file)
 
 #include <ctype.h>
 
-/* IN_CTYPE_DOMAIN (C) is nonzero if the unsigned char C can safely be given
-   as an argument to <ctype.h> macros like "isspace".  */
-#ifdef STDC_HEADERS
-# define IN_CTYPE_DOMAIN(c) 1
-#else
-# define IN_CTYPE_DOMAIN(c) ((c) <= 0177)
-#endif
-
-#define ISSPACE(c) (IN_CTYPE_DOMAIN (c) && isspace (c))
-
 /* Find the white-space-separated options specified by OPTIONS, and
    using BUF to store copies of these options, set ARGV[0], ARGV[1],
    etc. to the option copies.  Return the number N of options found.
@@ -53,7 +43,7 @@ prepend_args (char const *options, char *buf, char **argv)
 
   for (;;)
     {
-      while (ISSPACE ((unsigned char) *o))
+      while (isspace ((unsigned char) *o))
        o++;
       if (!*o)
        return n;
@@ -64,7 +54,7 @@ prepend_args (char const *options, char *buf, char **argv)
       do
        if ((*b++ = *o++) == '\\' && *o)
          b[-1] = *o++;
-      while (*o && ! ISSPACE ((unsigned char) *o));
+      while (*o && ! isspace ((unsigned char) *o));
 
       *b++ = '\0';
     }
index 858aa7391b4f570dce2d80ea0bd788d4501b8846..094f64904d638f3cddb0ee8d11a48105fffdd299 100644 (file)
@@ -723,7 +723,7 @@ from_header (char const *where0, size_t digs, char const *type,
                    type));
          return -1;
        }
-      if (!ISSPACE ((unsigned char) *where))
+      if (!isspace ((unsigned char) *where))
        break;
       where++;
     }
@@ -861,7 +861,7 @@ from_header (char const *where0, size_t digs, char const *type,
        value = -value;
     }
 
-  if (where != lim && *where && !ISSPACE ((unsigned char) *where))
+  if (where != lim && *where && !isspace ((unsigned char) *where))
     {
       if (type)
        {
index e1fd263c7daabe55c54e83832efb62c21093763f..8c0bce5dd83c2adf8ad854daec84e0c8606d306c 100644 (file)
@@ -720,7 +720,7 @@ stat_to_env (char *name, char type, struct tar_stat_info *st)
 }
 
 static pid_t global_pid;
-static RETSIGTYPE (*pipe_handler) (int sig);
+static void (*pipe_handler) (int sig);
 
 int
 sys_exec_command (char *file_name, int typechar, struct tar_stat_info *st)
@@ -788,7 +788,7 @@ sys_exec_info_script (const char **archive_name, int volume_number)
   pid_t pid;
   char uintbuf[UINTMAX_STRSIZE_BOUND];
   int p[2];
-  static RETSIGTYPE (*saved_handler) (int sig);
+  static void (*saved_handler) (int sig);
 
   xpipe (p);
   saved_handler = signal (SIGPIPE, SIG_IGN);
index 4f5017d0ff4a3d79936c0cc6a63fe88f05f29dc0..6fb9277fdda95cfbfecc0f81137b737bbc0c8c2e 100644 (file)
--- a/src/tar.c
+++ b/src/tar.c
@@ -990,7 +990,7 @@ set_use_compress_program_option (const char *string)
   use_compress_program_option = string;
 }
 \f
-static RETSIGTYPE
+static void
 sigstat (int signo)
 {
   compute_duration ();
@@ -1775,7 +1775,7 @@ parse_opt (int key, char *arg, struct argp_state *state)
     case KEEP_DIRECTORY_SYMLINK_OPTION:
       keep_directory_symlink_option = true;
       break;
-      
+
     case KEEP_NEWER_FILES_OPTION:
       old_files_option = KEEP_NEWER_FILES;
       break;
@@ -2220,7 +2220,7 @@ static int subcommand_class[] = {
 
 /* Return t if the subcommand_option is in class(es) f */
 #define IS_SUBCOMMAND_CLASS(f) (subcommand_class[subcommand_option] & (f))
-  
+
 static struct tar_args args;
 
 static void
@@ -2493,7 +2493,7 @@ decode_options (int argc, char **argv)
                  _("--%s option cannot be used with %s"),
                  starting_file_option ? "starting-file" : "same-order",
                  subcommand_string (subcommand_option)));
-  
+
   /* If ready to unlink hierarchies, so we are for simpler files.  */
   if (recursive_unlink_option)
     old_files_option = UNLINK_FIRST_OLD_FILES;
This page took 0.027112 seconds and 4 git commands to generate.