From a1a89d10e5da77e4ac71fcf1cc645c1822fedd97 Mon Sep 17 00:00:00 2001 From: Nikias Bassen Date: Wed, 24 Nov 2021 14:37:01 +0100 Subject: restore: Use new reverse proxy implementation from latest libimobiledevice with fallback to the legacy code with a compile time warning. The legacy code will be removed in the future once a newer libimobiledevice has been officially released. --- configure.ac | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index e748924..ed81dde 100644 --- a/configure.ac +++ b/configure.ac @@ -113,11 +113,23 @@ AC_CACHE_CHECK(for enum idevice_connection_type, ac_cv_enum_idevice_connection_t ]], [[ enum idevice_connection_type conn_type = CONNECTION_USBMUXD; ]])],[ac_cv_enum_idevice_connection_type=yes],[ac_cv_enum_idevice_connection_type=no])) - -if (test "$ac_cv_enum_idevice_connection_type" = "yes"); then +if test "$ac_cv_enum_idevice_connection_type" = "yes"; then AC_DEFINE(HAVE_ENUM_IDEVICE_CONNECTION_TYPE, 1, [Define if enum idevice_connection_type is available]) fi +# check if libimobiledevice has reverse proxy support +AC_CACHE_CHECK(for reverse proxy support in libimobiledevice, ac_cv_reverse_proxy, + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + #include + #include + ]], [[ + reverse_proxy_client_t rp = NULL; + reverse_proxy_client_create_with_port(NULL, &rp, REVERSE_PROXY_DEFAULT_PORT); + ]])],[ac_cv_reverse_proxy=yes],[ac_cv_reverse_proxy=no])) +if test "$ac_cv_reverse_proxy" = "yes"; then + AC_DEFINE(HAVE_REVERSE_PROXY, 1, [Define if libimobiledevice has a reverse proxy implementation]) +fi + CFLAGS="$CACHED_CFLAGS" AC_ARG_WITH([openssl], -- cgit v1.1-32-gdbae