]> granicus.if.org Git - curl/commitdiff
VMS specific preprocessor symbol checking adjustments
authorYang Tse <yangsita@gmail.com>
Wed, 30 Dec 2009 17:59:56 +0000 (17:59 +0000)
committerYang Tse <yangsita@gmail.com>
Wed, 30 Dec 2009 17:59:56 +0000 (17:59 +0000)
27 files changed:
ares/setup_once.h
include/curl/curlbuild.h.dist
lib/connect.c
lib/curl_addrinfo.c
lib/curl_addrinfo.h
lib/ftp.c
lib/getenv.c
lib/hostares.c
lib/hostasyn.c
lib/hostip.c
lib/hostip4.c
lib/hostip6.c
lib/hostsyn.c
lib/hostthre.c
lib/if2ip.c
lib/imap.c
lib/netrc.c
lib/nonblock.c
lib/pop3.c
lib/setup.h
lib/setup_once.h
lib/smtp.c
lib/ssh.c
lib/url.c
src/getpass.c
src/homedir.c
src/main.c

index f7d45a232606b92425e082bae68260b9ce8122fa..95722b2b733873a95d5b0a1fa7c601cada3307a6 100644 (file)
@@ -415,7 +415,7 @@ typedef int sig_atomic_t;
  *  Actually use __32_getpwuid() on 64-bit VMS builds for getpwuid()
  */
 
-#if defined(VMS) && \
+#if defined(__VMS) && \
     defined(__INITIAL_POINTER_SIZE) && (__INITIAL_POINTER_SIZE == 64)
 #define getpwuid __32_getpwuid
 #endif
@@ -425,7 +425,7 @@ typedef int sig_atomic_t;
  * Macro argv_item_t hides platform details to code using it.
  */
 
-#ifdef VMS
+#ifdef __VMS
 #define argv_item_t  __char_ptr32
 #else
 #define argv_item_t  char *
index 9c3469ef4433e02c7bade67a9272b2ef73dcd3d2..0ee7135c50e9a14f131edb49e7023806576af325 100644 (file)
 #  define CURL_SIZEOF_CURL_SOCKLEN_T 4
 
 #elif defined(__VMS)
-#  if defined(__alpha) || defined(__ia64)
-#    define CURL_SIZEOF_LONG           4
-#    define CURL_TYPEOF_CURL_OFF_T     long long
-#    define CURL_FORMAT_CURL_OFF_T     "lld"
-#    define CURL_FORMAT_CURL_OFF_TU    "llu"
-#    define CURL_FORMAT_OFF_T          "%lld"
-#    define CURL_SIZEOF_CURL_OFF_T     8
-#    define CURL_SUFFIX_CURL_OFF_T     LL
-#    define CURL_SUFFIX_CURL_OFF_TU    ULL
-#  else
+#  if defined(__VAX)
 #    define CURL_SIZEOF_LONG           4
 #    define CURL_TYPEOF_CURL_OFF_T     long
 #    define CURL_FORMAT_CURL_OFF_T     "ld"
 #    define CURL_SIZEOF_CURL_OFF_T     4
 #    define CURL_SUFFIX_CURL_OFF_T     L
 #    define CURL_SUFFIX_CURL_OFF_TU    UL
+#  else
+#    define CURL_SIZEOF_LONG           4
+#    define CURL_TYPEOF_CURL_OFF_T     long long
+#    define CURL_FORMAT_CURL_OFF_T     "lld"
+#    define CURL_FORMAT_CURL_OFF_TU    "llu"
+#    define CURL_FORMAT_OFF_T          "%lld"
+#    define CURL_SIZEOF_CURL_OFF_T     8
+#    define CURL_SUFFIX_CURL_OFF_T     LL
+#    define CURL_SUFFIX_CURL_OFF_TU    ULL
 #  endif
 #  define CURL_TYPEOF_CURL_SOCKLEN_T unsigned int
 #  define CURL_SIZEOF_CURL_SOCKLEN_T 4
index affb7fec567f0a4306c0aa6d79a119edfbfdb1f3..ec3e43bd543005acebe19ad45ab4cf0bc9ff67d3 100644 (file)
@@ -64,7 +64,7 @@
 #undef in_addr_t
 #define in_addr_t unsigned long
 #endif
-#ifdef VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #endif
index 963335111c371577e9ea2f8e01ad1aa2162ee59e..a5d26165c8ae4281d15657fa9148d47a497029b1 100644 (file)
@@ -38,7 +38,7 @@
 #  include <arpa/inet.h>
 #endif
 
-#ifdef  VMS
+#ifdef __VMS
 #  include <in.h>
 #  include <inet.h>
 #  include <stdlib.h>
@@ -365,7 +365,7 @@ Curl_ip2addr(int af, const void *inaddr, const char *hostname, int port)
 {
   Curl_addrinfo *ai;
 
-#if defined(VMS) && \
+#if defined(__VMS) && \
     defined(__INITIAL_POINTER_SIZE) && (__INITIAL_POINTER_SIZE == 64)
 #pragma pointer_size save
 #pragma pointer_size short
@@ -418,7 +418,7 @@ Curl_ip2addr(int af, const void *inaddr, const char *hostname, int port)
   h->h_addr_list[0] = addrentry;
   h->h_addr_list[1] = NULL; /* terminate list of entries */
 
-#if defined(VMS) && \
+#if defined(__VMS) && \
     defined(__INITIAL_POINTER_SIZE) && (__INITIAL_POINTER_SIZE == 64)
 #pragma pointer_size restore
 #pragma message enable PTRMISMATCH
index 2fbb47a688237f08a5f7831594094839e3025ee7..a7235039f54b6084fa3fc7dd59b223165d644f95 100644 (file)
@@ -38,7 +38,7 @@
 #  include <arpa/inet.h>
 #endif
 
-#ifdef  VMS
+#ifdef __VMS
 #  include <in.h>
 #  include <inet.h>
 #  include <stdlib.h>
index 60abc9cc0a3a6ceb2c679f0684534ff59876c477..c5be2361f749e816f26c0ac944e1eed31716214b 100644 (file)
--- a/lib/ftp.c
+++ b/lib/ftp.c
@@ -49,7 +49,7 @@
 #ifdef HAVE_NETDB_H
 #include <netdb.h>
 #endif
-#ifdef  VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #endif
index 73fece24df4d428ea433914f3e50d7432666f238..56c2cb7711cef7e71da57396b2fc7f30ac163dc1 100644 (file)
@@ -27,7 +27,7 @@
 #include <stdlib.h>
 #include <string.h>
 
-#ifdef VMS
+#ifdef __VMS
 #include <unixlib.h>
 #endif
 
@@ -51,7 +51,7 @@ char *GetEnv(const char *variable)
   return (env[0] != '\0')?strdup(env):NULL;
 #else
   char *env = getenv(variable);
-#ifdef VMS
+#ifdef __VMS
   if(env && strcmp("HOME",variable) == 0)
     env = decc_translate_vms(env);
 #endif
index 1412f13a6a80415c1e072438a5eb2864ecf96047..8c1cb14fe250ae985ecb6b9fa7780b2d1aa7a445 100644 (file)
@@ -46,7 +46,7 @@
 #ifdef HAVE_UNISTD_H
 #include <unistd.h>     /* for the close() proto */
 #endif
-#ifdef  VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #include <stdlib.h>
index 8659e2fb2bf9421cd41046ab3a94318be0a850c1..715b0da4bebd93f713fb8ca35891dcdf35bdea6f 100644 (file)
@@ -43,7 +43,7 @@
 #ifdef HAVE_UNISTD_H
 #include <unistd.h>     /* for the close() proto */
 #endif
-#ifdef  VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #include <stdlib.h>
index 26ed7b6676820a3b15529999d052d368f481467c..fc17de6730619632737137790295e20160745930 100644 (file)
@@ -43,7 +43,7 @@
 #ifdef HAVE_UNISTD_H
 #include <unistd.h>     /* for the close() proto */
 #endif
-#ifdef  VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #include <stdlib.h>
index c10df461cd6b5d32b3fcc8a6b3932878049fe391..b4f6bd9d3cc07c33f79d7a4769350a813395f9c1 100644 (file)
@@ -44,7 +44,7 @@
 #ifdef HAVE_UNISTD_H
 #include <unistd.h>     /* for the close() proto */
 #endif
-#ifdef  VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #include <stdlib.h>
index 972f84778ff01e931ddd86b44ba5caeebf7e6c05..a5bc55ce043d346f78e81e3fe543ddde9bcc18ca 100644 (file)
@@ -43,7 +43,7 @@
 #ifdef HAVE_UNISTD_H
 #include <unistd.h>     /* for the close() proto */
 #endif
-#ifdef  VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #include <stdlib.h>
index 027d5fa1af32f626828fcbc36b5d0a7aed47c239..65d72256b27e6fb7deaac2b9ca34efa73e1c4d39 100644 (file)
@@ -43,7 +43,7 @@
 #ifdef HAVE_UNISTD_H
 #include <unistd.h>     /* for the close() proto */
 #endif
-#ifdef  VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #include <stdlib.h>
index 2ff9c4a07ed45881f071de9584d6456ab4e9fe54..e41653b27d35c53b44402960b3a380c7cc9683da 100644 (file)
@@ -44,7 +44,7 @@
 #ifdef HAVE_UNISTD_H
 #include <unistd.h>     /* for the close() proto */
 #endif
-#ifdef  VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #include <stdlib.h>
index f0159457c97ebbd24647e0e7240e692646495e0e..b8ed4c81cd215331d5b7840d49e6f3099bcdd3a3 100644 (file)
@@ -53,7 +53,7 @@
 #ifdef HAVE_STROPTS_H
 #  include <stropts.h>
 #endif
-#ifdef VMS
+#ifdef __VMS
 #  include <inet.h>
 #endif
 
index 50201e151bec60afee685a8963288956e2ad3b40..fab6c4dde44bafdff040f4f9a815b87741ddaa00 100644 (file)
@@ -52,7 +52,7 @@
 #ifdef HAVE_NETDB_H
 #include <netdb.h>
 #endif
-#ifdef  VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #endif
index a543c34e24ed5a861e8e88891835104be44cc3cb..a5dc8f408473e8a4386effc73a16e7b9d411ccf5 100644 (file)
@@ -33,7 +33,7 @@
 #ifdef HAVE_PWD_H
 #include <pwd.h>
 #endif
-#ifdef VMS
+#ifdef __VMS
 #include <unixlib.h>
 #endif
 
@@ -117,7 +117,7 @@ int Curl_parsenetrc(const char *host,
       struct passwd *pw;
       pw= getpwuid(geteuid());
       if(pw) {
-#ifdef  VMS
+#ifdef __VMS
         home = decc_translate_vms(pw->pw_dir);
 #else
         home = pw->pw_dir;
index d5a32a9e2248ff4a75f6c291646adb5fe12d5e41..c8f36e46ad647a64ca3e1eeab68432cd01b4afec 100644 (file)
@@ -42,7 +42,7 @@
 #if (defined(HAVE_IOCTL_FIONBIO) && defined(NETWARE))
 #include <sys/filio.h>
 #endif
-#ifdef VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #endif
index 43549f791f95370edfdc63b87e130518b60e7c7b..24354504ffbab1629b7991200bba865e91bce063 100644 (file)
@@ -53,7 +53,7 @@
 #ifdef HAVE_NETDB_H
 #include <netdb.h>
 #endif
-#ifdef  VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #endif
index 49d14ed0942168a40c2e39fe8e5413e457e64a27..8620f83b9c77850df3940bd088af43a92fadf916 100644 (file)
  */
 
 #ifndef SIZEOF_OFF_T
-#  if defined(__VMS) && (defined(__alpha) || defined(__ia64))
+#  if defined(__VMS) && !defined(__VAX)
 #    if defined(_LARGEFILE)
 #      define SIZEOF_OFF_T 8
 #    endif
index 9ad69e58d1023d1370cb61c9a170f7b476fa8330..5c49165f0290804400ebcb5bd8d41e01c6869c4f 100644 (file)
@@ -422,7 +422,7 @@ typedef int sig_atomic_t;
  *  Actually use __32_getpwuid() on 64-bit VMS builds for getpwuid()
  */
 
-#if defined(VMS) && \
+#if defined(__VMS) && \
     defined(__INITIAL_POINTER_SIZE) && (__INITIAL_POINTER_SIZE == 64)
 #define getpwuid __32_getpwuid
 #endif
@@ -432,7 +432,7 @@ typedef int sig_atomic_t;
  * Macro argv_item_t hides platform details to code using it.
  */
 
-#ifdef VMS
+#ifdef __VMS
 #define argv_item_t  __char_ptr32
 #else
 #define argv_item_t  char *
index 44e405ed5751cae0b2d81352b58ed2aa6fae35b8..1bd869eb0cf84c969daa3da8d9dd39c6aadb0cb8 100644 (file)
@@ -51,7 +51,7 @@
 #ifdef HAVE_NETDB_H
 #include <netdb.h>
 #endif
-#ifdef  VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #endif
index 5022a2b43bcfafd2a2e872788aad8d318b426dc6..a93e440bcc78ee7190659b7e727bc5456e99320e 100644 (file)
--- a/lib/ssh.c
+++ b/lib/ssh.c
@@ -66,7 +66,7 @@
 #ifdef HAVE_NETDB_H
 #include <netdb.h>
 #endif
-#ifdef  VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #endif
index ec2c2bf1bd9a9b3e3e294aab5cd8bc0fc1d945a6..05055acbacc7276d56c02ae54465da72be0dfbc8 100644 (file)
--- a/lib/url.c
+++ b/lib/url.c
@@ -65,7 +65,7 @@
 #include <sys/param.h>
 #endif
 
-#ifdef VMS
+#ifdef __VMS
 #include <in.h>
 #include <inet.h>
 #endif
index 8d20eb48caf045a6819a86ed109fd62245187bd3..a46d8e30de47d0292a67294f30246be36f3d2602 100644 (file)
@@ -5,7 +5,7 @@
  *                            | (__| |_| |  _ <| |___
  *                             \___|\___/|_| \_\_____|
  *
- * Copyright (C) 1998 - 2008, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2009, 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
@@ -54,7 +54,7 @@
 #include "memdebug.h"
 #endif
 
-#ifdef VMS
+#ifdef __VMS
 /* VMS implementation */
 #include descrip
 #include starlet
@@ -93,7 +93,7 @@ char *getpass_r(const char *prompt, char *buffer, size_t buflen)
   return buffer; /* we always return success */
 }
 #define DONE
-#endif /* VMS */
+#endif /* __VMS */
 
 
 #ifdef WIN32
index e8392f192748e6dca3b12c051d0a4544470580bc..e2fbc7a3ac6a2756db03888807ce0ab8cc404bc5 100644 (file)
@@ -5,7 +5,7 @@
  *                            | (__| |_| |  _ <| |___
  *                             \___|\___/|_| \_\_____|
  *
- * Copyright (C) 1998 - 2007, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2009, 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
@@ -33,7 +33,7 @@
 #ifdef HAVE_UNISTD_H
 #include <unistd.h>
 #endif
-#ifdef VMS
+#ifdef __VMS
 #include <unixlib.h>
 #endif
 
@@ -68,7 +68,7 @@ char *GetEnv(const char *variable, char do_expand)
   }
 #else
   (void)do_expand;
-#ifdef  VMS
+#ifdef __VMS
   env = getenv(variable);
   if (env && strcmp("HOME",variable) == 0) {
         env = decc_translate_vms(env);
@@ -99,7 +99,7 @@ char *homedir(void)
    struct passwd *pw = getpwuid(geteuid());
 
    if (pw) {
-#ifdef VMS
+#ifdef __VMS
      home = decc_translate_vms(pw->pw_dir);
 #else
      home = pw->pw_dir;
index f7c2eb43e11e67af5d517e45ea0309d6bbf992e7..a4b858b55c6274a36086299b423ffabe53866b0f 100644 (file)
@@ -277,7 +277,7 @@ typedef enum {
  */
 
 #ifndef SIZEOF_OFF_T
-#  if defined(__VMS) && (defined(__alpha) || defined(__ia64))
+#  if defined(__VMS) && !defined(__VAX)
 #    if defined(_LARGEFILE)
 #      define SIZEOF_OFF_T 8
 #    endif