From 8c37efbf003ebb2fa99287b31be8914052b58e5f Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Tue, 3 Aug 2004 18:40:30 +0000 Subject: [PATCH] Remove "fatal" module. --- ChangeLog | 5 ++++ MODULES.html.sh | 1 - lib/ChangeLog | 4 +++ lib/fatal.c | 62 -------------------------------------------- lib/fatal.h | 68 ------------------------------------------------- m4/ChangeLog | 4 +++ m4/fatal.m4 | 13 ---------- modules/fatal | 24 ----------------- 8 files changed, 13 insertions(+), 168 deletions(-) delete mode 100644 lib/fatal.c delete mode 100644 lib/fatal.h delete mode 100644 m4/fatal.m4 delete mode 100644 modules/fatal diff --git a/ChangeLog b/ChangeLog index 480cd1a418..f0d5a037cc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2004-08-03 Paul Eggert + + * modules/fatal: Remove, as the "fatal" module wasn't used or working. + * MODULES.html.sh (func_all_modules): Remove fatal. + 2004-07-19 Bruno Haible * MODULES.html.sh (func_all_modules): Add dummy. diff --git a/MODULES.html.sh b/MODULES.html.sh index cf222dabf1..bd1e585182 100755 --- a/MODULES.html.sh +++ b/MODULES.html.sh @@ -1909,7 +1909,6 @@ func_all_modules () func_module c-stack func_module error func_module extensions - func_module fatal func_module getdomainname func_module xgetdomainname func_module getloadavg diff --git a/lib/ChangeLog b/lib/ChangeLog index 11b2daf499..9af9b1fc24 100644 --- a/lib/ChangeLog +++ b/lib/ChangeLog @@ -1,3 +1,7 @@ +2004-08-03 Paul Eggert + + * fatal.c, fatal.h: Remove as the "fatal" module wasn't used or working. + 2004-07-16 Simon Josefsson * dummy.c: New file. diff --git a/lib/fatal.c b/lib/fatal.c deleted file mode 100644 index 79e8a346e0..0000000000 --- a/lib/fatal.c +++ /dev/null @@ -1,62 +0,0 @@ -/* Fatal exits for noninteractive utilities - - Copyright (C) 2001, 2003 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2, or (at your option) - any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License along - with this program; if not, write to the Free Software Foundation, - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ - -#ifdef HAVE_CONFIG_H -# include -#endif - -#include "fatal.h" - -#include "exit.h" -#include -#include -#include -#include - -#ifdef _LIBC -# define program_name program_invocation_name -#else /* not _LIBC */ -/* The calling program should define program_name and set it to the - name of the executing program. */ -extern char *program_name; -#endif - -#include "unlocked-io.h" - -/* Like error, but always exit with EXIT_FAILURE. */ - -void -fatal (int errnum, const char *message, ...) -{ - va_list args; - - if (error_print_progname) - (*error_print_progname) (); - else - { - fflush (stdout); - fprintf (stderr, "%s: ", program_name); - } - - va_start (args, message); - error (EXIT_FAILURE, errnum, message, args); - - /* The following code isn't reachable, but pacifies some compilers. */ - va_end (args); - abort (); -} diff --git a/lib/fatal.h b/lib/fatal.h deleted file mode 100644 index e12f8851fc..0000000000 --- a/lib/fatal.h +++ /dev/null @@ -1,68 +0,0 @@ -#include "error.h" - -/* FIXME: this is all from ansidecl. better to simply swipe - that file from egcs/include and include it from here. */ - -/* Using MACRO(x,y) in cpp #if conditionals does not work with some - older preprocessors. Thus we can't define something like this: - -#define HAVE_GCC_VERSION(MAJOR, MINOR) \ - (__GNUC__ > (MAJOR) || (__GNUC__ == (MAJOR) && __GNUC_MINOR__ >= (MINOR))) - -and then test "#if HAVE_GCC_VERSION(2,7)". - -So instead we use the macro below and test it against specific values. */ - -/* This macro simplifies testing whether we are using gcc, and if it - is of a particular minimum version. (Both major & minor numbers are - significant.) This macro will evaluate to 0 if we are not using - gcc at all. */ -#ifndef GCC_VERSION -# define GCC_VERSION (__GNUC__ * 1000 + __GNUC_MINOR__) -#endif /* GCC_VERSION */ - -/* Define macros for some gcc attributes. This permits us to use the - macros freely, and know that they will come into play for the - version of gcc in which they are supported. */ - -#if (GCC_VERSION < 2007) -# define __attribute__(x) -#endif - -/* Attribute __malloc__ on functions was valid as of gcc 2.96. */ -#ifndef ATTRIBUTE_MALLOC -# if (GCC_VERSION >= 2096) -# define ATTRIBUTE_MALLOC __attribute__ ((__malloc__)) -# else -# define ATTRIBUTE_MALLOC -# endif /* GNUC >= 2.96 */ -#endif /* ATTRIBUTE_MALLOC */ - -/* Attributes on labels were valid as of gcc 2.93. */ -#ifndef ATTRIBUTE_UNUSED_LABEL -# if (GCC_VERSION >= 2093) -# define ATTRIBUTE_UNUSED_LABEL ATTRIBUTE_UNUSED -# else -# define ATTRIBUTE_UNUSED_LABEL -# endif /* GNUC >= 2.93 */ -#endif /* ATTRIBUTE_UNUSED_LABEL */ - -#ifndef ATTRIBUTE_UNUSED -# define ATTRIBUTE_UNUSED __attribute__ ((__unused__)) -#endif /* ATTRIBUTE_UNUSED */ - -#ifndef ATTRIBUTE_NORETURN -# define ATTRIBUTE_NORETURN __attribute__ ((__noreturn__)) -#endif /* ATTRIBUTE_NORETURN */ - -#ifndef ATTRIBUTE_PRINTF -# define ATTRIBUTE_PRINTF(m, n) __attribute__ ((__format__ (__printf__, m, n))) -# define ATTRIBUTE_PRINTF_1 ATTRIBUTE_PRINTF(1, 2) -# define ATTRIBUTE_PRINTF_2 ATTRIBUTE_PRINTF(2, 3) -# define ATTRIBUTE_PRINTF_3 ATTRIBUTE_PRINTF(3, 4) -# define ATTRIBUTE_PRINTF_4 ATTRIBUTE_PRINTF(4, 5) -# define ATTRIBUTE_PRINTF_5 ATTRIBUTE_PRINTF(5, 6) -#endif /* ATTRIBUTE_PRINTF */ - -extern void fatal (int errnum, const char *format, ...) - ATTRIBUTE_NORETURN ATTRIBUTE_PRINTF_2; diff --git a/m4/ChangeLog b/m4/ChangeLog index 999c481314..c7d51febc7 100644 --- a/m4/ChangeLog +++ b/m4/ChangeLog @@ -1,3 +1,7 @@ +2004-08-03 Paul Eggert + + * fatal.m4: Remove, as the "fatal" module wasn't used or working. + 2004-07-13 Robert Millan * host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g. diff --git a/m4/fatal.m4 b/m4/fatal.m4 deleted file mode 100644 index eea9b1c4ed..0000000000 --- a/m4/fatal.m4 +++ /dev/null @@ -1,13 +0,0 @@ -# fatal.m4 serial 3 -dnl Copyright (C) 2002, 2003 Free Software Foundation, Inc. -dnl This file is free software, distributed under the terms of the GNU -dnl General Public License. As a special exception to the GNU General -dnl Public License, this file may be distributed as part of a program -dnl that contains a configuration script generated by Autoconf, under -dnl the same distribution terms as the rest of that program. - -AC_DEFUN([gl_FATAL], -[ - dnl No prerequisites of lib/fatal.c. - : -]) diff --git a/modules/fatal b/modules/fatal deleted file mode 100644 index 45090ed4fe..0000000000 --- a/modules/fatal +++ /dev/null @@ -1,24 +0,0 @@ -Description: -Error reporting for fatal errors. - -Files: -lib/fatal.h -lib/fatal.c -m4/fatal.m4 - -Depends-on: -error -unlocked-io -exit - -configure.ac: -gl_FATAL - -Makefile.am: -lib_SOURCES += fatal.h fatal.c - -Include: -"fatal.h" - -Maintainer: - -- 2.30.2