From: Paul Eggert Date: Sat, 12 Aug 2023 23:45:30 +0000 (-0700) Subject: boot-time,readutmp: remove -lrt usage X-Git-Tag: v1.0~918 X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=32d729b68bb29e5103d03a6a2eb39d800c7d8a27;p=gnulib.git boot-time,readutmp: remove -lrt usage This code uses clock-relevant functions only on platforms that do not need -lrt. * m4/readutmp.m4 (gl_READUTMP): Do not require gl_CLOCK_TIME or add CLOCK_TIME_LIB to READUTMP_LIB. * modules/boot-time (Link): No need to link with CLOCK_TIME_LIB. --- diff --git a/ChangeLog b/ChangeLog index 407e1733ca..9e5c65f564 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,12 @@ 2023-08-12 Paul Eggert + boot-time,readutmp: remove -lrt usage + This code uses clock-relevant functions only on platforms + that do not need -lrt. + * m4/readutmp.m4 (gl_READUTMP): Do not require gl_CLOCK_TIME + or add CLOCK_TIME_LIB to READUTMP_LIB. + * modules/boot-time (Link): No need to link with CLOCK_TIME_LIB. + boot-time,readutmp: do not depend on fopen-gnu These modules should work well enough even if fopen is not fixed to conform to fopen-gnu standards. The only gotcha I can see is diff --git a/m4/readutmp.m4 b/m4/readutmp.m4 index c180374044..fff8d4eb7b 100644 --- a/m4/readutmp.m4 +++ b/m4/readutmp.m4 @@ -1,4 +1,4 @@ -# readutmp.m4 serial 27 +# readutmp.m4 serial 28 dnl Copyright (C) 2002-2023 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -40,8 +40,6 @@ AC_DEFUN([gl_READUTMP], fi fi fi - AC_REQUIRE([gl_CLOCK_TIME]) - READUTMP_LIB="$READUTMP_LIB $CLOCK_TIME_LIB" AC_SUBST([READUTMP_LIB]) gl_PREREQ_READUTMP_H diff --git a/modules/boot-time b/modules/boot-time index d8ab075024..24a798160a 100644 --- a/modules/boot-time +++ b/modules/boot-time @@ -27,7 +27,6 @@ Include: "boot-time.h" Link: -$(CLOCK_TIME_LIB) License: GPL