From: Paul Eggert Date: Fri, 28 Jan 2005 23:23:32 +0000 (+0000) Subject: Sync from coreutils. X-Git-Tag: cvs-readonly~3557 X-Git-Url: http://erislabs.net/gitweb/?a=commitdiff_plain;h=854b4d80a126f835cbd39197a7d46577ae7b9d08;p=gnulib.git Sync from coreutils. * modules/getloadavg (Files): Remove m4/getloadavg.m4. (Depends-on): Add c-strtod. (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG. * m4/getloadavg.m4, m4/glibc.m4, m4/search-libs.m4: Remove. * m4/check-decl.m4, m4/jm-macros.m4, m4/lib-check.m4, m4/prereq.m4: Remove files that are specific to coreutils. --- diff --git a/ChangeLog b/ChangeLog index 77ce668e6..0699106a4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2005-01-28 Paul Eggert + + Sync from coreutils. + * modules/getloadavg (Files): Remove m4/getloadavg.m4. + (Depends-on): Add c-strtod. + (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG. + 2005-01-28 Bruno Haible * modules/javacomp: New file. diff --git a/MODULES.html b/MODULES.html index b44864531..9798f7027 100644 --- a/MODULES.html +++ b/MODULES.html @@ -2,7 +2,7 @@ Gnulib Module List - +

Gnulib Module List

@@ -933,6 +933,14 @@ usually the host name including FQDN. classpath Java CLASSPATH handling. + + javacomp + Compile a Java program. + + + javaexec + Execute a Java program. +

Misc

@@ -3034,6 +3042,20 @@ variables. + + + +
--- stdbool
xsetenv
xalloc
javacomp + #include "javacomp.h" + javacomp.c
javacomp.sh.in +
javacomp.m4
gt_JAVACOMP +
stdbool
xallocsa
execute
pipe
wait-process
classpath
xsetenv
sh-quote
safe-read
xalloc
error
gettext +
javaexec + #include "javaexec.h" + javaexec.c
javaexec.sh.in +
javaexec.m4
gt_JAVAEXEC +
stdbool
execute
classpath
xsetenv
sh-quote
pathname
xalloc
xallocsa
error
gettext +

Misc

@@ -3111,8 +3133,8 @@ variables. - -
getloadavg --- getloadavg.c - getloadavg.m4
gl_FUNC_GETLOADAVG -
cloexec
xalloc +
AC_FUNC_GETLOADAVG + cloexec
xalloc
c-strtod
getpagesize @@ -3209,13 +3231,6 @@ variables. openat
javaexec - #include "javaexec.h" - javaexec.c
javaexec.sh.in -
javaexec.m4
gt_JAVAEXEC -
stdbool
execute
classpath
xsetenv
sh-quote
pathname
xalloc
xallocsa
error
gettext -
openat #include "openat.h" openat.c @@ -3226,22 +3241,16 @@ variables.

Lone files - please create new modules containing them

 lib/progreloc.c
-m4/check-decl.m4
 m4/d-type.m4
-m4/glibc.m4
 m4/host-os.m4
-m4/jm-macros.m4
 m4/jm-winsz1.m4
 m4/jm-winsz2.m4
-m4/lib-check.m4
 m4/link-follow.m4
 m4/onceonly.m4
 m4/perl.m4
-m4/prereq.m4
 m4/ptrdiff_max.m4
 m4/readdir.m4
 m4/rmdir-errno.m4
-m4/search-libs.m4
 m4/st_dm_mode.m4
 m4/uintptr_t.m4
 m4/unlink-busy.m4
@@ -3259,6 +3268,6 @@ variables.
       
  • A testsuite
    - Generated from MODULES.html.sh on 27 January 2005. + Generated from MODULES.html.sh on 28 January 2005. diff --git a/m4/ChangeLog b/m4/ChangeLog index 72ef179a0..7a5e35cd2 100644 --- a/m4/ChangeLog +++ b/m4/ChangeLog @@ -1,3 +1,11 @@ +2005-01-28 Paul Eggert + + Sync from coreutils. + * getloadavg.m4, glibc.m4, search-libs.m4: Remove. + + Remove files that are specific to coreutils. + * check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove. + 2005-01-28 Bruno Haible * javacomp.m4: New file, from GNU gettext. diff --git a/m4/check-decl.m4 b/m4/check-decl.m4 deleted file mode 100644 index d70e1c90f..000000000 --- a/m4/check-decl.m4 +++ /dev/null @@ -1,75 +0,0 @@ -#serial 20 - -dnl This is just a wrapper function to encapsulate this kludge. -dnl Putting it in a separate file like this helps share it between -dnl different packages. -AC_DEFUN([gl_CHECK_DECLS], -[ - AC_REQUIRE([_gl_DECL_HEADERS]) - AC_REQUIRE([AC_HEADER_TIME]) - headers=' -#include -#include -#include - -#if HAVE_UNISTD_H -# include -#endif - -#include -#if TIME_WITH_SYS_TIME -# include -# include -#else -# if HAVE_SYS_TIME_H -# include -# else -# include -# endif -#endif - -#if HAVE_UTMP_H -# include -#endif - -#if HAVE_GRP_H -# include -#endif - -#if HAVE_PWD_H -# include -#endif -' - - AC_CHECK_DECLS([ - free, - getenv, - geteuid, - getgrgid, - getlogin, - getpwuid, - getuid, - getutent, - lseek, - malloc, - memchr, - memrchr, - nanosleep, - realloc, - stpcpy, - strndup, - strnlen, - strstr, - strtoul, - strtoull, - ttyname], , , $headers) -]) - -dnl FIXME: when autoconf has support for it. -dnl This is a little helper so we can require these header checks. -AC_DEFUN([_gl_DECL_HEADERS], -[ - AC_REQUIRE([AC_HEADER_STDC]) - AC_CHECK_HEADERS(grp.h memory.h pwd.h string.h strings.h stdlib.h \ - unistd.h sys/time.h utmp.h utmpx.h) -]) diff --git a/m4/getloadavg.m4 b/m4/getloadavg.m4 deleted file mode 100644 index 567245ea8..000000000 --- a/m4/getloadavg.m4 +++ /dev/null @@ -1,125 +0,0 @@ -#serial 11 - -# A replacement for autoconf's macro by the same name. This version -# accepts an optional argument specifying the name of the $srcdir-relative -# directory in which the file getloadavg.c may be found. It is unusual -# (but justified, imho) that this file is required at ./configure time. - -undefine([AC_FUNC_GETLOADAVG]) - -# AC_FUNC_GETLOADAVG -# ------------------ -AC_DEFUN([AC_FUNC_GETLOADAVG], -[ac_have_func=no # yes means we've found a way to get the load average. - -AC_CHECK_HEADERS_ONCE(fcntl.h locale.h unistd.h) -AC_CHECK_HEADERS(mach/mach.h) -AC_CHECK_FUNCS(setlocale) - -# By default, expect to find getloadavg.c in $srcdir/. -ac_lib_dir_getloadavg=$srcdir -# But if there's an argument, DIR, expect to find getloadavg.c in $srcdir/DIR. -m4_ifval([$1], [ac_lib_dir_getloadavg=$srcdir/$1]) -# Make sure getloadavg.c is where it belongs, at ./configure-time. -test -f $ac_lib_dir_getloadavg/getloadavg.c \ - || AC_MSG_ERROR([getloadavg.c is not in $ac_lib_dir_getloadavg]) -# FIXME: Add an autoconf-time test, too? - -ac_save_LIBS=$LIBS - -# Check for getloadavg, but be sure not to touch the cache variable. -(AC_CHECK_FUNC(getloadavg, exit 0, exit 1)) && ac_have_func=yes - -# On HPUX9, an unprivileged user can get load averages through this function. -AC_CHECK_FUNCS(pstat_getdynamic) - -# Solaris has libkstat which does not require root. -AC_CHECK_LIB(kstat, kstat_open) -test $ac_cv_lib_kstat_kstat_open = yes && ac_have_func=yes - -# Some systems with -lutil have (and need) -lkvm as well, some do not. -# On Solaris, -lkvm requires nlist from -lelf, so check that first -# to get the right answer into the cache. -# For kstat on solaris, we need libelf to force the definition of SVR4 below. -if test $ac_have_func = no; then - AC_CHECK_LIB(elf, elf_begin, LIBS="-lelf $LIBS") -fi -if test $ac_have_func = no; then - AC_CHECK_LIB(kvm, kvm_open, LIBS="-lkvm $LIBS") - # Check for the 4.4BSD definition of getloadavg. - AC_CHECK_LIB(util, getloadavg, - [LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes]) -fi - -if test $ac_have_func = no; then - # There is a commonly available library for RS/6000 AIX. - # Since it is not a standard part of AIX, it might be installed locally. - ac_getloadavg_LIBS=$LIBS - LIBS="-L/usr/local/lib $LIBS" - AC_CHECK_LIB(getloadavg, getloadavg, - [LIBS="-lgetloadavg $LIBS"], [LIBS=$ac_getloadavg_LIBS]) -fi - -# Make sure it is really in the library, if we think we found it, -# otherwise set up the replacement function. -AC_CHECK_FUNCS(getloadavg, [], - [_AC_LIBOBJ_GETLOADAVG]) - -# Some definitions of getloadavg require that the program be installed setgid. -AC_CACHE_CHECK(whether getloadavg requires setgid, - ac_cv_func_getloadavg_setgid, -[AC_EGREP_CPP([Yowza Am I SETGID yet], -[#include "$ac_lib_dir_getloadavg/getloadavg.c" -#ifdef LDAV_PRIVILEGED -Yowza Am I SETGID yet -@%:@endif], - ac_cv_func_getloadavg_setgid=yes, - ac_cv_func_getloadavg_setgid=no)]) -if test $ac_cv_func_getloadavg_setgid = yes; then - NEED_SETGID=true - AC_DEFINE(GETLOADAVG_PRIVILEGED, 1, - [Define if the `getloadavg' function needs to be run setuid - or setgid.]) -else - NEED_SETGID=false -fi -AC_SUBST(NEED_SETGID)dnl - -if test $ac_cv_func_getloadavg_setgid = yes; then - AC_CACHE_CHECK(group of /dev/kmem, ac_cv_group_kmem, -[ # On Solaris, /dev/kmem is a symlink. Get info on the real file. - ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null` - # If we got an error (system does not support symlinks), try without -L. - test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem` - ac_cv_group_kmem=`echo $ac_ls_output \ - | sed -ne ['s/[ ][ ]*/ /g; - s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\) *.*/\1/; - / /s/.* //;p;']` -]) - AC_SUBST(KMEM_GROUP, $ac_cv_group_kmem)dnl -fi -if test "x$ac_save_LIBS" = x; then - GETLOADAVG_LIBS=$LIBS -else - GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$ac_save_LIBS!!"` -fi -LIBS=$ac_save_LIBS - -AC_SUBST(GETLOADAVG_LIBS)dnl -])# AC_FUNC_GETLOADAVG - - -AC_DEFUN([gl_FUNC_GETLOADAVG], -[ - AC_FUNC_GETLOADAVG([lib]) - dnl Note AC_FUNC_GETLOADAVG does AC_LIBOBJ(getloadavg). - if test $ac_cv_func_getloadavg = no; then - gl_PREREQ_GETLOADAVG - fi -]) - -# Prerequisites of lib/getloadavg.c not done by autoconf's AC_FUNC_GETLOADAVG. -AC_DEFUN([gl_PREREQ_GETLOADAVG], -[ - AC_CHECK_HEADERS_ONCE(fcntl.h unistd.h) -]) diff --git a/m4/glibc.m4 b/m4/glibc.m4 deleted file mode 100644 index 687405768..000000000 --- a/m4/glibc.m4 +++ /dev/null @@ -1,35 +0,0 @@ -#serial 3 - -dnl From Gordon Matzigkeit. -dnl Test for the GNU C Library. -dnl FIXME: this should migrate into libit. - -AC_DEFUN([AM_GLIBC], - [ - AC_CACHE_CHECK(whether we are using the GNU C Library, - ac_cv_gnu_library, - [AC_EGREP_CPP([Thanks for using GNU], - [ -#include -#ifdef __GNU_LIBRARY__ - Thanks for using GNU -#endif - ], - ac_cv_gnu_library=yes, - ac_cv_gnu_library=no) - ] - ) - AC_CACHE_CHECK(for version 2 of the GNU C Library, - ac_cv_glibc, - [AC_EGREP_CPP([Thanks for using GNU too], - [ -#include -#ifdef __GLIBC__ - Thanks for using GNU too -#endif - ], - ac_cv_glibc=yes, ac_cv_glibc=no) - ] - ) - ] -) diff --git a/m4/jm-macros.m4 b/m4/jm-macros.m4 deleted file mode 100644 index 567d2d1c3..000000000 --- a/m4/jm-macros.m4 +++ /dev/null @@ -1,291 +0,0 @@ -#serial 82 -*- autoconf -*- - -dnl Misc type-related macros for coreutils. - -# Copyright (C) 1998, 2000, 2001, 2002, 2003, 2004, 2005 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. - -# Written by Jim Meyering. - -AC_DEFUN([gl_MACROS], -[ - AC_PREREQ(2.58) - - GNU_PACKAGE="GNU $PACKAGE" - AC_DEFINE_UNQUOTED(GNU_PACKAGE, "$GNU_PACKAGE", - [The concatenation of the strings `GNU ', and PACKAGE.]) - AC_SUBST(GNU_PACKAGE) - - AM_MISSING_PROG(HELP2MAN, help2man) - AC_SUBST(OPTIONAL_BIN_PROGS) - AC_SUBST(MAN) - AC_SUBST(DF_PROG) - - dnl This macro actually runs replacement code. See isc-posix.m4. - AC_REQUIRE([AC_ISC_POSIX])dnl - - gl_CHECK_ALL_TYPES - - AC_REQUIRE([gl_HOST_OS]) - AC_REQUIRE([gl_ASSERT]) - AC_REQUIRE([gl_CHECK_TYPE_STRUCT_UTIMBUF]) - AC_REQUIRE([gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE]) - AC_REQUIRE([gl_CHECK_TYPE_STRUCT_DIRENT_D_INO]) - AC_REQUIRE([gl_CHECK_DECLS]) - - AC_REQUIRE([gl_PREREQ]) - - AC_REQUIRE([gl_FUNC_DIRFD]) - AC_REQUIRE([AC_FUNC_ACL]) - AC_REQUIRE([gl_FUNC_LCHOWN]) - AC_REQUIRE([fetish_FUNC_RMDIR_NOTEMPTY]) - AC_REQUIRE([gl_FUNC_CHOWN]) - AC_REQUIRE([AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK]) - AC_REQUIRE([AC_FUNC_STRERROR_R]) - AC_REQUIRE([gl_FUNC_GROUP_MEMBER]) - AC_REQUIRE([gl_AFS]) - AC_REQUIRE([gl_AC_FUNC_LINK_FOLLOWS_SYMLINK]) - AC_REQUIRE([gl_FUNC_FPENDING]) - - # This is for od and stat, and any other program that - # uses the PRI.MAX macros from inttypes.h. - AC_REQUIRE([gt_INTTYPES_PRI]) - AC_REQUIRE([gl_ULLONG_MAX]) - - AC_REQUIRE([gl_FUNC_GETGROUPS]) - - AC_REQUIRE([AC_FUNC_FSEEKO]) - AC_REQUIRE([AC_FUNC_ALLOCA]) - - AC_CONFIG_LIBOBJ_DIR([lib]) - AC_FUNC_GETLOADAVG([lib]) - - AC_REQUIRE([gl_SYS_PROC_UPTIME]) - AC_REQUIRE([gl_FUNC_FTRUNCATE]) - - # raise is used by at least sort and ls. - AC_REPLACE_FUNCS(raise) - - # By default, argmatch should fail calling usage (1). - AC_DEFINE(ARGMATCH_DIE, [usage (1)], - [Define to the function xargmatch calls on failures.]) - AC_DEFINE(ARGMATCH_DIE_DECL, [extern void usage ()], - [Define to the declaration of the xargmatch failure function.]) - - dnl Used to define SETVBUF in sys2.h. - dnl This evokes the following warning from autoconf: - dnl ...: warning: AC_TRY_RUN called without default to allow cross compiling - AC_FUNC_SETVBUF_REVERSED - - # used by sleep and shred - AC_REQUIRE([gl_CLOCK_TIME]) - AC_CHECK_FUNCS_ONCE(gettimeofday) - AC_FUNC_GETTIMEOFDAY_CLOBBER - # used by shred - AC_CHECK_FUNCS_ONCE(directio) - - AC_REQUIRE([AC_FUNC_CLOSEDIR_VOID]) - - AC_CHECK_FUNCS_ONCE( \ - endgrent \ - endpwent \ - ftruncate \ - gethrtime \ - hasmntopt \ - isascii \ - iswspace \ - lchown \ - listmntent \ - memcpy \ - mempcpy \ - mkfifo \ - mbrlen \ - realpath \ - sethostname \ - strchr \ - strerror \ - strrchr \ - sysctl \ - sysinfo \ - tcgetpgrp \ - wcrtomb \ - tzset \ - ) - - AC_FUNC_STRTOD - - AC_REQUIRE([cu_PREREQ_STAT_PROG]) - AC_REQUIRE([GL_FUNC_READDIR]) - - # for dd.c and shred.c - fetish_saved_libs=$LIBS - AC_SEARCH_LIBS([fdatasync], [rt posix4], - [test "$ac_cv_search_fdatasync" = "none required" || - LIB_FDATASYNC=$ac_cv_search_fdatasync]) - AC_SUBST([LIB_FDATASYNC]) - AC_CHECK_FUNCS(fdatasync) - LIBS=$fetish_saved_libs - - # See if linking `seq' requires -lm. - # It does on nearly every system. The single exception (so far) is - # BeOS which has all the math functions in the normal runtime library - # and doesn't have a separate math library. - - AC_SUBST(SEQ_LIBM) - ac_seq_body=' - static double x, y; - x = floor (x); - x = rint (x); - x = modf (x, &y);' - AC_TRY_LINK([#include ], $ac_seq_body, , - [ac_seq_save_LIBS="$LIBS" - LIBS="$LIBS -lm" - AC_TRY_LINK([#include ], $ac_seq_body, SEQ_LIBM=-lm) - LIBS="$ac_seq_save_LIBS" - ]) - - AM_LANGINFO_CODESET - gl_GLIBC21 - AM_ICONV - gl_FUNC_UNLINK_BUSY_TEXT - - # These tests are for df. - AC_REQUIRE([gl_FSUSAGE]) - AC_REQUIRE([gl_MOUNTLIST]) - if test $gl_cv_list_mounted_fs = yes && test $gl_cv_fs_space = yes; then - DF_PROG='df$(EXEEXT)' - fi - AC_REQUIRE([gl_AC_DOS]) - AC_REQUIRE([AC_FUNC_CANONICALIZE_FILE_NAME]) - - # If any of these functions don't exist (e.g. DJGPP 2.03), - # use the corresponding stub. - AC_CHECK_FUNC([fchdir], , [AC_LIBOBJ(fchdir-stub)]) - - AC_REQUIRE([gl_FUNC_FREE]) - AC_REQUIRE([gl_FUNC_CHDIR_LONG]) -]) - -# These tests must be run before any use of AC_CHECK_TYPE, -# because that macro compiles code that tests e.g., HAVE_UNISTD_H. -# See the definition of ac_includes_default in `configure'. -AC_DEFUN([gl_CHECK_ALL_HEADERS], -[ - AC_CHECK_HEADERS_ONCE( \ - errno.h \ - fcntl.h \ - float.h \ - hurd.h \ - limits.h \ - memory.h \ - mntent.h \ - mnttab.h \ - netdb.h \ - paths.h \ - stdlib.h \ - stddef.h \ - stdint.h \ - string.h \ - sys/filsys.h \ - sys/fs/s5param.h \ - sys/fs_types.h \ - sys/fstyp.h \ - sys/ioctl.h \ - sys/mntent.h \ - sys/param.h \ - sys/resource.h \ - sys/socket.h \ - sys/statfs.h \ - sys/statvfs.h \ - sys/systeminfo.h \ - sys/time.h \ - sys/timeb.h \ - sys/vfs.h \ - sys/wait.h \ - syslog.h \ - termios.h \ - unistd.h \ - utime.h \ - ) - AC_CHECK_HEADERS(sys/mount.h sys/sysctl.h, [], [], - [AC_INCLUDES_DEFAULT - [#if HAVE_SYS_PARAM_H - #include - #endif]]) -]) - -# This macro must be invoked before any tests that run the compiler. -AC_DEFUN([gl_CHECK_ALL_TYPES], -[ - dnl This test must come as early as possible after the compiler configuration - dnl tests, because the choice of the file model can (in principle) affect - dnl whether functions and headers are available, whether they work, etc. - AC_REQUIRE([AC_SYS_LARGEFILE]) - - dnl This test must precede tests of compiler characteristics like - dnl that for the inline keyword, since it may change the degree to - dnl which the compiler supports such features. - AC_REQUIRE([AM_C_PROTOTYPES]) - - dnl Checks for typedefs, structures, and compiler characteristics. - AC_REQUIRE([AC_C_BIGENDIAN]) - AC_REQUIRE([AC_C_CONST]) - AC_REQUIRE([AC_C_VOLATILE]) - AC_REQUIRE([AC_C_INLINE]) - AC_REQUIRE([AC_C_LONG_DOUBLE]) - - AC_REQUIRE([gl_CHECK_ALL_HEADERS]) - AC_REQUIRE([AC_HEADER_DIRENT]) - AC_REQUIRE([AC_HEADER_STDC]) - AC_CHECK_MEMBERS( - [struct stat.st_author, - struct stat.st_blksize],,, - [$ac_includes_default -#include - ]) - AC_REQUIRE([AC_STRUCT_ST_BLOCKS]) - - AC_REQUIRE([AC_HEADER_STAT]) - AC_REQUIRE([AC_STRUCT_ST_MTIM_NSEC]) - AC_REQUIRE([AC_STRUCT_ST_DM_MODE]) - - AC_REQUIRE([AC_TYPE_GETGROUPS]) - AC_REQUIRE([AC_TYPE_MBSTATE_T]) - AC_REQUIRE([AC_TYPE_MODE_T]) - AC_REQUIRE([AC_TYPE_OFF_T]) - AC_REQUIRE([AC_TYPE_PID_T]) - AC_REQUIRE([AC_TYPE_SIGNAL]) - AC_REQUIRE([AC_TYPE_SIZE_T]) - AC_REQUIRE([AC_TYPE_UID_T]) - AC_CHECK_TYPE(ino_t, unsigned long int) - - gt_TYPE_SSIZE_T - - dnl This relies on the fact that autoconf 2.14a's implementation of - dnl AC_CHECK_TYPE checks includes unistd.h. - AC_CHECK_TYPE(major_t, unsigned int) - AC_CHECK_TYPE(minor_t, unsigned int) - - AC_REQUIRE([gl_AC_TYPE_UINT32_T]) - AC_REQUIRE([gl_AC_TYPE_UINTMAX_T]) - AC_REQUIRE([gl_AC_TYPE_UINTPTR_T]) - AC_REQUIRE([gl_AC_TYPE_UNSIGNED_LONG_LONG]) - - AC_REQUIRE([AC_HEADER_MAJOR]) - AC_REQUIRE([AC_HEADER_DIRENT]) - -]) diff --git a/m4/lib-check.m4 b/m4/lib-check.m4 deleted file mode 100644 index 0ce73103f..000000000 --- a/m4/lib-check.m4 +++ /dev/null @@ -1,65 +0,0 @@ -#serial 7 - -dnl Misc lib-related macros for fileutils, sh-utils, textutils. - -AC_DEFUN([gl_LIB_CHECK], -[ - - # Check for libypsec.a on Dolphin M88K machines. - AC_CHECK_LIB(ypsec, main) - - # m88k running dgux 5.4 needs this - AC_CHECK_LIB(ldgc, main) - - # Some programs need to link with -lm. printf does if it uses - # lib/strtod.c which uses pow. And seq uses the math functions, - # floor, modf, rint. And factor uses sqrt. And sleep uses fesetround. - - # Save a copy of $LIBS and add $FLOOR_LIBM before these tests - # Check for these math functions used by seq. - ac_su_saved_lib="$LIBS" - LIBS="$LIBS -lm" - AC_CHECK_FUNCS(floor modf rint) - LIBS="$ac_su_saved_lib" - - AC_SUBST(SQRT_LIBM) - AC_CHECK_FUNCS(sqrt) - if test $ac_cv_func_sqrt = no; then - AC_CHECK_LIB(m, sqrt, [SQRT_LIBM=-lm]) - fi - - AC_SUBST(FESETROUND_LIBM) - AC_CHECK_FUNCS(fesetround) - if test $ac_cv_func_fesetround = no; then - AC_CHECK_LIB(m, fesetround, [FESETROUND_LIBM=-lm]) - fi - - # The -lsun library is required for YP support on Irix-4.0.5 systems. - # m88k/svr3 DolphinOS systems using YP need -lypsec for id. - AC_SEARCH_LIBS(yp_match, [sun ypsec]) - - # SysV needs -lsec, older versions of Linux need -lshadow for - # shadow passwords. UnixWare 7 needs -lgen. - AC_SEARCH_LIBS(getspnam, [shadow sec gen]) - - AC_CHECK_HEADERS(shadow.h) - - # Requirements for su.c. - shadow_includes="\ -$ac_includes_default -#if HAVE_SHADOW_H -# include -#endif -" - AC_CHECK_MEMBERS([struct spwd.sp_pwdp],,,[$shadow_includes]) - AC_CHECK_FUNCS(getspnam) - - # SCO-ODT-3.0 is reported to need -lufc for crypt. - # NetBSD needs -lcrypt for crypt. - ac_su_saved_lib="$LIBS" - AC_SEARCH_LIBS(crypt, [ufc crypt], - [test "$ac_cv_search_crypt" = "none required" || - LIB_CRYPT="$ac_cv_search_crypt"]) - LIBS="$ac_su_saved_lib" - AC_SUBST(LIB_CRYPT) -]) diff --git a/m4/prereq.m4 b/m4/prereq.m4 deleted file mode 100644 index f417678a4..000000000 --- a/m4/prereq.m4 +++ /dev/null @@ -1,135 +0,0 @@ -#serial 47 - -dnl We use gl_ for non Autoconf macros. -m4_pattern_forbid([^gl_[ABCDEFGHIJKLMNOPQRSTUVXYZ]])dnl - -# These are the prerequisite macros for files in the lib/ -# directory of the coreutils package. - -AC_DEFUN([gl_PREREQ], -[ - # We don't yet use c-stack.c. - # AC_REQUIRE([gl_C_STACK]) - - AC_REQUIRE([AM_FUNC_GETLINE]) - AC_REQUIRE([AM_STDBOOL_H]) - AC_REQUIRE([gl_FUNC_MKDIR_TRAILING_SLASH]) - AC_REQUIRE([gl_FUNC_MKSTEMP]) - AC_REQUIRE([gl_ALLOCSA]) - AC_REQUIRE([gl_BACKUPFILE]) - AC_REQUIRE([gl_C_STRTOLD]) - AC_REQUIRE([gl_CANON_HOST]) - AC_REQUIRE([gl_CLOEXEC]) - AC_REQUIRE([gl_CLOSEOUT]) - AC_REQUIRE([gl_DIRNAME]) - AC_REQUIRE([gl_ERROR]) - AC_REQUIRE([gl_EXCLUDE]) - AC_REQUIRE([gl_EXITFAIL]) - AC_REQUIRE([gl_FCNTL_SAFER]) - AC_REQUIRE([gl_FILEBLOCKS]) - AC_REQUIRE([gl_FILEMODE]) - AC_REQUIRE([gl_FILE_TYPE]) - AC_REQUIRE([gl_FSUSAGE]) - AC_REQUIRE([gl_FUNC_ALLOCA]) - AC_REQUIRE([gl_FUNC_ATEXIT]) - AC_REQUIRE([gl_FUNC_DUP2]) - AC_REQUIRE([gl_FUNC_FNMATCH_GNU]) - AC_REQUIRE([gl_FUNC_GETHOSTNAME]) - AC_REQUIRE([AC_FUNC_GETLOADAVG]) - AC_REQUIRE([gl_FUNC_GETPASS]) - AC_REQUIRE([gl_FUNC_GETUSERSHELL]) - AC_REQUIRE([gl_FUNC_MEMCHR]) - AC_REQUIRE([gl_FUNC_MEMCPY]) - AC_REQUIRE([gl_FUNC_MEMMOVE]) - AC_REQUIRE([gl_FUNC_MEMPCPY]) - AC_REQUIRE([gl_FUNC_MEMRCHR]) - AC_REQUIRE([gl_FUNC_MEMSET]) - AC_REQUIRE([gl_FUNC_MKTIME]) - AC_REQUIRE([gl_FUNC_NONREENTRANT_EUIDACCESS]) - AC_REQUIRE([gl_FUNC_READLINK]) - AC_REQUIRE([gl_FUNC_RMDIR]) - AC_REQUIRE([gl_FUNC_RPMATCH]) - AC_REQUIRE([gt_FUNC_SETENV]) - AC_REQUIRE([gl_FUNC_SIG2STR]) - AC_REQUIRE([gl_FUNC_STPCPY]) - AC_REQUIRE([gl_FUNC_STRCSPN]) - AC_REQUIRE([gl_FUNC_STRDUP]) - AC_REQUIRE([gl_FUNC_STRNDUP]) - AC_REQUIRE([gl_FUNC_STRNLEN]) - AC_REQUIRE([gl_FUNC_STRPBRK]) - AC_REQUIRE([gl_FUNC_STRSTR]) - AC_REQUIRE([gl_FUNC_STRTOD]) - AC_REQUIRE([gl_FUNC_STRTOIMAX]) - AC_REQUIRE([gl_FUNC_STRTOLL]) - AC_REQUIRE([gl_FUNC_STRTOL]) - AC_REQUIRE([gl_FUNC_STRTOULL]) - AC_REQUIRE([gl_FUNC_STRTOUL]) - AC_REQUIRE([gl_FUNC_STRTOUMAX]) - AC_REQUIRE([gl_FUNC_STRVERSCMP]) - AC_REQUIRE([gl_FUNC_VASNPRINTF]) - AC_REQUIRE([gl_FUNC_VASPRINTF]) - AC_REQUIRE([gl_GETDATE]) - AC_REQUIRE([gl_GETNDELIM2]) - AC_REQUIRE([gl_GETOPT]) - AC_REQUIRE([gl_GETPAGESIZE]) - AC_REQUIRE([gl_GETTIME]) - AC_REQUIRE([gl_GETUGROUPS]) - AC_REQUIRE([gl_HARD_LOCALE]) - AC_REQUIRE([gl_HASH]) - AC_REQUIRE([gl_HUMAN]) - AC_REQUIRE([gl_IDCACHE]) - AC_REQUIRE([gl_INTTOSTR]) - AC_REQUIRE([gl_LONG_OPTIONS]) - AC_REQUIRE([gl_MAKEPATH]) - AC_REQUIRE([gl_MBSWIDTH]) - AC_REQUIRE([gl_MD5]) - AC_REQUIRE([gl_MEMCOLL]) - AC_REQUIRE([gl_MODECHANGE]) - AC_REQUIRE([gl_MOUNTLIST]) - AC_REQUIRE([gl_OBSTACK]) - AC_REQUIRE([gl_PATHMAX]) - AC_REQUIRE([gl_PATH_CONCAT]) - AC_REQUIRE([gl_PHYSMEM]) - AC_REQUIRE([gl_POSIXTM]) - AC_REQUIRE([gl_POSIXVER]) - AC_REQUIRE([gl_QUOTEARG]) - AC_REQUIRE([gl_QUOTE]) - AC_REQUIRE([gl_READTOKENS]) - AC_REQUIRE([gl_READUTMP]) - AC_REQUIRE([gl_REGEX]) - AC_REQUIRE([gl_SAFE_READ]) - AC_REQUIRE([gl_SAFE_WRITE]) - AC_REQUIRE([gl_SAME]) - AC_REQUIRE([gl_SAVEDIR]) - AC_REQUIRE([gl_SAVE_CWD]) - AC_REQUIRE([gl_SETTIME]) - AC_REQUIRE([gl_SHA1]) - AC_REQUIRE([gl_STDIO_SAFER]) - AC_REQUIRE([gl_STRCASE]) - AC_REQUIRE([gl_TIMESPEC]) - AC_REQUIRE([gl_UNICODEIO]) - AC_REQUIRE([gl_UNISTD_SAFER]) - AC_REQUIRE([gl_USERSPEC]) - AC_REQUIRE([gl_UTIMECMP]) - AC_REQUIRE([gl_UTIMENS]) - AC_REQUIRE([gl_XALLOC]) - AC_REQUIRE([gl_XGETCWD]) - AC_REQUIRE([gl_XREADLINK]) - AC_REQUIRE([gl_XSTRTOD]) - AC_REQUIRE([gl_XSTRTOL]) - AC_REQUIRE([gl_YESNO]) - AC_REQUIRE([AC_FUNC_CALLOC]) - AC_REQUIRE([gl_FUNC_GLIBC_UNLOCKED_IO]) - AC_REQUIRE([gl_FUNC_GNU_STRFTIME]) - AC_REQUIRE([gl_FUNC_LSTAT]) - AC_REQUIRE([AC_FUNC_MALLOC]) - AC_REQUIRE([gl_FUNC_MEMCMP]) - AC_REQUIRE([gl_FUNC_NANOSLEEP]) - AC_REQUIRE([gl_FUNC_PUTENV]) - AC_REQUIRE([AC_FUNC_REALLOC]) - AC_REQUIRE([gl_FUNC_STAT]) - AC_REQUIRE([gl_FUNC_UTIME]) - AC_REQUIRE([gl_XSTRTOIMAX]) - AC_REQUIRE([gl_XSTRTOUMAX]) - AC_REQUIRE([vb_FUNC_RENAME]) -]) diff --git a/m4/search-libs.m4 b/m4/search-libs.m4 deleted file mode 100644 index 41c1c04ef..000000000 --- a/m4/search-libs.m4 +++ /dev/null @@ -1,42 +0,0 @@ -#serial 5 - -dnl A replacement for autoconf's macro by the same name. This version -dnl uses `ac_lib' rather than `i' for the loop variable, but more importantly -dnl moves the ACTION-IF-FOUND ([$]3) into the inner `if'-block so that it is -dnl run only if one of the listed libraries ends up being used (and not in -dnl the `none required' case. -dnl I hope it's only temporary while we wait for that version to be fixed. -undefine([AC_SEARCH_LIBS]) - -# AC_SEARCH_LIBS(FUNCTION, SEARCH-LIBS, -# [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND], -# [OTHER-LIBRARIES]) -# -------------------------------------------------------- -# Search for a library defining FUNC, if it's not already available. -AC_DEFUN([AC_SEARCH_LIBS], -[ - AC_CACHE_CHECK([for library containing $1], [ac_cv_search_$1], - [ - ac_func_search_save_LIBS=$LIBS - ac_cv_search_$1=no - AC_TRY_LINK_FUNC([$1], [ac_cv_search_$1='none required']) - if test "$ac_cv_search_$1" = no; then - for ac_lib in $2; do - LIBS="-l$ac_lib $5 $ac_func_search_save_LIBS" - AC_TRY_LINK_FUNC([$1], [ac_cv_search_$1="-l$ac_lib"; break]) - done - fi - LIBS=$ac_func_search_save_LIBS - ]) - - if test "$ac_cv_search_$1" = no; then : - $4 - else - if test "$ac_cv_search_$1" = 'none required'; then : - $4 - else - LIBS="$ac_cv_search_$1 $LIBS" - $3 - fi - fi -]) diff --git a/modules/getloadavg b/modules/getloadavg index e8774bc85..e2ede2bdc 100644 --- a/modules/getloadavg +++ b/modules/getloadavg @@ -3,14 +3,14 @@ Return the current system load averages. Files: lib/getloadavg.c -m4/getloadavg.m4 Depends-on: cloexec xalloc +c-strtod configure.ac: -gl_FUNC_GETLOADAVG +AC_FUNC_GETLOADAVG Makefile.am: @@ -21,4 +21,3 @@ GPL Maintainer: Jim Meyering -