diff options
| author | Daniel Colascione | 2019-06-23 18:19:08 -0700 |
|---|---|---|
| committer | Daniel Colascione | 2019-06-23 18:19:08 -0700 |
| commit | b9ac4f815ebaa1acb0d045fe9583f665efa6f628 (patch) | |
| tree | f2bfcf685bb9f83a67c5f70fe8e4f65ef16d8690 /m4 | |
| parent | f3b1b5fb5034de026adc41cf2403cff42f4a0b67 (diff) | |
| download | emacs-b9ac4f815ebaa1acb0d045fe9583f665efa6f628.tar.gz emacs-b9ac4f815ebaa1acb0d045fe9583f665efa6f628.zip | |
Fix locating pdump by symlink
* admin/merge-gnulib (GNULIB_MODULES): Add canonicalize-lgpl module
* build-aux/config.guess, build-aux/gitlog-to-changelog,
build-aux/update-copyright, lib/canonicalize-lgpl.c,
lib/gnulib.mk.in, lib/malloca.c, lib/malloca.h, lib/pathmax.h,
m4/canonicalize.m4, m4/double-slash-root.m4, m4/gnulib-comp.m4,
m4/malloca.m4, my/pathmax.4: copy from GNUlib or regenerate from
update
* src/emacs.c: find dump by canonical path
Diffstat (limited to 'm4')
| -rw-r--r-- | m4/canonicalize.m4 | 133 | ||||
| -rw-r--r-- | m4/double-slash-root.m4 | 38 | ||||
| -rw-r--r-- | m4/gnulib-comp.m4 | 43 | ||||
| -rw-r--r-- | m4/malloca.m4 | 15 | ||||
| -rw-r--r-- | m4/pathmax.m4 | 42 |
5 files changed, 271 insertions, 0 deletions
diff --git a/m4/canonicalize.m4 b/m4/canonicalize.m4 new file mode 100644 index 00000000000..b61747bd1a5 --- /dev/null +++ b/m4/canonicalize.m4 | |||
| @@ -0,0 +1,133 @@ | |||
| 1 | # canonicalize.m4 serial 30 | ||
| 2 | |||
| 3 | dnl Copyright (C) 2003-2007, 2009-2019 Free Software Foundation, Inc. | ||
| 4 | |||
| 5 | dnl This file is free software; the Free Software Foundation | ||
| 6 | dnl gives unlimited permission to copy and/or distribute it, | ||
| 7 | dnl with or without modifications, as long as this notice is preserved. | ||
| 8 | |||
| 9 | # Provides canonicalize_file_name and canonicalize_filename_mode, but does | ||
| 10 | # not provide or fix realpath. | ||
| 11 | AC_DEFUN([gl_FUNC_CANONICALIZE_FILENAME_MODE], | ||
| 12 | [ | ||
| 13 | AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS]) | ||
| 14 | AC_CHECK_FUNCS_ONCE([canonicalize_file_name]) | ||
| 15 | AC_REQUIRE([gl_DOUBLE_SLASH_ROOT]) | ||
| 16 | AC_REQUIRE([gl_FUNC_REALPATH_WORKS]) | ||
| 17 | if test $ac_cv_func_canonicalize_file_name = no; then | ||
| 18 | HAVE_CANONICALIZE_FILE_NAME=0 | ||
| 19 | else | ||
| 20 | case "$gl_cv_func_realpath_works" in | ||
| 21 | *yes) ;; | ||
| 22 | *) REPLACE_CANONICALIZE_FILE_NAME=1 ;; | ||
| 23 | esac | ||
| 24 | fi | ||
| 25 | ]) | ||
| 26 | |||
| 27 | # Provides canonicalize_file_name and realpath. | ||
| 28 | AC_DEFUN([gl_CANONICALIZE_LGPL], | ||
| 29 | [ | ||
| 30 | AC_REQUIRE([gl_STDLIB_H_DEFAULTS]) | ||
| 31 | AC_REQUIRE([gl_CANONICALIZE_LGPL_SEPARATE]) | ||
| 32 | if test $ac_cv_func_canonicalize_file_name = no; then | ||
| 33 | HAVE_CANONICALIZE_FILE_NAME=0 | ||
| 34 | if test $ac_cv_func_realpath = no; then | ||
| 35 | HAVE_REALPATH=0 | ||
| 36 | else | ||
| 37 | case "$gl_cv_func_realpath_works" in | ||
| 38 | *yes) ;; | ||
| 39 | *) REPLACE_REALPATH=1 ;; | ||
| 40 | esac | ||
| 41 | fi | ||
| 42 | else | ||
| 43 | case "$gl_cv_func_realpath_works" in | ||
| 44 | *yes) | ||
| 45 | ;; | ||
| 46 | *) | ||
| 47 | REPLACE_CANONICALIZE_FILE_NAME=1 | ||
| 48 | REPLACE_REALPATH=1 | ||
| 49 | ;; | ||
| 50 | esac | ||
| 51 | fi | ||
| 52 | ]) | ||
| 53 | |||
| 54 | # Like gl_CANONICALIZE_LGPL, except prepare for separate compilation | ||
| 55 | # (no REPLACE_CANONICALIZE_FILE_NAME, no REPLACE_REALPATH, no AC_LIBOBJ). | ||
| 56 | AC_DEFUN([gl_CANONICALIZE_LGPL_SEPARATE], | ||
| 57 | [ | ||
| 58 | AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS]) | ||
| 59 | AC_CHECK_FUNCS_ONCE([canonicalize_file_name getcwd readlink]) | ||
| 60 | AC_REQUIRE([gl_DOUBLE_SLASH_ROOT]) | ||
| 61 | AC_REQUIRE([gl_FUNC_REALPATH_WORKS]) | ||
| 62 | AC_CHECK_HEADERS_ONCE([sys/param.h]) | ||
| 63 | ]) | ||
| 64 | |||
| 65 | # Check whether realpath works. Assume that if a platform has both | ||
| 66 | # realpath and canonicalize_file_name, but the former is broken, then | ||
| 67 | # so is the latter. | ||
| 68 | AC_DEFUN([gl_FUNC_REALPATH_WORKS], | ||
| 69 | [ | ||
| 70 | AC_CHECK_FUNCS_ONCE([realpath]) | ||
| 71 | AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles | ||
| 72 | AC_CACHE_CHECK([whether realpath works], [gl_cv_func_realpath_works], [ | ||
| 73 | touch conftest.a | ||
| 74 | mkdir conftest.d | ||
| 75 | AC_RUN_IFELSE([ | ||
| 76 | AC_LANG_PROGRAM([[ | ||
| 77 | ]GL_NOCRASH[ | ||
| 78 | #include <stdlib.h> | ||
| 79 | #include <string.h> | ||
| 80 | ]], [[ | ||
| 81 | int result = 0; | ||
| 82 | { | ||
| 83 | char *name = realpath ("conftest.a", NULL); | ||
| 84 | if (!(name && *name == '/')) | ||
| 85 | result |= 1; | ||
| 86 | free (name); | ||
| 87 | } | ||
| 88 | { | ||
| 89 | char *name = realpath ("conftest.b/../conftest.a", NULL); | ||
| 90 | if (name != NULL) | ||
| 91 | result |= 2; | ||
| 92 | free (name); | ||
| 93 | } | ||
| 94 | { | ||
| 95 | char *name = realpath ("conftest.a/", NULL); | ||
| 96 | if (name != NULL) | ||
| 97 | result |= 4; | ||
| 98 | free (name); | ||
| 99 | } | ||
| 100 | { | ||
| 101 | char *name1 = realpath (".", NULL); | ||
| 102 | char *name2 = realpath ("conftest.d//./..", NULL); | ||
| 103 | if (! name1 || ! name2 || strcmp (name1, name2)) | ||
| 104 | result |= 8; | ||
| 105 | free (name1); | ||
| 106 | free (name2); | ||
| 107 | } | ||
| 108 | return result; | ||
| 109 | ]]) | ||
| 110 | ], | ||
| 111 | [gl_cv_func_realpath_works=yes], | ||
| 112 | [gl_cv_func_realpath_works=no], | ||
| 113 | [case "$host_os" in | ||
| 114 | # Guess yes on glibc systems. | ||
| 115 | *-gnu* | gnu*) gl_cv_func_realpath_works="guessing yes" ;; | ||
| 116 | # Guess yes on musl systems. | ||
| 117 | *-musl*) gl_cv_func_realpath_works="guessing yes" ;; | ||
| 118 | # Guess no on native Windows. | ||
| 119 | mingw*) gl_cv_func_realpath_works="guessing no" ;; | ||
| 120 | # If we don't know, assume the worst. | ||
| 121 | *) gl_cv_func_realpath_works="guessing no" ;; | ||
| 122 | esac | ||
| 123 | ]) | ||
| 124 | rm -rf conftest.a conftest.d | ||
| 125 | ]) | ||
| 126 | case "$gl_cv_func_realpath_works" in | ||
| 127 | *yes) | ||
| 128 | AC_DEFINE([FUNC_REALPATH_WORKS], [1], [Define to 1 if realpath() | ||
| 129 | can malloc memory, always gives an absolute path, and handles | ||
| 130 | trailing slash correctly.]) | ||
| 131 | ;; | ||
| 132 | esac | ||
| 133 | ]) | ||
diff --git a/m4/double-slash-root.m4 b/m4/double-slash-root.m4 new file mode 100644 index 00000000000..0c5afb17156 --- /dev/null +++ b/m4/double-slash-root.m4 | |||
| @@ -0,0 +1,38 @@ | |||
| 1 | # double-slash-root.m4 serial 4 -*- Autoconf -*- | ||
| 2 | dnl Copyright (C) 2006, 2008-2019 Free Software Foundation, Inc. | ||
| 3 | dnl This file is free software; the Free Software Foundation | ||
| 4 | dnl gives unlimited permission to copy and/or distribute it, | ||
| 5 | dnl with or without modifications, as long as this notice is preserved. | ||
| 6 | |||
| 7 | AC_DEFUN([gl_DOUBLE_SLASH_ROOT], | ||
| 8 | [ | ||
| 9 | AC_REQUIRE([AC_CANONICAL_HOST]) | ||
| 10 | AC_CACHE_CHECK([whether // is distinct from /], [gl_cv_double_slash_root], | ||
| 11 | [ if test x"$cross_compiling" = xyes ; then | ||
| 12 | # When cross-compiling, there is no way to tell whether // is special | ||
| 13 | # short of a list of hosts. However, the only known hosts to date | ||
| 14 | # that have a distinct // are Apollo DomainOS (too old to port to), | ||
| 15 | # Cygwin, and z/OS. If anyone knows of another system for which // has | ||
| 16 | # special semantics and is distinct from /, please report it to | ||
| 17 | # <bug-gnulib@gnu.org>. | ||
| 18 | case $host in | ||
| 19 | *-cygwin | i370-ibm-openedition) | ||
| 20 | gl_cv_double_slash_root=yes ;; | ||
| 21 | *) | ||
| 22 | # Be optimistic and assume that / and // are the same when we | ||
| 23 | # don't know. | ||
| 24 | gl_cv_double_slash_root='unknown, assuming no' ;; | ||
| 25 | esac | ||
| 26 | else | ||
| 27 | set x `ls -di / // 2>/dev/null` | ||
| 28 | if test "$[2]" = "$[4]" && wc //dev/null >/dev/null 2>&1; then | ||
| 29 | gl_cv_double_slash_root=no | ||
| 30 | else | ||
| 31 | gl_cv_double_slash_root=yes | ||
| 32 | fi | ||
| 33 | fi]) | ||
| 34 | if test "$gl_cv_double_slash_root" = yes; then | ||
| 35 | AC_DEFINE([DOUBLE_SLASH_IS_DISTINCT_ROOT], [1], | ||
| 36 | [Define to 1 if // is a file system root distinct from /.]) | ||
| 37 | fi | ||
| 38 | ]) | ||
diff --git a/m4/gnulib-comp.m4 b/m4/gnulib-comp.m4 index 4627575bf63..cb6dce15ccf 100644 --- a/m4/gnulib-comp.m4 +++ b/m4/gnulib-comp.m4 | |||
| @@ -52,6 +52,7 @@ AC_DEFUN([gl_EARLY], | |||
| 52 | # Code from module byteswap: | 52 | # Code from module byteswap: |
| 53 | # Code from module c-ctype: | 53 | # Code from module c-ctype: |
| 54 | # Code from module c-strcase: | 54 | # Code from module c-strcase: |
| 55 | # Code from module canonicalize-lgpl: | ||
| 55 | # Code from module careadlinkat: | 56 | # Code from module careadlinkat: |
| 56 | # Code from module clock-time: | 57 | # Code from module clock-time: |
| 57 | # Code from module cloexec: | 58 | # Code from module cloexec: |
| @@ -113,6 +114,7 @@ AC_DEFUN([gl_EARLY], | |||
| 113 | # Code from module limits-h: | 114 | # Code from module limits-h: |
| 114 | # Code from module localtime-buffer: | 115 | # Code from module localtime-buffer: |
| 115 | # Code from module lstat: | 116 | # Code from module lstat: |
| 117 | # Code from module malloca: | ||
| 116 | # Code from module manywarnings: | 118 | # Code from module manywarnings: |
| 117 | # Code from module memmem-simple: | 119 | # Code from module memmem-simple: |
| 118 | # Code from module memrchr: | 120 | # Code from module memrchr: |
| @@ -125,6 +127,7 @@ AC_DEFUN([gl_EARLY], | |||
| 125 | # Code from module nstrftime: | 127 | # Code from module nstrftime: |
| 126 | # Code from module open: | 128 | # Code from module open: |
| 127 | # Code from module openat-h: | 129 | # Code from module openat-h: |
| 130 | # Code from module pathmax: | ||
| 128 | # Code from module pipe2: | 131 | # Code from module pipe2: |
| 129 | # Code from module pselect: | 132 | # Code from module pselect: |
| 130 | # Code from module pthread_sigmask: | 133 | # Code from module pthread_sigmask: |
| @@ -199,6 +202,13 @@ AC_DEFUN([gl_INIT], | |||
| 199 | gl_FUNC_ALLOCA | 202 | gl_FUNC_ALLOCA |
| 200 | gl___BUILTIN_EXPECT | 203 | gl___BUILTIN_EXPECT |
| 201 | gl_BYTESWAP | 204 | gl_BYTESWAP |
| 205 | gl_CANONICALIZE_LGPL | ||
| 206 | if test $HAVE_CANONICALIZE_FILE_NAME = 0 || test $REPLACE_CANONICALIZE_FILE_NAME = 1; then | ||
| 207 | AC_LIBOBJ([canonicalize-lgpl]) | ||
| 208 | fi | ||
| 209 | gl_MODULE_INDICATOR([canonicalize-lgpl]) | ||
| 210 | gl_STDLIB_MODULE_INDICATOR([canonicalize_file_name]) | ||
| 211 | gl_STDLIB_MODULE_INDICATOR([realpath]) | ||
| 202 | AC_CHECK_FUNCS_ONCE([readlinkat]) | 212 | AC_CHECK_FUNCS_ONCE([readlinkat]) |
| 203 | gl_CLOCK_TIME | 213 | gl_CLOCK_TIME |
| 204 | gl_MODULE_INDICATOR([close-stream]) | 214 | gl_MODULE_INDICATOR([close-stream]) |
| @@ -447,9 +457,11 @@ AC_DEFUN([gl_INIT], | |||
| 447 | gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=false | 457 | gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=false |
| 448 | gl_gnulib_enabled_21ee726a3540c09237a8e70c0baf7467=false | 458 | gl_gnulib_enabled_21ee726a3540c09237a8e70c0baf7467=false |
| 449 | gl_gnulib_enabled_2049e887c7e5308faad27b3f894bb8c9=false | 459 | gl_gnulib_enabled_2049e887c7e5308faad27b3f894bb8c9=false |
| 460 | gl_gnulib_enabled_malloca=false | ||
| 450 | gl_gnulib_enabled_5264294aa0a5557541b53c8c741f7f31=false | 461 | gl_gnulib_enabled_5264294aa0a5557541b53c8c741f7f31=false |
| 451 | gl_gnulib_enabled_open=false | 462 | gl_gnulib_enabled_open=false |
| 452 | gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=false | 463 | gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=false |
| 464 | gl_gnulib_enabled_pathmax=false | ||
| 453 | gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=false | 465 | gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=false |
| 454 | gl_gnulib_enabled_strtoll=false | 466 | gl_gnulib_enabled_strtoll=false |
| 455 | gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=false | 467 | gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=false |
| @@ -561,6 +573,14 @@ AC_DEFUN([gl_INIT], | |||
| 561 | gl_gnulib_enabled_2049e887c7e5308faad27b3f894bb8c9=true | 573 | gl_gnulib_enabled_2049e887c7e5308faad27b3f894bb8c9=true |
| 562 | fi | 574 | fi |
| 563 | } | 575 | } |
| 576 | func_gl_gnulib_m4code_malloca () | ||
| 577 | { | ||
| 578 | if ! $gl_gnulib_enabled_malloca; then | ||
| 579 | gl_MALLOCA | ||
| 580 | gl_gnulib_enabled_malloca=true | ||
| 581 | func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec | ||
| 582 | fi | ||
| 583 | } | ||
| 564 | func_gl_gnulib_m4code_5264294aa0a5557541b53c8c741f7f31 () | 584 | func_gl_gnulib_m4code_5264294aa0a5557541b53c8c741f7f31 () |
| 565 | { | 585 | { |
| 566 | if ! $gl_gnulib_enabled_5264294aa0a5557541b53c8c741f7f31; then | 586 | if ! $gl_gnulib_enabled_5264294aa0a5557541b53c8c741f7f31; then |
| @@ -593,6 +613,13 @@ AC_DEFUN([gl_INIT], | |||
| 593 | gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=true | 613 | gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=true |
| 594 | fi | 614 | fi |
| 595 | } | 615 | } |
| 616 | func_gl_gnulib_m4code_pathmax () | ||
| 617 | { | ||
| 618 | if ! $gl_gnulib_enabled_pathmax; then | ||
| 619 | gl_PATHMAX | ||
| 620 | gl_gnulib_enabled_pathmax=true | ||
| 621 | fi | ||
| 622 | } | ||
| 596 | func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c () | 623 | func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c () |
| 597 | { | 624 | { |
| 598 | if ! $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then | 625 | if ! $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then |
| @@ -617,6 +644,12 @@ AC_DEFUN([gl_INIT], | |||
| 617 | gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=true | 644 | gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=true |
| 618 | fi | 645 | fi |
| 619 | } | 646 | } |
| 647 | if test $HAVE_CANONICALIZE_FILE_NAME = 0 || test $REPLACE_CANONICALIZE_FILE_NAME = 1; then | ||
| 648 | func_gl_gnulib_m4code_malloca | ||
| 649 | fi | ||
| 650 | if test $HAVE_CANONICALIZE_FILE_NAME = 0 || test $REPLACE_CANONICALIZE_FILE_NAME = 1; then | ||
| 651 | func_gl_gnulib_m4code_pathmax | ||
| 652 | fi | ||
| 620 | if test $HAVE_FACCESSAT = 0 || test $REPLACE_FACCESSAT = 1; then | 653 | if test $HAVE_FACCESSAT = 0 || test $REPLACE_FACCESSAT = 1; then |
| 621 | func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b | 654 | func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b |
| 622 | fi | 655 | fi |
| @@ -676,9 +709,11 @@ AC_DEFUN([gl_INIT], | |||
| 676 | AM_CONDITIONAL([gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1], [$gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1]) | 709 | AM_CONDITIONAL([gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1], [$gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1]) |
| 677 | AM_CONDITIONAL([gl_GNULIB_ENABLED_21ee726a3540c09237a8e70c0baf7467], [$gl_gnulib_enabled_21ee726a3540c09237a8e70c0baf7467]) | 710 | AM_CONDITIONAL([gl_GNULIB_ENABLED_21ee726a3540c09237a8e70c0baf7467], [$gl_gnulib_enabled_21ee726a3540c09237a8e70c0baf7467]) |
| 678 | AM_CONDITIONAL([gl_GNULIB_ENABLED_2049e887c7e5308faad27b3f894bb8c9], [$gl_gnulib_enabled_2049e887c7e5308faad27b3f894bb8c9]) | 711 | AM_CONDITIONAL([gl_GNULIB_ENABLED_2049e887c7e5308faad27b3f894bb8c9], [$gl_gnulib_enabled_2049e887c7e5308faad27b3f894bb8c9]) |
| 712 | AM_CONDITIONAL([gl_GNULIB_ENABLED_malloca], [$gl_gnulib_enabled_malloca]) | ||
| 679 | AM_CONDITIONAL([gl_GNULIB_ENABLED_5264294aa0a5557541b53c8c741f7f31], [$gl_gnulib_enabled_5264294aa0a5557541b53c8c741f7f31]) | 713 | AM_CONDITIONAL([gl_GNULIB_ENABLED_5264294aa0a5557541b53c8c741f7f31], [$gl_gnulib_enabled_5264294aa0a5557541b53c8c741f7f31]) |
| 680 | AM_CONDITIONAL([gl_GNULIB_ENABLED_open], [$gl_gnulib_enabled_open]) | 714 | AM_CONDITIONAL([gl_GNULIB_ENABLED_open], [$gl_gnulib_enabled_open]) |
| 681 | AM_CONDITIONAL([gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7], [$gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7]) | 715 | AM_CONDITIONAL([gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7], [$gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7]) |
| 716 | AM_CONDITIONAL([gl_GNULIB_ENABLED_pathmax], [$gl_gnulib_enabled_pathmax]) | ||
| 682 | AM_CONDITIONAL([gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c], [$gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c]) | 717 | AM_CONDITIONAL([gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c], [$gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c]) |
| 683 | AM_CONDITIONAL([gl_GNULIB_ENABLED_strtoll], [$gl_gnulib_enabled_strtoll]) | 718 | AM_CONDITIONAL([gl_GNULIB_ENABLED_strtoll], [$gl_gnulib_enabled_strtoll]) |
| 684 | AM_CONDITIONAL([gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec], [$gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec]) | 719 | AM_CONDITIONAL([gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec], [$gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec]) |
| @@ -845,6 +880,7 @@ AC_DEFUN([gl_FILE_LIST], [ | |||
| 845 | lib/c-strcase.h | 880 | lib/c-strcase.h |
| 846 | lib/c-strcasecmp.c | 881 | lib/c-strcasecmp.c |
| 847 | lib/c-strncasecmp.c | 882 | lib/c-strncasecmp.c |
| 883 | lib/canonicalize-lgpl.c | ||
| 848 | lib/careadlinkat.c | 884 | lib/careadlinkat.c |
| 849 | lib/careadlinkat.h | 885 | lib/careadlinkat.h |
| 850 | lib/cdefs.h | 886 | lib/cdefs.h |
| @@ -915,6 +951,8 @@ AC_DEFUN([gl_FILE_LIST], [ | |||
| 915 | lib/localtime-buffer.c | 951 | lib/localtime-buffer.c |
| 916 | lib/localtime-buffer.h | 952 | lib/localtime-buffer.h |
| 917 | lib/lstat.c | 953 | lib/lstat.c |
| 954 | lib/malloca.c | ||
| 955 | lib/malloca.h | ||
| 918 | lib/md5.c | 956 | lib/md5.c |
| 919 | lib/md5.h | 957 | lib/md5.h |
| 920 | lib/memmem.c | 958 | lib/memmem.c |
| @@ -928,6 +966,7 @@ AC_DEFUN([gl_FILE_LIST], [ | |||
| 928 | lib/openat-priv.h | 966 | lib/openat-priv.h |
| 929 | lib/openat-proc.c | 967 | lib/openat-proc.c |
| 930 | lib/openat.h | 968 | lib/openat.h |
| 969 | lib/pathmax.h | ||
| 931 | lib/pipe2.c | 970 | lib/pipe2.c |
| 932 | lib/pselect.c | 971 | lib/pselect.c |
| 933 | lib/pthread_sigmask.c | 972 | lib/pthread_sigmask.c |
| @@ -1001,6 +1040,7 @@ AC_DEFUN([gl_FILE_LIST], [ | |||
| 1001 | m4/alloca.m4 | 1040 | m4/alloca.m4 |
| 1002 | m4/builtin-expect.m4 | 1041 | m4/builtin-expect.m4 |
| 1003 | m4/byteswap.m4 | 1042 | m4/byteswap.m4 |
| 1043 | m4/canonicalize.m4 | ||
| 1004 | m4/clock_time.m4 | 1044 | m4/clock_time.m4 |
| 1005 | m4/copy-file-range.m4 | 1045 | m4/copy-file-range.m4 |
| 1006 | m4/count-leading-zeros.m4 | 1046 | m4/count-leading-zeros.m4 |
| @@ -1009,6 +1049,7 @@ AC_DEFUN([gl_FILE_LIST], [ | |||
| 1009 | m4/d-type.m4 | 1049 | m4/d-type.m4 |
| 1010 | m4/dirent_h.m4 | 1050 | m4/dirent_h.m4 |
| 1011 | m4/dirfd.m4 | 1051 | m4/dirfd.m4 |
| 1052 | m4/double-slash-root.m4 | ||
| 1012 | m4/dup2.m4 | 1053 | m4/dup2.m4 |
| 1013 | m4/eealloc.m4 | 1054 | m4/eealloc.m4 |
| 1014 | m4/environ.m4 | 1055 | m4/environ.m4 |
| @@ -1048,6 +1089,7 @@ AC_DEFUN([gl_FILE_LIST], [ | |||
| 1048 | m4/localtime-buffer.m4 | 1089 | m4/localtime-buffer.m4 |
| 1049 | m4/longlong.m4 | 1090 | m4/longlong.m4 |
| 1050 | m4/lstat.m4 | 1091 | m4/lstat.m4 |
| 1092 | m4/malloca.m4 | ||
| 1051 | m4/manywarnings-c++.m4 | 1093 | m4/manywarnings-c++.m4 |
| 1052 | m4/manywarnings.m4 | 1094 | m4/manywarnings.m4 |
| 1053 | m4/mbstate_t.m4 | 1095 | m4/mbstate_t.m4 |
| @@ -1064,6 +1106,7 @@ AC_DEFUN([gl_FILE_LIST], [ | |||
| 1064 | m4/off_t.m4 | 1106 | m4/off_t.m4 |
| 1065 | m4/open-cloexec.m4 | 1107 | m4/open-cloexec.m4 |
| 1066 | m4/open.m4 | 1108 | m4/open.m4 |
| 1109 | m4/pathmax.m4 | ||
| 1067 | m4/pipe2.m4 | 1110 | m4/pipe2.m4 |
| 1068 | m4/pselect.m4 | 1111 | m4/pselect.m4 |
| 1069 | m4/pthread_sigmask.m4 | 1112 | m4/pthread_sigmask.m4 |
diff --git a/m4/malloca.m4 b/m4/malloca.m4 new file mode 100644 index 00000000000..820f40a8a88 --- /dev/null +++ b/m4/malloca.m4 | |||
| @@ -0,0 +1,15 @@ | |||
| 1 | # malloca.m4 serial 1 | ||
| 2 | dnl Copyright (C) 2003-2004, 2006-2007, 2009-2019 Free Software Foundation, | ||
| 3 | dnl Inc. | ||
| 4 | dnl This file is free software; the Free Software Foundation | ||
| 5 | dnl gives unlimited permission to copy and/or distribute it, | ||
| 6 | dnl with or without modifications, as long as this notice is preserved. | ||
| 7 | |||
| 8 | AC_DEFUN([gl_MALLOCA], | ||
| 9 | [ | ||
| 10 | dnl Use the autoconf tests for alloca(), but not the AC_SUBSTed variables | ||
| 11 | dnl @ALLOCA@ and @LTALLOCA@. | ||
| 12 | dnl gl_FUNC_ALLOCA dnl Already brought in by the module dependencies. | ||
| 13 | AC_REQUIRE([gl_EEMALLOC]) | ||
| 14 | AC_REQUIRE([AC_TYPE_LONG_LONG_INT]) | ||
| 15 | ]) | ||
diff --git a/m4/pathmax.m4 b/m4/pathmax.m4 new file mode 100644 index 00000000000..0770aca3aac --- /dev/null +++ b/m4/pathmax.m4 | |||
| @@ -0,0 +1,42 @@ | |||
| 1 | # pathmax.m4 serial 11 | ||
| 2 | dnl Copyright (C) 2002-2003, 2005-2006, 2009-2019 Free Software Foundation, | ||
| 3 | dnl Inc. | ||
| 4 | dnl This file is free software; the Free Software Foundation | ||
| 5 | dnl gives unlimited permission to copy and/or distribute it, | ||
| 6 | dnl with or without modifications, as long as this notice is preserved. | ||
| 7 | |||
| 8 | AC_DEFUN([gl_PATHMAX], | ||
| 9 | [ | ||
| 10 | dnl Prerequisites of lib/pathmax.h. | ||
| 11 | AC_CHECK_HEADERS_ONCE([sys/param.h]) | ||
| 12 | ]) | ||
| 13 | |||
| 14 | # Expands to a piece of C program that defines PATH_MAX in the same way as | ||
| 15 | # "pathmax.h" will do. | ||
| 16 | AC_DEFUN([gl_PATHMAX_SNIPPET], [[ | ||
| 17 | /* Arrange to define PATH_MAX, like "pathmax.h" does. */ | ||
| 18 | #if HAVE_UNISTD_H | ||
| 19 | # include <unistd.h> | ||
| 20 | #endif | ||
| 21 | #include <limits.h> | ||
| 22 | #if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN | ||
| 23 | # include <sys/param.h> | ||
| 24 | #endif | ||
| 25 | #if !defined PATH_MAX && defined MAXPATHLEN | ||
| 26 | # define PATH_MAX MAXPATHLEN | ||
| 27 | #endif | ||
| 28 | #ifdef __hpux | ||
| 29 | # undef PATH_MAX | ||
| 30 | # define PATH_MAX 1024 | ||
| 31 | #endif | ||
| 32 | #if defined _WIN32 && ! defined __CYGWIN__ | ||
| 33 | # undef PATH_MAX | ||
| 34 | # define PATH_MAX 260 | ||
| 35 | #endif | ||
| 36 | ]]) | ||
| 37 | |||
| 38 | # Prerequisites of gl_PATHMAX_SNIPPET. | ||
| 39 | AC_DEFUN([gl_PATHMAX_SNIPPET_PREREQ], | ||
| 40 | [ | ||
| 41 | AC_CHECK_HEADERS_ONCE([unistd.h sys/param.h]) | ||
| 42 | ]) | ||