Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitc9e1ad7

Browse files
committed
Detect presence of SSL_get_current_compression
Apparently we still build against OpenSSL so old that it doesn'thave this function, so add an autoconf check for it to make thebuildfarm happy. If the function doesn't exist, always returnthat compression is disabled, since presumably the actualcompression functionality is always missing.For now, hardcode the function as present on MSVC, since we shouldhopefully be well beyond those old versions on that platform.
1 parentf9ddcf7 commitc9e1ad7

File tree

5 files changed

+22
-0
lines changed

5 files changed

+22
-0
lines changed

‎configure

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8509,6 +8509,17 @@ else
85098509
as_fn_error$?"library 'ssl' is required for OpenSSL""$LINENO" 5
85108510
fi
85118511

8512+
forac_funcin SSL_get_current_compression
8513+
do:
8514+
ac_fn_c_check_func"$LINENO""SSL_get_current_compression""ac_cv_func_SSL_get_current_compression"
8515+
iftest"x$ac_cv_func_SSL_get_current_compression" = xyes;then:
8516+
cat>>confdefs.h<<_ACEOF
8517+
#define HAVE_SSL_GET_CURRENT_COMPRESSION 1
8518+
_ACEOF
8519+
8520+
fi
8521+
done
8522+
85128523
else
85138524
{$as_echo"$as_me:${as_lineno-$LINENO}: checking for library containing CRYPTO_new_ex_data">&5
85148525
$as_echo_n"checking for library containing CRYPTO_new_ex_data...">&6; }

‎configure.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -950,6 +950,7 @@ if test "$with_openssl" = yes ; then
950950
if test "$PORTNAME" != "win32"; then
951951
AC_CHECK_LIB(crypto, CRYPTO_new_ex_data, [], [AC_MSG_ERROR([library 'crypto' is required for OpenSSL])])
952952
AC_CHECK_LIB(ssl, SSL_library_init, [], [AC_MSG_ERROR([library 'ssl' is required for OpenSSL])])
953+
AC_CHECK_FUNCS([SSL_get_current_compression])
953954
else
954955
AC_SEARCH_LIBS(CRYPTO_new_ex_data, eay32 crypto, [], [AC_MSG_ERROR([library 'eay32' or 'crypto' is required for OpenSSL])])
955956
AC_SEARCH_LIBS(SSL_library_init, ssleay32 ssl, [], [AC_MSG_ERROR([library 'ssleay32' or 'ssl' is required for OpenSSL])])

‎src/include/pg_config.h.in

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -430,6 +430,9 @@
430430
/* Define to 1 if you have the `srandom' function. */
431431
#undef HAVE_SRANDOM
432432

433+
/* Define to 1 if you have the `SSL_get_current_compression' function. */
434+
#undef HAVE_SSL_GET_CURRENT_COMPRESSION
435+
433436
/* Define to 1 if you have the <stdint.h> header file. */
434437
#undef HAVE_STDINT_H
435438

‎src/include/pg_config.h.win32

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -337,6 +337,9 @@
337337
/* Define to 1 if you have the `srandom' function. */
338338
/* #undef HAVE_SRANDOM */
339339

340+
/* Define to 1 if you have the `SSL_get_current_compression' function. */
341+
#define HAVE_SSL_GET_CURRENT_COMPRESSION 1
342+
340343
/* Define to 1 if you have the <stdint.h> header file. */
341344
/* #undef HAVE_STDINT_H */
342345

‎src/include/port.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -420,6 +420,10 @@ extern void unsetenv(const char *name);
420420
externvoidsrandom(unsignedintseed);
421421
#endif
422422

423+
#ifndefHAVE_SSL_GET_CURRENT_COMPRESSION
424+
#defineSSL_get_current_compression(x) 0
425+
#endif
426+
423427
/* thread.h */
424428
externchar*pqStrerror(interrnum,char*strerrbuf,size_tbuflen);
425429

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp