]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
_ Make it compilable again on OS400.
authorPatrick Monnerat <Patrick.Monnerat@datasphere.ch>
Thu, 11 Feb 2010 18:49:06 +0000 (18:49 +0000)
committerPatrick Monnerat <Patrick.Monnerat@datasphere.ch>
Thu, 11 Feb 2010 18:49:06 +0000 (18:49 +0000)
_ Upgrade OS400 EBCDIC wrappers for new options.
_ Upgrade ILE/RPG bindings to current state.

lib/config-os400.h
packages/OS400/README.OS400
packages/OS400/ccsidcurl.c
packages/OS400/curl.inc.in
packages/OS400/make-include.sh
packages/OS400/make-lib.sh

index 7a303fdbb7ae086bd0ddb97ee871010ebc16968e..ac75db2a26ebd3f148770a08729d09778b7d51c1 100644 (file)
 /* Define if you have the gethostbyaddr_r() function with 8 arguments */
 #undef HAVE_GETHOSTBYADDR_R_8
 
-/* Define if you have the gethostbyname_r() function with 3 arguments */
-#define HAVE_GETHOSTBYNAME_R_3
-
-/* Define if you have the gethostbyname_r() function with 5 arguments */
+/* OS400 supports a 3-argument ASCII version of gethostbyaddr_r(), but its
+ *  prototype is incompatible with the "standard" one (1st argument is not
+ *  const). However, getaddrinfo() is supported (ASCII version defined as
+ *  a local wrapper in setup-os400.h) in a threadsafe way: we can then
+ *  configure getaddrinfo() as such and get rid of gethostbyname_r() without
+ *  loss of threadsafeness. */
+#undef HAVE_GETHOSTBYNAME_R
+#undef HAVE_GETHOSTBYNAME_R_3
 #undef HAVE_GETHOSTBYNAME_R_5
-
-/* Define if you have the gethostbyname_r() function with 6 arguments */
 #undef HAVE_GETHOSTBYNAME_R_6
+#define HAVE_GETADDRINFO
+#define HAVE_GETADDRINFO_THREADSAFE
 
 /* Define if you need the _REENTRANT define for some functions */
 #undef NEED_REENTRANT
 /* Define if you have the <fcntl.h> header file. */
 #define HAVE_FCNTL_H
 
-/* Define if getaddrinfo exists and works */
-/* OS400 has no ASCII version of this procedure: wrapped in setup-os400.h. */
-#define HAVE_GETADDRINFO
-
 /* Define if you have the `geteuid' function. */
 #define HAVE_GETEUID
 
@@ -91,9 +91,6 @@
 /* Define if you have the `gethostbyaddr_r' function. */
 #define HAVE_GETHOSTBYADDR_R
 
-/* Define if you have the `gethostbyname_r' function. */
-#define HAVE_GETHOSTBYNAME_R
-
 /* Define if you have the `gethostname' function. */
 #define HAVE_GETHOSTNAME
 
index 58c75b7b17ac3226716408405cee3ae730d08b5c..e5410f32d04ae3385503fc11f28b8c9c00239fbd 100644 (file)
@@ -106,9 +106,11 @@ options:
         CURLOPT_PROXYUSERNAME
         CURLOPT_PROXYPASSWORD
         CURLOPT_NOPROXY
+        CURLOPT_RTSP_SESSION_UID
+        CURLOPT_RTSP_STREAM_URI
+        CURLOPT_RTSP_TRANSPORT
         CURLOPT_SOCKS5_GSSAPI_SERVICE
        CURLOPT_MAIL_FROM
-       CURLOPT_MAIL_RCPT
   Else it is the same as for curl_easy_setopt().
   Note that CURLOPT_ERRORBUFFER is not in the list above, since it gives the
 address of an (empty) character buffer, not the address of a string.
index 4d722d565858fe69a13df618e6ae47d6ec0841a9..38fe2ba544c81430c6ca498f00fcfec3c1307828 100644 (file)
@@ -5,7 +5,7 @@
  *                            | (__| |_| |  _ <| |___
  *                             \___|\___/|_| \_\_____|
  *
- * Copyright (C) 1998 - 2009, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2010, Daniel Stenberg, <daniel@haxx.se>, et al.
  *
  * This software is licensed as described in the file COPYING, which
  * you should have received as part of this distribution. The terms
@@ -1030,7 +1030,7 @@ curl_easy_setopt_ccsid(CURL * curl, CURLoption tag, ...)
   if (testwarn) {
     testwarn = 0;
 
-    if ((int) STRING_LAST != (int) STRING_MAIL_RCPT + 1)
+    if ((int) STRING_LAST != (int) STRING_MAIL_FROM + 1)
       curl_mfprintf(stderr,
        "*** WARNING: curl_easy_setopt_ccsid() should be reworked ***\n");
     }
@@ -1080,11 +1080,13 @@ curl_easy_setopt_ccsid(CURL * curl, CURLoption tag, ...)
   case CURLOPT_PROXYUSERNAME:
   case CURLOPT_PROXYPASSWORD:
   case CURLOPT_NOPROXY:
+  case CURLOPT_RTSP_SESSION_ID:
+  case CURLOPT_RTSP_STREAM_URI:
+  case CURLOPT_RTSP_TRANSPORT:
   /* SSH2 not (yet) implemented on OS400. */
   /* case CURLOPT_SSH_KNOWNHOSTS: */
   case CURLOPT_SOCKS5_GSSAPI_SERVICE:
   case CURLOPT_MAIL_FROM:
-  case CURLOPT_MAIL_RCPT:
     s = va_arg(arg, char *);
     ccsid = va_arg(arg, unsigned int);
 
index 91b96be8dfa37992bb97216c5e77da7f14544315..697134bbb4839f23a522ff6d80a11c8297c6b5eb 100644 (file)
@@ -5,7 +5,7 @@
       *                            | (__| |_| |  _ <| |___
       *                             \___|\___/|_| \_\_____|
       *
-      * Copyright (C) 1998 - 2009, Daniel Stenberg, <daniel@haxx.se>, et al.
+      * Copyright (C) 1998 - 2010, Daniel Stenberg, <daniel@haxx.se>, et al.
       *
       * This software is licensed as described in the file COPYING, which
       * you should have received as part of this distribution. The terms
      d                 c                   82
      d  CURLE_SSL_ISSUER_ERROR...
      d                 c                   83
+     d  CURLE_FTP_PRET_FAILED...
+     d                 c                   84
+     d  CURLE_RTSP_CSEQ_ERROR...
+     d                 c                   85
+     d  CURLE_RTSP_SESSION_ERROR...
+     d                 c                   86
       *
      d curlioerr       s             10i 0 based(######ptr######)               Enum
      d  CURLIOE_OK     c                   0
      d                 c                   X'00010000'
      d  CURLPROTO_SMTPS...
      d                 c                   X'00020000'
+     d  CURLPROTO_RTSP...
+     d                 c                   X'00040000'
       *
      d CURLoption      s             10i 0 based(######ptr######)               Enum
      d  CURLOPT_FILE   c                   10001
      d                 c                   10022
      d  CURLOPT_HTTPHEADER...
      d                 c                   10023
+     d  CURLOPT_RTSPHEADER...
+     d                 c                   10023
      d  CURLOPT_HTTPPOST...
      d                 c                   10024
      d  CURLOPT_SSLCERT...
      d                 c                   10186
      d  CURLOPT_MAIL_RCPT...
      d                 c                   10187
+     d  CURLOPT_FTP_USE_PRET...
+     d                 c                   00188
+     d  CURLOPT_RTSP_REQUEST...
+     d                 c                   00189
+     d  CURLOPT_RTSP_SESSION_ID...
+     d                 c                   10190
+     d  CURLOPT_RTSP_STREAM_URI...
+     d                 c                   10191
+     d  CURLOPT_RTSP_TRANSPORT...
+     d                 c                   10192
+     d  CURLOPT_RTSP_CLIENT_CSEQ...
+     d                 c                   00193
+     d  CURLOPT_RTSP_SERVER_CSEQ...
+     d                 c                   00194
+     d  CURLOPT_INTERLEAVEDATA...
+     d                 c                   10195
+     d  CURLOPT_INTERLEAVEFUNCTION...
+     d                 c                   20196
       *
      d  CURLOPT_SERVER_RESPONSE_TIMEOUT...
      d                 c                   00112
      d                 c                   X'00400022'
      d  CURLINFO_CONDITION_UNMET...                                             CURLINFO_LONG + 35
      d                 c                   X'00200023'
+     d  CURLINFO_RTSP_SESSION_ID...                                             CURLINFO_STRING + 36
+     d                 c                   X'00100024'
+     d  CURLINFO_RTSP_CLIENT_CSEQ...                                            CURLINFO_LONG + 37
+     d                 c                   X'00200025'
+     d  CURLINFO_RTSP_SERVER_CSEQ...                                            CURLINFO_LONG + 38
+     d                 c                   X'00200026'
+     d  CURLINFO_RTSP_CSEQ_RECV...                                              CURLINFO_LONG + 39
+     d                 c                   X'00200027'
       *
      d  CURLINFO_HTTP_CODE...                                                   Old ...RESPONSE_CODE
      d                 c                   X'00200002'
      d                 c                   10005
      d  CURLMOPT_MAXCONNECTS...
      d                 c                   00006
+      *
+      *  Public API enums for RTSP requests.
+      *
+     d CURLRTSPREQ_NONE...
+     d                 c                   0
+     d CURL_RTSPREQ_OPTIONS...
+     d                 c                   1
+     d CURL_RTSPREQ_DESCRIBE...
+     d                 c                   2
+     d CURL_RTSPREQ_ANNOUNCE...
+     d                 c                   3
+     d CURL_RTSPREQ_SETUP...
+     d                 c                   4
+     d CURL_RTSPREQ_PLAY...
+     d                 c                   5
+     d CURL_RTSPREQ_PAUSE...
+     d                 c                   6
+     d CURL_RTSPREQ_TEARDOWN...
+     d                 c                   7
+     d CURL_RTSPREQ_GET_PARAMETER...
+     d                 c                   8
+     d CURL_RTSPREQ_SET_PARAMETER...
+     d                 c                   9
+     d CURL_RTSPREQ_RECORD...
+     d                 c                   10
+     d CURL_RTSPREQ_RECEIVE...
+     d                 c                   12
+     d CURL_RTSPREQ_LAST...
+     d                 c                   13
+
       *
       *  Renaming CURLMsg to CURL_Msg to avoid case-insensivity name clash.
       *
index e4bc31d814db5a2e9dfe68c11ac2ef33558fedb5..2d34047bd403350e3e1e325f1c3fbccd8bc8756f 100644 (file)
@@ -48,12 +48,6 @@ copy_hfile()
 
 #       Copy the header files.
 
-DEST="${SRCPF}/`db2_name curl/curl.h`.MBR"
-if action_needed "${DEST}" curl/curl.h
-then   copy_hfile "${DEST}" curl/curl.h -e                             \
-            's/^# *include  *[<"]curl\/curlbuild.h[">]/#include "curlbuild.h"/'
-fi
-
 for HFILE in curl/*.h ${SCRIPTDIR}/ccsidcurl.h
 do      DEST="${SRCPF}/`db2_name \"${HFILE}\"`.MBR"
         if action_needed "${DEST}" "${HFILE}"
index 1f02a62ffc03c2ab2e512a3877eb233d54ea28b5..876cc6ba49c94e4f9d1c80821ce9b5c7fe4a3755 100644 (file)
@@ -13,7 +13,7 @@ cd "${TOPDIR}/lib"
 
 echo '#pragma comment(user, "libcurl version '"${LIBCURL_VERSION}"'")' > os400.c
 echo '#pragma comment(date)' >> os400.c
-echo '#pragma comment(copyright, "Copyright (C) 1998-2009 Daniel Stenberg et al. OS/400 version by P. Monnerat")' >> os400.c
+echo '#pragma comment(copyright, "Copyright (C) 1998-2010 Daniel Stenberg et al. OS/400 version by P. Monnerat")' >> os400.c
 make_module     OS400           os400.c
 LINK=                           # No need to rebuild service program yet.
 MODULES=