aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Monnerat <Patrick.Monnerat@datasphere.ch>2010-02-11 18:49:06 +0000
committerPatrick Monnerat <Patrick.Monnerat@datasphere.ch>2010-02-11 18:49:06 +0000
commit4258e943a15013952afd67354800ec6199af7050 (patch)
treef908f0b6dd16a3e25dcf1ceab295d11d24bf3067
parentc3b87d1b4f33e90f828043ca7a2c63018ca26457 (diff)
_ Make it compilable again on OS400.
_ Upgrade OS400 EBCDIC wrappers for new options. _ Upgrade ILE/RPG bindings to current state.
-rw-r--r--lib/config-os400.h23
-rw-r--r--packages/OS400/README.OS4004
-rw-r--r--packages/OS400/ccsidcurl.c8
-rw-r--r--packages/OS400/curl.inc.in68
-rw-r--r--packages/OS400/make-include.sh6
-rw-r--r--packages/OS400/make-lib.sh2
6 files changed, 86 insertions, 25 deletions
diff --git a/lib/config-os400.h b/lib/config-os400.h
index 7a303fdbb..ac75db2a2 100644
--- a/lib/config-os400.h
+++ b/lib/config-os400.h
@@ -24,14 +24,18 @@
/* 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
@@ -78,10 +82,6 @@
/* 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
diff --git a/packages/OS400/README.OS400 b/packages/OS400/README.OS400
index 58c75b7b1..e5410f32d 100644
--- a/packages/OS400/README.OS400
+++ b/packages/OS400/README.OS400
@@ -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.
diff --git a/packages/OS400/ccsidcurl.c b/packages/OS400/ccsidcurl.c
index 4d722d565..38fe2ba54 100644
--- a/packages/OS400/ccsidcurl.c
+++ b/packages/OS400/ccsidcurl.c
@@ -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);
diff --git a/packages/OS400/curl.inc.in b/packages/OS400/curl.inc.in
index 91b96be8d..697134bbb 100644
--- a/packages/OS400/curl.inc.in
+++ b/packages/OS400/curl.inc.in
@@ -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
@@ -408,6 +408,12 @@
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
@@ -556,6 +562,8 @@
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
@@ -601,6 +609,8 @@
d c 10022
d CURLOPT_HTTPHEADER...
d c 10023
+ d CURLOPT_RTSPHEADER...
+ d c 10023
d CURLOPT_HTTPPOST...
d c 10024
d CURLOPT_SSLCERT...
@@ -893,6 +903,24 @@
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
@@ -1030,6 +1058,14 @@
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'
@@ -1161,6 +1197,36 @@
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.
*
d CURL_Msg ds based(######ptr######)
diff --git a/packages/OS400/make-include.sh b/packages/OS400/make-include.sh
index e4bc31d81..2d34047bd 100644
--- a/packages/OS400/make-include.sh
+++ b/packages/OS400/make-include.sh
@@ -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}"
diff --git a/packages/OS400/make-lib.sh b/packages/OS400/make-lib.sh
index 1f02a62ff..876cc6ba4 100644
--- a/packages/OS400/make-lib.sh
+++ b/packages/OS400/make-lib.sh
@@ -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=