< prev index next >

src/java.base/unix/native/libjava/TimeZone_md.c

Print this page




  38 #if defined(__solaris__)
  39 #include <libscf.h>
  40 #endif
  41 
  42 #include "jvm.h"
  43 #include "TimeZone_md.h"
  44 
  45 #define SKIP_SPACE(p)   while (*p == ' ' || *p == '\t') p++;
  46 
  47 #define RESTARTABLE(_cmd, _result) do { \
  48   do { \
  49     _result = _cmd; \
  50   } while((_result == -1) && (errno == EINTR)); \
  51 } while(0)
  52 
  53 #if defined(_ALLBSD_SOURCE)
  54 #define dirent64 dirent
  55 #define readdir64 readdir
  56 #endif
  57 






  58 #if !defined(__solaris__) || defined(__sparcv9) || defined(amd64)
  59 #define fileopen        fopen
  60 #define filegets        fgets
  61 #define fileclose       fclose
  62 #endif
  63 
  64 #if defined(__linux__) || defined(_ALLBSD_SOURCE)
  65 static const char *ETC_TIMEZONE_FILE = "/etc/timezone";
  66 static const char *ZONEINFO_DIR = "/usr/share/zoneinfo";
  67 static const char *DEFAULT_ZONEINFO_FILE = "/etc/localtime";
  68 #else
  69 static const char *SYS_INIT_FILE = "/etc/default/init";
  70 static const char *ZONEINFO_DIR = "/usr/share/lib/zoneinfo";
  71 static const char *DEFAULT_ZONEINFO_FILE = "/usr/share/lib/zoneinfo/localtime";
  72 #endif /* defined(__linux__) || defined(_ALLBSD_SOURCE) */
  73 
  74 #if defined(_AIX)
  75 static const char *ETC_ENVIRONMENT_FILE = "/etc/environment";
  76 #endif
  77 




  38 #if defined(__solaris__)
  39 #include <libscf.h>
  40 #endif
  41 
  42 #include "jvm.h"
  43 #include "TimeZone_md.h"
  44 
  45 #define SKIP_SPACE(p)   while (*p == ' ' || *p == '\t') p++;
  46 
  47 #define RESTARTABLE(_cmd, _result) do { \
  48   do { \
  49     _result = _cmd; \
  50   } while((_result == -1) && (errno == EINTR)); \
  51 } while(0)
  52 
  53 #if defined(_ALLBSD_SOURCE)
  54 #define dirent64 dirent
  55 #define readdir64 readdir
  56 #endif
  57 
  58 #if defined(_AIX)
  59   #define DIR DIR64
  60   #define opendir opendir64
  61   #define closedir closedir64
  62 #endif
  63 
  64 #if !defined(__solaris__) || defined(__sparcv9) || defined(amd64)
  65 #define fileopen        fopen
  66 #define filegets        fgets
  67 #define fileclose       fclose
  68 #endif
  69 
  70 #if defined(__linux__) || defined(_ALLBSD_SOURCE)
  71 static const char *ETC_TIMEZONE_FILE = "/etc/timezone";
  72 static const char *ZONEINFO_DIR = "/usr/share/zoneinfo";
  73 static const char *DEFAULT_ZONEINFO_FILE = "/etc/localtime";
  74 #else
  75 static const char *SYS_INIT_FILE = "/etc/default/init";
  76 static const char *ZONEINFO_DIR = "/usr/share/lib/zoneinfo";
  77 static const char *DEFAULT_ZONEINFO_FILE = "/usr/share/lib/zoneinfo/localtime";
  78 #endif /* defined(__linux__) || defined(_ALLBSD_SOURCE) */
  79 
  80 #if defined(_AIX)
  81 static const char *ETC_ENVIRONMENT_FILE = "/etc/environment";
  82 #endif
  83 


< prev index next >