diff options
author | Thomas Munro | 2022-08-04 21:22:56 +0000 |
---|---|---|
committer | Thomas Munro | 2022-08-04 21:22:56 +0000 |
commit | 2b1f580ee2ca373d0451d89a40fc8f0a5f55ede9 (patch) | |
tree | f752391d9be7ab5a8229c1f3c4e0e5f413e5d5ec /configure | |
parent | adeef67834cc3db14c36430c1421cf4ed8a809d3 (diff) |
Remove configure probes for symlink/readlink, and dead code.
symlink() and readlink() are in SUSv2 and all targeted Unix systems have
them. We have partial emulation on Windows. Code that raised runtime
errors on systems without it has been dead for years, so we can remove
that and also references to such systems in the documentation.
Define HAVE_READLINK and HAVE_SYMLINK macros on Unix. Our Windows
replacement functions based on junction points can't be used for
relative paths or for non-directories, so the macros can be used to
check for full symlink support. The places that deal with tablespaces
can just use symlink functions without checking the macros. (If they
did check the macros, they'd need to provide an #else branch with a
runtime or compile time error, and it'd be dead code.)
Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us>
Reviewed-by: Andres Freund <andres@anarazel.de>
Discussion: https://postgr.es/m/CA+hUKGJ3LHeP9w5Fgzdr4G8AnEtJ=z=p6hGDEm4qYGEUX5B6fQ@mail.gmail.com
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/configure b/configure index 232f19a0cd2..1f852078e75 100755 --- a/configure +++ b/configure @@ -16039,7 +16039,7 @@ fi LIBS_including_readline="$LIBS" LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'` -for ac_func in backtrace_symbols clock_gettime copyfile fdatasync getifaddrs getpeerucred inet_pton kqueue mbstowcs_l memset_s poll posix_fallocate ppoll pthread_is_threaded_np readlink readv setproctitle setproctitle_fast strchrnul strsignal symlink syncfs sync_file_range uselocale wcstombs_l writev +for ac_func in backtrace_symbols clock_gettime copyfile fdatasync getifaddrs getpeerucred inet_pton kqueue mbstowcs_l memset_s poll posix_fallocate ppoll pthread_is_threaded_np readv setproctitle setproctitle_fast strchrnul strsignal syncfs sync_file_range uselocale wcstombs_l writev do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" @@ -17083,9 +17083,6 @@ esac ;; esac - -$as_echo "#define HAVE_SYMLINK 1" >>confdefs.h - ac_fn_c_check_type "$LINENO" "MINIDUMP_TYPE" "ac_cv_type_MINIDUMP_TYPE" " #define WIN32_LEAN_AND_MEAN #include <windows.h> |