summaryrefslogtreecommitdiffstats
path: root/contrib/libs/curl/lib
diff options
context:
space:
mode:
authorgazimovbulat <[email protected]>2025-05-13 00:09:51 +0300
committergazimovbulat <[email protected]>2025-05-13 00:22:36 +0300
commit2c2bd72c4484a5704db08733e5e22b58eee89944 (patch)
tree83070d4d8e3ee75c05b3a61b990c72a127411f8d /contrib/libs/curl/lib
parent31c8ff060ca43cd2220f90cbcc619ff5f8c6f37e (diff)
feat contrib curl: include libssh2 for sftp
commit_hash:6721cdd5ed873cd6f6243dcb846cacad6acb2155
Diffstat (limited to 'contrib/libs/curl/lib')
-rw-r--r--contrib/libs/curl/lib/curl_config-linux.h4
-rw-r--r--contrib/libs/curl/lib/curl_config-osx.h2
-rw-r--r--contrib/libs/curl/lib/curl_config-win.h2
-rw-r--r--contrib/libs/curl/lib/curl_path.c2
-rw-r--r--contrib/libs/curl/lib/curl_path.h49
-rw-r--r--contrib/libs/curl/lib/urldata.h4
-rw-r--r--contrib/libs/curl/lib/vssh/libssh.c2
-rw-r--r--contrib/libs/curl/lib/vssh/libssh2.c6
-rw-r--r--contrib/libs/curl/lib/vssh/ssh.h4
-rw-r--r--contrib/libs/curl/lib/vssh/wolfssh.c2
10 files changed, 63 insertions, 14 deletions
diff --git a/contrib/libs/curl/lib/curl_config-linux.h b/contrib/libs/curl/lib/curl_config-linux.h
index 548dd9135da..abfc7d8b3fb 100644
--- a/contrib/libs/curl/lib/curl_config-linux.h
+++ b/contrib/libs/curl/lib/curl_config-linux.h
@@ -413,7 +413,7 @@
/* #undef HAVE_LIBSSH */
/* Define to 1 if you have the `ssh2' library (-lssh2). */
-/* #undef HAVE_LIBSSH2 */
+#define HAVE_LIBSSH2 1
/* Define to 1 if you have the `ssl' library (-lssl). */
#define HAVE_LIBSSL 1
@@ -871,7 +871,7 @@
/* #undef USE_LIBSSH */
/* if libSSH2 is in use */
-/* #undef USE_LIBSSH2 */
+#define USE_LIBSSH2 1
/* If you want to build curl with the built-in manual */
/* #undef USE_MANUAL */
diff --git a/contrib/libs/curl/lib/curl_config-osx.h b/contrib/libs/curl/lib/curl_config-osx.h
index 599c2a40032..e3296ce0e8c 100644
--- a/contrib/libs/curl/lib/curl_config-osx.h
+++ b/contrib/libs/curl/lib/curl_config-osx.h
@@ -972,7 +972,7 @@
/* #undef USE_LIBSSH */
/* if libSSH2 is in use */
-/* #undef USE_LIBSSH2 */
+#define USE_LIBSSH2 1
/* If you want to build curl with the built-in manual */
/* #undef USE_MANUAL */
diff --git a/contrib/libs/curl/lib/curl_config-win.h b/contrib/libs/curl/lib/curl_config-win.h
index c680859da97..3ebcfde9b1a 100644
--- a/contrib/libs/curl/lib/curl_config-win.h
+++ b/contrib/libs/curl/lib/curl_config-win.h
@@ -985,7 +985,7 @@
/* #undef USE_DARWINSSL */
/* if libSSH2 is in use */
-/* #undef USE_LIBSSH2 */
+#define USE_LIBSSH2 1
/* If you want to build curl with the built-in manual */
/* #undef USE_MANUAL */
diff --git a/contrib/libs/curl/lib/curl_path.c b/contrib/libs/curl/lib/curl_path.c
index 2e5e3e7ba87..856423db997 100644
--- a/contrib/libs/curl/lib/curl_path.c
+++ b/contrib/libs/curl/lib/curl_path.c
@@ -28,7 +28,7 @@
#include <curl/curl.h>
#include "curl_memory.h"
-#error #include "curl_path.h"
+#include "curl_path.h"
#include "escape.h"
#include "memdebug.h"
diff --git a/contrib/libs/curl/lib/curl_path.h b/contrib/libs/curl/lib/curl_path.h
new file mode 100644
index 00000000000..cbe51c22176
--- /dev/null
+++ b/contrib/libs/curl/lib/curl_path.h
@@ -0,0 +1,49 @@
+#ifndef HEADER_CURL_PATH_H
+#define HEADER_CURL_PATH_H
+/***************************************************************************
+ * _ _ ____ _
+ * Project ___| | | | _ \| |
+ * / __| | | | |_) | |
+ * | (__| |_| | _ <| |___
+ * \___|\___/|_| \_\_____|
+ *
+ * Copyright (C) Daniel Stenberg, <[email protected]>, et al.
+ *
+ * This software is licensed as described in the file COPYING, which
+ * you should have received as part of this distribution. The terms
+ * are also available at https://curl.se/docs/copyright.html.
+ *
+ * You may opt to use, copy, modify, merge, publish, distribute and/or sell
+ * copies of the Software, and permit persons to whom the Software is
+ * furnished to do so, under the terms of the COPYING file.
+ *
+ * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
+ * KIND, either express or implied.
+ *
+ * SPDX-License-Identifier: curl
+ *
+ ***************************************************************************/
+
+#include "curl_setup.h"
+#include <curl/curl.h>
+#include "urldata.h"
+
+#ifdef _WIN32
+# undef PATH_MAX
+# define PATH_MAX MAX_PATH
+# ifndef R_OK
+# define R_OK 4
+# endif
+#endif
+
+#ifndef PATH_MAX
+#define PATH_MAX 1024 /* just an extra precaution since there are systems that
+ have their definition hidden well */
+#endif
+
+CURLcode Curl_getworkingpath(struct Curl_easy *data,
+ char *homedir,
+ char **path);
+
+CURLcode Curl_get_pathname(const char **cpp, char **path, char *homedir);
+#endif /* HEADER_CURL_PATH_H */
diff --git a/contrib/libs/curl/lib/urldata.h b/contrib/libs/curl/lib/urldata.h
index db0e73719ee..6007a719c7d 100644
--- a/contrib/libs/curl/lib/urldata.h
+++ b/contrib/libs/curl/lib/urldata.h
@@ -194,8 +194,8 @@ typedef CURLcode (*Curl_datastream)(struct Curl_easy *data,
#endif
#ifdef USE_LIBSSH2
-#error #include <libssh2.h>
-#error #include <libssh2_sftp.h>
+#include <libssh2.h>
+#include <libssh2_sftp.h>
#endif /* USE_LIBSSH2 */
#define READBUFFER_SIZE CURL_MAX_WRITE_SIZE
diff --git a/contrib/libs/curl/lib/vssh/libssh.c b/contrib/libs/curl/lib/vssh/libssh.c
index 88bfd6a4098..d46360e0f64 100644
--- a/contrib/libs/curl/lib/vssh/libssh.c
+++ b/contrib/libs/curl/lib/vssh/libssh.c
@@ -72,7 +72,7 @@
#include "multiif.h"
#include "select.h"
#include "warnless.h"
-#error #include "curl_path.h"
+#include "curl_path.h"
#ifdef HAVE_SYS_STAT_H
#include <sys/stat.h>
diff --git a/contrib/libs/curl/lib/vssh/libssh2.c b/contrib/libs/curl/lib/vssh/libssh2.c
index 6560dba2ed2..11f5f4fd5d7 100644
--- a/contrib/libs/curl/lib/vssh/libssh2.c
+++ b/contrib/libs/curl/lib/vssh/libssh2.c
@@ -30,8 +30,8 @@
#include <limits.h>
-#error #include <libssh2.h>
-#error #include <libssh2_sftp.h>
+#include <libssh2.h>
+#include <libssh2_sftp.h>
#ifdef HAVE_FCNTL_H
#include <fcntl.h>
@@ -75,7 +75,7 @@
#include "multiif.h"
#include "select.h"
#include "warnless.h"
-#error #include "curl_path.h"
+#include "curl_path.h"
#include <curl_base64.h> /* for base64 encoding/decoding */
#include <curl_sha256.h>
diff --git a/contrib/libs/curl/lib/vssh/ssh.h b/contrib/libs/curl/lib/vssh/ssh.h
index ff1d0a1efee..d34a1ed2397 100644
--- a/contrib/libs/curl/lib/vssh/ssh.h
+++ b/contrib/libs/curl/lib/vssh/ssh.h
@@ -27,8 +27,8 @@
#include "curl_setup.h"
#if defined(USE_LIBSSH2)
-#error #include <libssh2.h>
-#error #include <libssh2_sftp.h>
+#include <libssh2.h>
+#include <libssh2_sftp.h>
#elif defined(USE_LIBSSH)
#error #include <libssh/libssh.h>
#error #include <libssh/sftp.h>
diff --git a/contrib/libs/curl/lib/vssh/wolfssh.c b/contrib/libs/curl/lib/vssh/wolfssh.c
index e32e98cc755..a11a73183a3 100644
--- a/contrib/libs/curl/lib/vssh/wolfssh.c
+++ b/contrib/libs/curl/lib/vssh/wolfssh.c
@@ -35,7 +35,7 @@
#include "connect.h"
#include "sendf.h"
#include "progress.h"
-#error #include "curl_path.h"
+#include "curl_path.h"
#include "strtoofft.h"
#include "transfer.h"
#include "speedcheck.h"