Re: xctime()

2010-01-24 Thread Robert Millan
On Sun, Jan 24, 2010 at 08:51:58PM +0100, Bruno Haible wrote: > Hmm, if this is proposed for gnulib, I have 4 remarks: > > - Error handling: strftime can fail. Since you call xmalloc for the > memory allocation, I think it would be reasonable to call error() > in case strftime fails. Ok

Re: TESTS_ENVIRONMENT

2010-01-24 Thread Ralf Wildenhues
Hello, * Bruno Haible wrote on Sun, Jan 24, 2010 at 05:54:55PM CET: > Things are different for EXEEXT and srcdir, though: These are defined by > autoconf and automake by default (well, it requires AC_PROG_CC or AC_PROG_CXX, > but everyone invokes one or the other). Therefore it's appropriate for >

Re: new common math function modules

2010-01-24 Thread Bruno Haible
On 2010-01-18 I wrote: > 2010-01-18 Bruno Haible > > New modules for common functions. > * m4/mathfunc.m4: New file. Oops. This commit had 3 bugs: - The autoconf test for atan2, copysign, fmod, hypot, jn, ldexp, modf, nextafter, pow, remainder, yn always failed, for example:

Re: xctime()

2010-01-24 Thread Bruno Haible
Hi Robert, Robert Millan wrote: > I implemented xctime for GNU isofsmk. xctime is an alternative to ctime() > that: > > - Uses dynamic allocation > - Is thread-safe > - Returns localized strings I agree that it's not a good idea to use ctime() or asctime(), because of the problems mention

xctime()

2010-01-24 Thread Robert Millan
Hi, I implemented xctime for GNU isofsmk. xctime is an alternative to ctime() that: - Uses dynamic allocation - Is thread-safe - Returns localized strings char * xctime (const time_t *time) { struct tm *loctime; char *str; size_t len; loctime = localtime (time); len = strftim

bootstrap's function find_tool

2010-01-24 Thread Thomas Treichl
Hi everybody, a month ago I was still working on an older OS X 10.4 system and tried to compile recent sources of GNU Octave which now uses the bootstrap file. I failed with a local copy of gnulib (I used the option --gnulib-srcdir=) because I didn't have any of the tools gsha1sum, sha1sum et

Re: TESTS_ENVIRONMENT

2010-01-24 Thread Bruno Haible
Hi, Jim Meyering wrote: > Currently, every test that uses init.sh must include > tests/init.sh in the "Files:" section and must append EXEEXT and srcdir > definitions to the TESTS_ENVIRONMENT in the "Makefile.am:" section: > > Files: > tests/init.sh > ... > > Makefile.am: > T

some new documentation

2010-01-24 Thread Bruno Haible
Hi, When Jim mentioned issues about TESTS_ENVIRONMENT, I realized that the gnulib documentation has no details about how a tests module normally looks like, and even the doc about regular modules is scarce. In fact, the module description details are undocumented! This fixes it. More doc could be

[PATCH] maint.mk: do not prepend "./" after filtering

2010-01-24 Thread Jim Meyering
FYI, >From 8fc05d032b3f9a9d068613ab5ee297b4e7d5a08a Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Sun, 24 Jan 2010 14:24:00 +0100 Subject: [PATCH] maint.mk: do not prepend "./" after filtering * top/maint.mk (_prepend_srcdir_prefix): New variable (VC_LIST_EXCEPT): Use it to avoid prepending

Re: [PATCH 1/2] top/maint.mk: Fix VC_LIST_EXCEPT for srcdir != builddir

2010-01-24 Thread Jim Meyering
Jim Meyering wrote: > Eric Blake wrote: >> According to Jim Meyering on 1/23/2010 11:28 AM: location of '../' got turned into '../../'. >>> >>> Thanks! >>> Looks like I introduced that. >>> This seems to fix the original problem without breaking anything. >>> I'll push it after a little more t

[PATCH] define STREQ(a, b) consistently, removing useless parentheses

2010-01-24 Thread Jim Meyering
FYI, >From c0221df484c4a8a32e42a595b9f6caa446cc2226 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Sun, 24 Jan 2010 11:31:42 +0100 Subject: [PATCH] define STREQ(a,b) consistently, removing useless parentheses #define STREQ(a, b) (strcmp ((a), (b)) == 0) is over-parenthesized, since the only r