[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: strings.h in argz.c?

From: Ralf Wildenhues
Subject: Re: strings.h in argz.c?
Date: Sat, 27 Jan 2007 17:45:26 +0100
User-agent: Mutt/1.5.13 (2006-08-11)

* Paul Eggert wrote on Mon, Jan 22, 2007 at 03:22:51AM CET:
> My experience is that everyone who's reported a bug against SunOS
> 4.1.x for several years, is either (1) doing it only because they're
> worried we might still want to be portable to SunOS 4.1.x, or (2)
> maintaining a computer museum.  Neither of these cases are worth
> worrying about.


> Ralf Wildenhues <address@hidden> writes:
> > Is it likely (in practice) to have math functions like sin, cos,
> > available but not math.h?  Similarly, is it likely to have string
> > functions but not string.h?
> Not these days, no.  However it is possible that a freestanding
> environment would have neither math.h nor the math functions.  PalmOS
> is one fairly-contemporary example.  It's less likely for string.h to
> be missing (PalmOS has it, albeit in a shim mode if memory serves).

OK, that's good enough for Libtool.  If a test fails due to missing
math.h, I won't be worried, if it would fail later anyway due to a
missing sine function.

* Simon Josefsson wrote on Mon, Jan 22, 2007 at 08:53:37AM CET:
> Ralf Wildenhues <address@hidden> writes:
> > We got a bug report about Libtool 1.5.22 and SunOS 4.1.x this year, so
> > I'm not doing any C89 cleanup on branch-1-5.
> That's not a problem, I only meant it to apply to future version.  (I
> assume there will be future versions not based on branch-1-5 ;-)).

I do hope so, too.

> > OTOH, the change may eventually cause 2 less header checks in user code;
> > that is, once all other checks for string.h and strings.h are eliminated
> > from their configury.
> Yes, and another problem might be code that checks for strings.h
> and/or memory.h, but not string.h.  It seems they might get the wrong
> headers..

Well, currently, Autoconf's _AC_INCLUDES_DEFAULT_REQUIREMENTS still
tests for these anyway.

> I don't know about math.h.  Math functions seem generally more
> optional than other functions to me, depending on platform.  If your
> patch only changed this for the self tests, that is probably OK, but
> it seems weird for libtool/ltdl to require math functions.

ACK.  Only the test suite requires them.

I applied the patch, with a NEWS bit added, to HEAD.


        Assume C89 for included headers, and throughout the testsuite.

        * NEWS: Update.
        * libltdl/argz.c: Do not include strings.h nor memory.h, include
        string.h unconditionally.
        Patch by Simon Josefsson <address@hidden>.
        * libltdl/libltdl/lt__private.h: Likewise.
        * libltdl/m4/ltdl.m4 (LTDL_INIT): Do not check for string.h,
        strings.h, memory.h.
        * tests/cdemo/ Assume presence of math.h.
        * tests/cdemo/foo.c: Likewise.
        * tests/demo/ Likewise for math.h, string.h.
        Assume 'const'.  Drop obsolete AC_EXEEXT.
        * tests/demo/dlmain.c: Likewise.
        * tests/demo/foo.c: Likewise.
        * tests/depdemo/ Likewise.
        * tests/depdemo/l4/l4.c: Likewise.
        * tests/f77demo/ Likewise.  Also drop obsolete
        * tests/fcdemo/ Likewise.
        * tests/mdemo/ Likewise.
        * tests/mdemo/foo1.c: Likewise.
        * tests/mdemo/foo2.c: Likewise.
        * tests/mdemo2/ Likewise.
        * tests/pdemo/ Likewise.
        * tests/pdemo/longer_file_name_dlmain.c:
        * tests/pdemo/longer_file_name_foo.c: Likewise.
        * tests/pdemo/longer_file_name_foo2.c: Likewise.
        * tests/tagdemo/ Likewise.
        * tests/tagdemo/foo.cpp: Likewise.

Index: NEWS
RCS file: /cvsroot/libtool/libtool/NEWS,v
retrieving revision 1.197
diff -u -r1.197 NEWS
--- NEWS        24 Oct 2006 20:17:37 -0000      1.197
+++ NEWS        27 Jan 2007 16:44:19 -0000
@@ -36,6 +36,9 @@
 * Initial support for the Sun compiler suite on GNU/Linux.
 * Improved support for GNU/kFreeBSD and GNU/NetBSD.
 * Search paths with GCC on multilib systems like x86_64 have been fixed.
+* The Libtool and libltdl macros and the testsuite now assume a C89
+  environment, consequently do not test for headers such as string.h,
+  strings.h, memory.h any more.
 * Bug fixes.
 New in 1.9f: 2004-10-23; CVS version 1.9e, Libtool team:

reply via email to

[Prev in Thread] Current Thread [Next in Thread]