From: Bruno Haible Date: Mon, 8 Jan 2007 21:28:13 +0000 (+0000) Subject: 2007-01-08 Bruno Haible X-Git-Tag: cvs-readonly~1421 X-Git-Url: http://erislabs.org.uk/gitweb/?a=commitdiff_plain;h=25d88ed1433aa7015e676ea6b1d718a70dc427f7;p=gnulib.git 2007-01-08 Bruno Haible * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition. * lib/fts_.h (_LGPL_PACKAGE): Remove macro. Use !GNULIB_FTS instead of _LGPL_PACKAGE. * lib/fts.c: Likewise. * modules/fts (configure.ac): Use gl_MODULE_INDICATOR. --- diff --git a/ChangeLog b/ChangeLog index 4e2ad0683..aa28c08d2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2007-01-08 Bruno Haible + + * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition. + * lib/fts_.h (_LGPL_PACKAGE): Remove macro. + Use !GNULIB_FTS instead of _LGPL_PACKAGE. + * lib/fts.c: Likewise. + * modules/fts (configure.ac): Use gl_MODULE_INDICATOR. + 2006-12-25 Bruno Haible * modules/utf8-ucs4-safe: New file. diff --git a/lib/fts.c b/lib/fts.c index 9482833a0..061198fdd 100644 --- a/lib/fts.c +++ b/lib/fts.c @@ -162,13 +162,13 @@ static unsigned short int fts_stat (FTS *, FTSENT *, bool) internal_function; static int fts_safe_changedir (FTS *, FTSENT *, int, const char *) internal_function; -#if _LGPL_PACKAGE +#if GNULIB_FTS +# include "fts-cycle.c" +#else static bool enter_dir (FTS *fts, FTSENT *ent) { return true; } static void leave_dir (FTS *fts, FTSENT *ent) {} static bool setup_dir (FTS *fts) { return true; } static void free_dir (FTS *fts) {} -#else -# include "fts-cycle.c" #endif #ifndef MAX @@ -1405,7 +1405,7 @@ err: memset(sbp, 0, sizeof(struct stat)); return (p->fts_level == FTS_ROOTLEVEL ? FTS_D : FTS_DOT); } -#if _LGPL_PACKAGE +#if !GNULIB_FTS { /* * Cycle detection is done by brute force when the directory diff --git a/lib/fts_.h b/lib/fts_.h index d5b047412..a8a52d269 100644 --- a/lib/fts_.h +++ b/lib/fts_.h @@ -1,6 +1,6 @@ /* Traverse a file hierarchy. - Copyright (C) 2004, 2005, 2006 Free Software Foundation, Inc. + Copyright (C) 2004, 2005, 2006, 2007 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 @@ -52,7 +52,6 @@ # ifdef _LIBC # include -# define _LGPL_PACKAGE 1 # else # undef __THROW # define __THROW @@ -142,7 +141,7 @@ typedef struct { # define FTS_STOP 0x2000 /* (private) unrecoverable error */ int fts_options; /* fts_open options, global flags */ -# if !_LGPL_PACKAGE +# if GNULIB_FTS union { /* This data structure is used if FTS_TIGHT_CYCLE_CHECK is specified. It records the directories between a starting diff --git a/m4/fts.m4 b/m4/fts.m4 index 2c9348e63..ae6c46996 100644 --- a/m4/fts.m4 +++ b/m4/fts.m4 @@ -1,5 +1,5 @@ -#serial 11 -dnl Copyright (C) 2005, 2006 Free Software Foundation, Inc. +#serial 12 +dnl Copyright (C) 2005-2007 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. @@ -12,9 +12,6 @@ AC_DEFUN([gl_FUNC_FTS], AC_DEFUN([gl_FUNC_FTS_LGPL], [ AC_REQUIRE([gl_FUNC_FTS_CORE]) - AC_DEFINE([_LGPL_PACKAGE], 1, - [Define to 1 if compiling for a package to be distributed under the - GNU Lesser Public License.]) ]) AC_DEFUN([gl_FUNC_FTS_CORE], diff --git a/modules/fts b/modules/fts index b354809c4..5473ee2a4 100644 --- a/modules/fts +++ b/modules/fts @@ -22,6 +22,7 @@ unistd-safer configure.ac: gl_FUNC_FTS +gl_MODULE_INDICATOR([fts]) Makefile.am: