summaryrefslogtreecommitdiff
path: root/NEWS
Commit message (Collapse)AuthorAgeFilesLines
...
* renameatu: rename from renameat2Paul Eggert2018-07-051-0/+4
| | | | | | | | | | | | | | | | | | | | It's looking like Glibc will add a renameat2 function that is incompatible with Gnulib renameat2; see: https://sourceware.org/ml/libc-alpha/2018-07/msg00064.html To help avoid future confusion, rename renameat2 to something else. Use the name 'renameatu', as the Gnulib function is close to the Glibc function. Perhaps someday there will also be a renameat2 Gnulib module, which mimicks the future glibc renameat2, but that can wait as nobody seems to need such a module now. * NEWS: Mention this. * lib/renameatu.c: Rename from lib/renameat2.c. * lib/renameatu.h: Rename from lib/renameat2.h. * modules/renameat2: Rename from modules/renameatu. * modules/renameat2-tests: Rename from modules/renameat2-tests. All uses of "renameat2" in identifiers or file name changed to "renameatu", except for two instances in lib/renameatu.c that deal with the Linux kernel's renameat2 syscall.
* chdir-safer: remove this modulePaul Eggert2017-12-301-0/+3
| | | | | | | * MODULES.html.sh (func_all_modules): Remove chdir-safer. * NEWS: Document removal. * lib/chdir-safer.c, lib/chdir-safer.h, m4/afs.m4, m4/chdir-safer.m4: * modules/chdir-safer: Remove these files.
* posixtm: remove PDS_LEADING_YEARPaul Eggert2017-11-241-0/+6
| | | | | | | | | | | | | | | | | This changes the API slightly, in a hopefully-innocuous way. Without this change the code had undefined behavior when a caller specified neither PDS_LEADING_YEAR nor PDS_TRAILING_YEAR. Problem reported by Pádraig Brady in: https://lists.gnu.org/r/bug-gnulib/2017-11/msg00048.html * NEWS: Mention this. * lib/posixtm.c (posix_time_parse): Treat the absence of PDS_TRAILING_YEAR as if PDS_LEADING_YEAR were present. * lib/posixtm.h (PDS_LEADING_YEAR): Remove (actually, leave it present, but define it as zero, for compatibility with existing source code). All other PDS_* values moved up. * tests/test-posixtm.c (LY): New macro. (T): Use it. Do not expect a particular numeric encoding for PDS_CENTURY etc.
* open: support O_CLOEXECPaul Eggert2017-08-141-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * NEWS, doc/posix-functions/open.texi: * doc/posix-functions/openat.texi: Document this. * lib/fcntl.in.h (O_CLOEXEC): Default to a nonzero value. (GNULIB_defined_O_CLOEXEC): New symbol. * lib/open.c: Include cloexec.h. (open): Support O_CLOEXEC. * lib/openat.c: Include cloexec.h. (rpl_openat): Support O_CLOEXEC. * lib/popen-safer.c: Do not include cloexec.h. (open_noinherit): Remove. (popen_safer): Use O_CLOEXEC instead of set_cloexec_flag. * lib/save-cwd.c: Do not include cloexec.h. (save_cwd): Use O_CLOEXEC instead of set_cloexec_flag. * m4/open-cloexec.m4: New file. * m4/open.m4 (gl_FUNC_OPEN): Require gl_PREPROC_O_CLOEXEC. Replace 'open' if O_CLOEXEC is not present. * m4/openat.m4 (gl_FUNC_OPENAT): Require gl_PREPROC_O_CLOEXEC. Replace 'openat' if O_CLOEXEC is not present. * modules/freopen (Depends-on): Depend on 'open' if replacing freopen. * modules/open (Files): Add m4/open-cloexec.m4. (Depends-on): Depend on cloexec if replacing 'open'. * modules/openat (Files): Add m4/open-cloexec.m4. (Depends-on): Depend on cloexec if replacing openat. * modules/popen-safer (Depends-on): Remove cloexec. * modules/save-cwd (Depends-on): Remove cloexec, and add fd-safer-flag and 'open'.
* Rename module 'strftime' to 'nstrftime'.Bruno Haible2017-07-241-0/+2
| | | | * NEWS: Mention the change.
* closeout: don’t close stderr when sanitizingPaul Eggert2017-05-191-0/+4
| | | | | | | * NEWS: Document this. * lib/closeout.c (__has_feature): New macro, if not already defined. (SANITIZE_ADDRESS): New constant. (close_stdout): Don’t close stderr if sanitizing addresses.
* xbinary-io: rename from xsetmodePaul Eggert2017-02-161-3/+2
| | | | | | | | | | | | | | | | | | This patch is taken from suggestions by Bruno Haible in: http://lists.gnu.org/archive/html/bug-gnulib/2017-02/msg00060.html http://lists.gnu.org/archive/html/bug-gnulib/2017-02/msg00061.html * lib/binary-io.c (__gl_setmode_check): Set errno to EINVAL, not ENOTTY, when it is an inappropriate device. * lib/binary-io.h (SET_BINARY): Resurrect. * lib/xbinary-io.c: Rename from lib/xsetmode.c. (xset_binary_mode_error): Rename from xsetmode_error. * lib/xbinary-io.h: Rename from lib/xsetmode.h. (xset_binary_mode): Rename from xsetmode. All uses changed. * modules/xbinary-io: Rename from modules/xsetmode. Update file names. * tests/test-binary-io.sh (tmpfiles): Remove no-longer-used file name. * NEWS: Update to match revised behavior.
* xsetmode: new modulePaul Eggert2017-02-151-0/+4
| | | | | | | | | | | | | This is to fix a problem noted by Eric Blake. Code was using xfreopen to change files to binary mode, but this fails for stdout when in append mode. Such code should use xsetmode instead. * NEWS: Document incompatible changes to binary-io module. * lib/binary-io.c (__gl_setmode_check) [__DJGPP__ || __EMX__]: New function. * lib/binary-io.h (__gl_setmode): Rename from set_binary_mode. (set_binary_mode): New function, which also checks for tty. * lib/xsetmode.c, lib/xsetmode.h, modules/xsetmode: New files.
* parse-datetime: handle timezones reentrantlyPaul Eggert2017-01-201-0/+4
| | | | | | | | | | | | | | | | | | This API change was prompted by a report by Pádraig Brady in: https://bug.debian.org/851934#10 To help fix the bug, make parse_datetime2 more reentrant. * NEWS: Document this incompatible change. * lib/parse-datetime.h, lib/parse-datetime.y (parse_datetime2): Add two arguments, the timezone and the timezone name. All callers changed. If TZ="..." is specified, use it for calculating defaults. * lib/parse-datetime.y: Don't include xalloc.h or use xmalloc, as this code should be usable in a library. (mktime_ok, get_effective_timezone): Accept timezone arg too. All callers changed. (get_tz): Remove. (get_effective_timezone): Check for failures. * modules/parse-datetime: Add time_r, time_rz. Remove xalloc.
* host-cpu-c-abi: Add support for armhf, arm64, x32, s390x.Bruno Haible2017-01-161-0/+3
| | | | | | | | | * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Require gl_C_ASM. On x86_64 systems, distinguish x86_64 and x32. On arm systems, distinguish arm, armhf, arm64, and no longer distinguish arm and armel. On s390x systems, distinguish s390 and s390x. * modules/host-cpu-c-abi (Files): Add m4/asm-underscore.m4. * NEWS: Mention the change regarding 'armel'.
* localeinfo: case_folded_counterparts and WEOFPaul Eggert2017-01-151-0/+3
| | | | | | | * NEWS: Document this. * lib/localeinfo.c (case_folded_counterparts): First arg is now wint_t, not wchar_t. This generalizes the function to also work on WEOF, where it returns 0.
* getlogin, getlogin_r: Fix link errors on MSVC.Bruno Haible2016-12-181-0/+3
| | | | | | | | | | | | * m4/getlogin.m4 (gl_LIB_GETLOGIN): New macro. * modules/getlogin (configure.ac): Require gl_LIB_GETLOGIN. (Link): New section. * modules/getlogin_r (Files): Add m4/getlogin.m4. (configure.ac): Require gl_LIB_GETLOGIN. (Link): New section. * NEWS: Mention the new link requirements. * modules/getlogin-tests (test_getlogin_LDADD): New variable. * modules/getlogin_r-tests (test_getlogin_r_LDADD): New variable.
* Un-deprecate the 'progname' module.Bruno Haible2016-12-181-8/+10
| | | | | | * NEWS: Describe the appropriate use-cases of 'progname' versus 'getprogname'. Based on discussion summary at http://lists.gnu.org/archive/html/bug-gnulib/2016-10/msg00105.html
* Reorganize NEWS a bit.Bruno Haible2016-12-181-15/+15
| | | | | * NEWS: Move some not so important changes away from section "Important Notes".
* dfa: remove DFA_CASE_FOLD flag in favor of RE_ICASEArnold D. Robbins2016-12-131-0/+2
| | | | | * dfa.h (DFA_CASE_FOLD): Remove. * dfa.c (dfasyntax): Set dfa->syntax.case_fold based on RE_ICASE.
* Enable Unicode decoder safety unconditionally.Bruno Haible2016-11-191-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lib/unistr.in.h (u32_mbtouc_unsafe): Assume CONFIG_UNICODE_SAFETY. * lib/unistr/u8-mblen.c (u8_mblen): Likewise. * lib/unistr/u8-mbtouc-unsafe.c (u8_mbtouc_unsafe): Likewise. * lib/unistr/u8-mbtouc-unsafe-aux.c (u8_mbtouc_unsafe_aux): Likewise. * lib/unistr/u8-prev.c (u8_prev): Likewise. * lib/unistr/u8-strmblen.c (u8_strmblen): Likewise. * lib/unistr/u8-strmbtouc.c (u8_strmbtouc): Likewise. * lib/unistr/u16-mblen.c (u16_mblen): Likewise. * lib/unistr/u16-mbtouc-unsafe.c (u16_mbtouc_unsafe): Likewise. * lib/unistr/u16-mbtouc-unsafe-aux.c (u16_mbtouc_unsafe_aux): Likewise. * lib/unistr/u16-prev.c (u16_prev): Likewise. * lib/unistr/u16-strmblen.c (u16_strmblen): Likewise. * lib/unistr/u16-strmbtouc.c (u16_strmbtouc): Likewise. * lib/unistr/u32-mblen.c (u32_mblen): Likewise. * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Likewise. * lib/unistr/u32-prev.c (u32_prev): Likewise. * lib/unistr/u32-next.c (u32_next): Likewise. * lib/unistr/u32-strmblen.c (u32_strmblen): Likewise. * lib/unistr/u32-strmbtouc.c (u32_strmbtouc): Likewise. * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise. * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise. * tests/unistr/test-u16-prev.c (check_invalid): Enable the CONFIG_UNICODE_SAFETY tests unconditionally. * tests/unistr/test-u32-mblen.c (main): Likewise. * tests/unistr/test-u32-mbtouc.h (test_function): Likewise. * tests/unistr/test-u32-prev.c (check_invalid): Likewise. * tests/unistr/test-u32-next.c (main): Likewise. * tests/unistr/test-u32-strmblen.c (main): Likewise. * tests/unistr/test-u32-strmbtouc.c (main): Likewise. * tests/unistr/test-u32-mbtouc.c (FULL_SAFETY): Remove macro. * lib/unistr/u8-check.c (u8_check): Remove old dead code. * lib/unistr/u8-mbtouc.c (u8_mbtouc): Likewise. * lib/unistr/u8-mbtouc-aux.c (u8_mbtouc_aux): Likewise. * lib/unistr/u8-mbtoucr.c (u8_mbtoucr): Likewise. * lib/unistr/u8-uctomb.c (u8_uctomb): Likewise. * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Likewise. * lib/unistr/u16-check.c (u16_check): Update comment. * NEWS: Mention the changes that callers should be aware of.
* getprogname: new modulePino Toscano2016-09-051-0/+8
| | | | | | | | | This provides a LGPL module for getting the name of the current program, using the same API found on *BSD systems. * lib/getprogname.c, lib/getprogname.h, m4/getprogname.m4: * modules/getprogname: New files. * MODULES.html.sh (Misc): Add getprogname. * NEWS: Document the deprecation of the 'progname' module.
* stdbool: don't require _Bool for C++Paul Eggert2016-08-171-0/+4
| | | | | | | | | Problem reported by David Seifert in: http://lists.gnu.org/archive/html/bug-gnulib/2016-06/msg00005.html * NEWS, doc/posix-headers/stdbool.texi (stdbool.h): Document this. * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL): Make the check more-forgiving for C++, in that it requires only 'bool'. Be a bit stricter about checking that bool and _Bool are compatible in C.
* intprops, mktime, strtol: assume two's complementPaul Eggert2016-04-131-0/+4
| | | | | | | | | | | | | | | | | | These macros were not portable to every conforming C11 ones' complement platform. It's not worth the hassle of porting to some platforms that use ones' complement or signed magnitude, as such platforms are almost purely theoretical nowadays and porting even to some of them makes the code harder to review for little practical benefit. Problem reported by Florian Weimer in: https://sourceware.org/ml/libc-alpha/2016-04/msg00295.html * lib/intprops.h (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT) (TYPE_SIGNED_MAGNITUDE, _GL_INT_TWOS_COMPLEMENT): * lib/mktime.c (TYPE_TWOS_COMPLEMENT): * lib/strtol.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT) (TYPE_SIGNED_MAGNITUDE): Remove. All uses rewritten to assume two's complement, which is all we can reasonably test nowadays anyway. * top/maint.mk (_intprops_names): Remove the removed macros.
* intprops: revise _WRAPV macros, revert _OVERFLOWPaul Eggert2015-11-041-8/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The incompatible changes to the _OVERFLOW macros were too much of a hassle in practice, so revert them. Instead, change the new _WRAPV macros to make them closer in behavior to GCC 5's new builtin_add_overflow etc. functions. No other software was using these newly-added macros yet, so this should be OK. * NEWS: Revert previous change, since the incompatible change has been reverted, and nobody used the incompatible version. * doc/intprops.texi (Wraparound Arithmetic, Integer Type Overflow): Document revised behavior. (Integer Range Overflow): Adjust example to match above revisions. * lib/intprops.h (INT_ADD_OVERFLOW, INT_SUBTRACT_OVERFLOW) (INT_MULTIPLY_OVERFLOW): Revert previous change, so that these can be used in integer constant expressions again. (INT_CONST_ADD_OVERFLOW, INT_CONST_SUBTRACT_OVERFLOW) (INT_CONST_MULTIPLY_OVERFLOW): Remove, as these are no longer needed. (INT_CONST_ADD_WRAPV, INT_CONST_SUBTRACT_WRAPV) (INT_NEGATE_WRAPV, INT_CONST_MULTIPLY_WRAPV, INT_DIVIDE_WRAPV) (INT_REMAINDER_WRAPV, INT_LEFT_SHIFT_WRAPV): Remove, as they did not seem that useful. (INT_ADD_WRAPV, INT_SUBTRACT_WRAPV, INT_MULTIPLY_WRAPV) (_GL_INT_OP_WRAPV, _GL_INT_OP_WRAPV_LONGISH) (_GL_INT_OP_WRAPV_VIA_UNSIGNED): Support new semantics. (__has_builtin): New macro, if not alreay defined. (_GL__GENERIC_BOGUS, _GL_INT_OP_CALC, _GL_INT_OP_CALC1): New macros. * tests/test-intprops.c (INT_CONST_DIVIDE_OVERFLOW) (INT_CONST_REMAINDER_OVERFLOW, INT_CONST_LEFT_SHIFT_OVERFLOW) (INT_CONST_DIVIDE_WRAPV, INT_CONST_REMAINDER_WRAPV) (INT_CONST_LEFT_SHIFT_WRAPV): Remove. (CHECK_SBINOP, CHECK_SSUM, CHECK_SUM1, CHECK_SSUM1) (CHECK_SDIFFERENCE, CHECK_SPRODUCT, CHECK_PRODUCT1, CHECK_SPRODUCT1): New macros. (CHECK_BINOP, CHECK_UNOP, main, CHECK_SUM): Test new behavior.
* intprops: add WRAPV and const flavors for GCC 5Paul Eggert2015-10-301-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If available, use GCC 5's builtin functions for efficient integer overflow checking. Also, add macros like INT_ADD_WRAPV that efficently and safely compute the low-order bits of the correct answer. A downside of these efficient functions is that they cannot be used in constant expressions, so add macros like INT_CONST_ADD_OVERFLOW and INT_CONST_ADD_WRAPV that can be used even in constant expressions. * NEWS: Document the incompatible changes to INT_ADD_OVERFLOW etc. * doc/intprops.texi (Integer Properties, Integer Type Overflow): Document the changes. (Wraparound Arithmetic): New section. (Integer Range Overflow): Put this subsection last, since it's least useful. * lib/intprops.h (INT_CONST_ADD_OVERFLOW) (INT_CONST_SUBTRACT_OVERFLOW, INT_CONST_MULTIPLY_OVERFLOW): New macros, with the meaning that INT_ADD_OVERFLOW etc. used to have. (INT_CONST_ADD_WRAPV, INT_CONST_SUBTRACT_WRAPV) (INT_NEGATE_WRAPV, INT_CONST_MULTIPLY_WRAPV, INT_DIVIDE_WRAPV) (INT_REMAINDER_WRAPV, _GL_INT_OP_WRAPV, _GL_EXPR_CAST) (_GL_INT_OP_WRAPV_LONGISH, INT_ADD_WRAPV, INT_SUBTRACT_WRAPV) (INT_MULTIPLY_WRAPV, _GL_OP_OVERFLOW, _GL_OP_WRAPV, _GL_OP_WRAPV_GENSYM): New macros. (INT_ADD_OVERFLOW, INT_SUBTRACT_OVERFLOW, INT_MULTIPLY_OVERFLOW): Generate calls to GCC builtins if available, for speed. * tests/test-intprops.c (INT_CONST_DIVIDE_OVERFLOW) (INT_CONST_REMAINDER_OVERFLOW, INT_CONST_LEFT_SHIFT_OVERFLOW) (INT_CONST_DIVIDE_WRAPV, INT_CONST_REMAINDER_WRAPV) (INT_CONST_LEFT_SHIFT_WRAPV): New macros. (main, CHECK_BINOP, CHECK_UNOP, CHECK_SUM, CHECK_PRODUCT) (CHECK_QUOTIENT, CHECK_REMAINDER): Test WRAPV and CONST flavors (when available) too.
* c-ctype: rewrite to use inline functionsPaul Eggert2015-09-251-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This simplifies maintenance, since it makes for just one implementation of each function, letting the compiler have the fun of optimization. In practice this works well nowadays with GCC. E.g., c_isascii might need only three instructions even though the source code lists every ASCII character individually in a large switch statement. Also, fix some z/OS porting bugs reported by Daniel Richard G. in: http://lists.gnu.org/archive/html/bug-gnulib/2015-09/msg00037.html * NEWS: Document the API change. * lib/c-ctype.c: Drastically simplify, since this now just expands inline functions. * lib/c-ctype.h: Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END. (C_CTYPE_INLINE): New macro. (C_CTYPE_CONSECUTIVE_DIGITS, C_CTYPE_CONSECUTIVE_LOWERCASE) (C_CTYPE_CONSECUTIVE_UPPERCASE): Remove. Verify that either ASCII or EBCDIC is being used. (_C_CTYPE_SIGNED_EBCDIC, _C_CTYPE_CNTRL, _C_CTYPE_A_THRU_F_N) (_C_CTYPE_DIGIT_N, _C_CTYPE_LOWER_N, _C_CTYPE_UPPER_N) (_C_CTYPE_CASES, _C_CTYPE_A_THRU_F, _C_CTYPE_DIGIT, _C_CTYPE_LOWER) (_C_CTYPE_UPPER, _C_CTYPE_PUNCT_PLAIN): New private macros. (_C_CTYPE_CNTRL): In EBCDIC, '\x07' is a control, not '\xff'. (c_isalnum, c_isalpha, c_isascii, c_isblank, c_iscntrl, c_isdigit) (c_isgraph, c_islower, c_isprint, c_ispunct, c_isspace, c_isupper) (c_isxdigit, c_tolower, c_toupper): Now inline functions. (c_tolower, c_toupper): When converting, return the unsigned char, as that is what z/OS does. * lib/c-strcaseeq.h (CASEEQ): Simplify in the light of the removal of some c-ctype.h macros. * modules/c-ctype (Depends-on): Add extern-inline; remove verify. * tests/test-c-ctype.c (test_all): Fix test for c_toupper and c_tolower promotion to be compatible with z/OS.
* maint: add coding cookies to non-ASCII sourcesPaul Eggert2015-09-241-0/+1
| | | | | | | | | | | | Otherwise, Emacs might do the wrong thing if run in an he_IL.ISO-8859-8 locale, which an Emacs developer does on occasion. Problem reported by Eli Zaretskii in: http://lists.gnu.org/archive/html/emacs-devel/2015-09/msg00966.html Don't bother with test files, as they aren't copied to the Emacs source directory. If this problem affects test files in some other GNU project, we can add coding cookies to the non-ASCII test files later.
* savewd: remove SAVEWD_CHDIR_READABLEPaul Eggert2015-09-221-0/+2
| | | | | | | | | | | | | | It was problematic in the light of file systems that ignore umask. Problem reported by Sebastian Ungar in: http://bugs.gnu.org/21534 * NEWS: Document this. * lib/mkancesdirs.c (mkancesdirs): MAKE_DIR now returns 0 if successful, -1 (setting errno) on failure, rather than something more complicated than that. * lib/mkdir-p.c (make_dir_parents): Do not use SAVEWD_CHDIR_READABLE. * lib/savewd.c (savewd_chdir): Remove support for SAVEWD_CHDIR_READABLE. * lib/savewd.h (SAVEWD_CHDIR_READABLE): Remove.
* fprintftime, strftime: use timezone_t argsPaul Eggert2015-07-231-0/+5
| | | | | | | | | | | | | | | | | | | | | | * NEWS: Document the change. * lib/fprintftime.h (fprintftime): * lib/strftime.c (extra_args) [my_strftime]: * lib/strftime.h (nstrftime): Time zone arg is now of type timezone_t, not int. * lib/strftime.c (mktime_z) [_LIBC]: New macro. (__gmtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: Remove; no longer used. (my_strftime) [emacs && !my_strftime]: (emacs_strftimeu) [emacs && !FPRINTFTIME]: Remove; Emacs doesn't need this any more. (HAVE_TZSET) [my_strftime]: Unset, since we no longer want fprintftime and nstrftime to call tzset. (ut) [!my_strftime]: Remove, replacing with ... (tz) [!my_stftime]: ... this new macro. All uses changed. (strftime_case_): Use localtime_rz and mktime_z instead of localtime_r and mktime. * modules/fprintftime (Depends-on): Add time_rz. * modules/strftime (Depends-on): Add time_rz. Remove time_r. * tests/test-strftime.c (main): Adjust to new nstrftime API.
* file-has-acl: new module, split from aclPaul Eggert2015-04-241-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | And add a new module file-has-acl-tests to match. I ran into a problem with the recent changes to the acl module, as they introduced a typo 'test use_xattrs = 0' into 'configure'. When using the fixed version with Emacs, I discovered that file-has-acl wasn't separated out well enough for Emacs (e.g., it had multiple libraries, but needed only one), so I fixed that too. * NEWS: Document this incompatible change. * modules/file-has-acl, modules/file-has-acl-tests: New files. * m4/acl.m4 (gl_FUNC_ACL_ARG): New macro, split from gl_FUNC_ACL. Initialize gl_need_lib_has_acl. (gl_FUNC_ACL): Require it. Simplify use of 'test'. Set LIB_HAS_ACL if gl_need_lib_has_acl. Move the file-has-acl.c-relevant stuff to ... (gl_FILE_HAS_ACL): ... this new macro. Rewrite to fix 'test use_xattrs = 0' typo, and omit some needless work. Set gl_need_lib_has_acl=1 if we'll need LIB_HAS_ACL to be set when gl_FUNC_ACL is called. * modules/acl (Files, lib_SOURCES): Remove lib/file-has-acl.c. (Link): Remove $(LIB_HAS_ACL). * modules/acl-tests (Files, Depends-on, configure.ac, TESTS) (check_PROGRAMS): Move stuff relevant to file-has-acl to modules/file-has-acl-tests. (test_file_has_acl_LDADD): Move to modules/file-has-acl-tests.
* acl: On Linux, check for acls without libaclAndreas Gruenbacher2015-04-151-0/+5
| | | | | | | | | | | | | On Linux, use the getxattr syscall instead of the acl_extended_file libacl library function to check for the presence of acls, avoiding a library dependency. * lib/file-has-acl.c: Include xattr headers if we have them. (file_has_acl): On Linux, use getxattr(). * m4/acl.m4 (gl_FUNC_ACL): Define LIB_HAS_ACL as the libraries to link with for file_has_acl(). Check for xattr headers and getxattr(). * modules/acl: Add a dep on the stdbool module which was already needed. Add the new reduced dependency LIB_HAS_ACL reference.
* hash: remove deprecated hash_insert0 functionGiuseppe Scrivano2015-04-031-0/+2
| | | | | | * lib/hash.h (hash_insert0): Remove deprecated function. * lib/hash.c (hash_insert0): Likewise. * NEWS: Document the interface change.
* obstack: add NEWS entry for recent incompatible changesPaul Eggert2014-10-311-1/+9
| | | | * NEWS: Describe recent changes.
* * NEWS: Recent changes are not that important.Paul Eggert2014-02-261-9/+9
|
* * NEWS: Document recent change to diffseq.Paul Eggert2014-02-231-0/+5
|
* savedir: add sorting arg to savedir, streamsavedir; remove fdsavedirSergey Poznyakoff2014-02-131-0/+4
| | | | | | | | | | | | | | | | | Patch based on an idea by Dick Streefland in <https://savannah.gnu.org/patch/?7892>. * NEWS: Document this. * lib/savedir.c (NAME_SIZE_DEFAULT): Remove. (direntry_t, comparison_function): New types. (direntry_cmp_name): New function. (direntry_cmp_inode) [D_INO_IN_DIRENT]: New function. (streamsavedir, savedir): New arg OPTION. (streamsavedir): Simplify memory allocation. (fdsavedir): Remove. * lib/savedir.h (enum savedir_option): New type. (streamsavedir, savedir): New arg OPTION. (fdsavedir): Remove.
* Assume gnulib is checked out from Git, not CVSStefano Lattarini2013-05-041-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | In fact, access to the gnulib repository through CVS has been disabled, or more precisely, got broken and was never restored; see: <http://lists.gnu.org/archive/html/bug-gnulib/2013-05/msg00008.html> Note that support for CVS is not removed completely and unthinkingly by this change: only support for CVS checkouts of gnulib itself is removed. For example, the 'bootstrap' script still cater to .cvsingore files and CVS directories, for the benefit of those poor gnulib clients still stuck with CVS. Ditto for the 'gnulib-tool' script itself. * gnulib-tool: Simplify accordingly. * posix-modules: Likewise. * MODULES.html.sh: Likewise. * doc/gnulib.texi: No longer mention the decommissioned CVS gnulib repository. * doc/gnulib-intro.texi: Likewise. * doc/gnulib-readme.texi: Likewise. * doc/gnulib-tool.texi: In the examples and explanations, refer to a sample '.gitignore' file rather than a sample '.cvsignore'. * NEWS: Update. * m4/extensions.m4: While at it, remove a comment mistakenly referring to "CVS Autoconf" rather than "git Autoconf". Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com> Acked-by: Paul Eggert <eggert@cs.ucla.edu>
* gettext: now it's your responsibility to add -I$(top_builddir)/intlPaul Eggert2013-04-301-0/+4
| | | | | | | | Formerly, it was your responsibility to do this for all Makefile.ams other than Gnulib's. Now it's your responsibility to do it for Gnulib's Makefile.am, too. * NEWS: Document this. * modules/gettext (AM_CPPFLAGS): Don't append -$(top_builddir)/intl.
* careadlinkat: stop exporting careadlinkatcwdPaul Eggert2013-02-081-0/+3
| | | | | | | | | | | | | | | Only Emacs used it directly, and Emacs no longer needs it. * NEWS: Document this simplification. * lib/areadlink.c (careadlinkatcwd): Move here from careadlinkat.c, and make it static. Include <stdlib.h>, for abort, and unistd.h, for readlink. * lib/careadlinkat.c (careadlinkatcwd): Move to areadlink.c. Don't include stdlib.h; no longer needed. * lib/careadlinkat.h (careadlinkatcwd): Remove decl. * lib/relocwrapper.c: Adjust comment to match new dependencies. * modules/areadlink (Depends-on): Add readlink. (Maintainer): Add self. * modules/careadlinkat (Depends-on): Remove readlink.
* config: drop scripts that automake says are not independentEric Blake2012-06-271-0/+3
| | | | | | | | | | | | | | | | | | | | | | | These three scripts are too closely tied to automake internals to be independently useful. In fact, automake would rather that people did not mix the latest version of these scripts with older versions of automake, as there is no effort being put into maintaining backwards-compatibility when these scripts are updated. The remaining scripts pulled from automake, such as mdate-sh or depcomp, are independently useful, so a future patch may end up reparenting those scripts to have gnulib instead of automake as the master owner. * config/srclist.txt: Drop elisp-comp, missing, and ylwrap. * build-aux/elisp-comp: Delete. * build-aux/missing: Likewise. * build-aux/ylwrap: Likewise. * modules/elisp-comp: Likewise. * MODULES.html.sh: Drop mention of elisp-comp. * NEWS: Mention this. Signed-off-by: Eric Blake <eblake@redhat.com>
* getopt-posix: No longer guarantee that option processing is resettable.Bruno Haible2012-06-261-0/+5
| | | | | | | | | | * doc/posix-functions/getopt.texi: Drop description of problem with internal state. Fix info about mingw and msvc9. * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Don't require a resettable option processing by getopt(). Run three test programs instead of one. Simplify cross-compilation guess. * NEWS: Mention the change. Reported by Rich Felker <dalias@aerifal.cx>.
* gnulib-tool: --create-[mega]testdir, --[mega]test implies --with-tests.Bruno Haible2012-06-211-0/+4
| | | | | | | | * gnulib-tool: Accept option --without-tests. (func_usage): Document --without-tests option. Rearrange. (inctests): Normalize according to the mode. * NEWS: Mention the change. Suggested by Simon Josefsson.
* streq: Rename macro.Bruno Haible2012-02-241-0/+3
| | | | | | | | | * lib/streq.h (STREQ_OPT): Renamed from STREQ. * NEWS: Mention the change. * lib/mbrtowc.c (mbrtowc): Update. * lib/uniwidth/cjk.h (is_cjk_encoding): Update. * lib/wcwidth.c (wcwidth): Update. Suggested by Akim Demaille and Jim Meyering.
* maint: spelling fixesPaul Eggert2012-02-051-2/+2
|
* ignore-value: remove deprecated ignore_ptr functionJim Meyering2012-01-101-0/+5
| | | | | * lib/ignore-value.h (ignore_ptr): Remove deprecated function. * NEWS: Note this.
* Add ChangeLog entries for last 3 commits.Paolo Bonzini2012-01-071-1/+1
|
* quotearg: do not use grave accent for left quotePaolo Bonzini2012-01-071-0/+9
| | | | | | * lib/quotearg.c (gettext_quote): Map "`" to "'" for locale_quoting_style. (quotearg_buffer_restyled): Fix example. * tests/test-quotearg-simple.c (results_g): Adjust test vectors.
* In commentary, do not use ` to quote.Paul Eggert2012-01-051-1/+1
|
* hash: deprecate poorly-named hash_insert0: use hash_insert_if_absentJim Meyering2011-11-181-0/+4
| | | | | | | | | | | | | * lib/hash.c (hash_insert_if_absent): Rename from hash_insert0. Add a sentence to the comment. (hash_insert0): New function that simply calls hash_insert_if_absent. * lib/hash.h (hash_insert_if_absent): Declare it. (hash_insert0): Add deprecation attribute. (_GL_ATTRIBUTE_DEPRECATED): Define. * lib/di-set.c (di_set_insert): Use hash_insert_if_absent, not hash_insert0. * NEWS: Mention it, even though it's not really an incompatible change Prompted by a question from Matthew Booth <mbooth@redhat.com>.
* New module 'mkdirat', split off from module 'openat'.Bruno Haible2011-11-041-0/+4
| | | | | | | | | | | | | | | | | | | * m4/mkdirat.m4: New file. extracted from m4/openat.m4. * m4/openat.m4 (gl_FUNC_OPENAT): Don't require gl_SYS_STAT_H_DEFAULTS. Don't test for mkdirat. Don't set GNULIB_MKDIRAT, HAVE_MKDIRAT. * modules/mkdirat: New file, extracted from modules/openat. * modules/openat (Files): Remove lib/mkdirat.c. (Depends-on): Remove mkdir. (configure.ac): Remove AC_LIBOBJ of mkdirat. (Include): Remove <sys/stat.h>. * modules/mkdirat-tests: New file, extracted from modules/openat-tests. * modules/openat-tests (Files): Remove tests/test-mkdirat.c, tests/test-mkdir.h. (Depends-on): Remove ignore-value. (Makefile.am): Remove rules for test-mkdirat. * doc/posix-functions/mkdirat.texi: Mention module 'mkdirat' instead of module 'openat'. * NEWS: Mention the change.
* New module 'fstatat', split off from module 'openat'.Bruno Haible2011-11-041-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | * lib/openat.h (statat, lstatat): Enable only if GNULIB_FSTATAT is defined. * m4/fstatat.m4: New file. extracted from m4/openat.m4. * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_FSTATAT. Don't invoke gl_FUNC_FSTATAT. (gl_FUNC_FSTATAT): Moved to m4/fstatat.m4. * modules/fstatat: New file, extracted from modules/openat. * modules/openat (Files): Remove lib/fstatat.c. (Depends-on): Remove lstat. (configure.ac): Remove AC_LIBOBJ of fstatat. * modules/fstatat-tests: New file, extracted from modules/openat-tests. * modules/openat-tests (Files): Remove tests/test-fstatat.c, tests/test-lstat.h, tests/test-stat.h. (Depends-on): Remove getcwd-lgpl. (Makefile.am): Remove rules for test-fstatat. * doc/posix-functions/fstatat.texi: Mention module 'fstatat' instead of module 'openat'. * NEWS: Mention the change. * modules/getcwd (Depends-on): Add fstatat. * modules/linkat (Depends-on): Likewise. * modules/mkfifoat-tests (Depends-on): Likewise. * modules/utimensat (Depends-on): Add fstatat. Remove openat.
* New module 'unlinkat', split off from module 'openat'.Bruno Haible2011-11-021-1/+5
| | | | | | | | | | | | | | | | | | | | | | * m4/unlinkat.m4: New file, extracted from m4/openat.m4. * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_UNLINKAT, REPLACE_UNLINKAT, HAVE_UNLINKAT. Don't test for unlinkat. * modules/unlinkat: New file, extracted from modules/openat. Correct the dependency conditions. * modules/openat (Files): Remove lib/unlinkat.c. (Depends-on): Remove rmdir, unlink. (configure.ac): Remove AC_LIBOBJ of unlinkat. * modules/unlinkat-tests: New file, extracted from modules/openat-tests. * modules/openat-tests (Files): Remove tests/test-unlinkat.c, tests/test-rmdir.h, tests/test-unlink.h. (Depends-on): Remove unlinkdir. (Makefile.am): Remove rules for test-unlinkat. * doc/posix-functions/unlinkat.texi: Mention module 'unlinkat' instead of module 'openat'. * NEWS: Mention the change. * modules/linkat-tests (Depends-on): Add unlinkat. * modules/mkfifoat-tests (Depends-on): Likewise. * modules/readlinkat-tests (Depends-on): Likewise.
* New module 'fchmodat', split off from module 'openat'.Bruno Haible2011-11-021-0/+4
| | | | | | | | | | | | | | | | | * lib/openat.h (chmodat, lchmodat): Enable only if GNULIB_FCHMODAT is defined. * m4/fchmodat.m4: New file, extracted from m4/openat.m4. * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_FCHMODAT. Don't test for fchmodat, lchmod. Don't set HAVE_FCHMODAT. * modules/fchmodat: New file, extracted from modules/openat. * modules/openat (Files): Remove lib/fchmodat.c. (configure.ac): Remove AC_LIBOBJ of fchmodat. * modules/fchmodat-tests: New file, extracted from modules/openat-tests. * modules/openat-tests (Files): Remove tests/test-fchmodat.c. (Makefile.am): Remove rules for test-fchmodat. * doc/posix-functions/fchmodat.texi: Mention module 'fchmodat' instead of module 'openat'. * NEWS: Mention the change.
* alignof: Avoid collision with stdalign module.Bruno Haible2011-11-011-0/+3
| | | | | | * lib/alignof.h (alignof): Remove macro. * NEWS: Mention the change. Reported by Paul Eggert.