]> sjero.net Git - wget/blob - vms/vms.h
NEWS: cite --start-pos
[wget] / vms / vms.h
1 /*
2  *    Various VMS-specific items.
3  *
4  *    Includes:
5  *
6  *  Emergency replacement for <utime.h> for VMS CRTL before V7.3.
7  *
8  *  Emergency replacement for <pwd.h> for VMS CRTL before V7.0.
9  *
10  *  Emergency substitution of stat() for lstat() for VAX and VMS CRTL
11  *  before V7.3-1.
12  *
13  *  Prototypes for VMS-specific functions:
14  *     acc_cb()
15  *     utime() (CRTL < V7.3)
16  *     ods_conform()
17  *     set_ods5_dest()
18  *     vms_arch()
19  *     vms_basename()
20  *     vms_vers()
21  *
22  *  Global storage:
23  *     ods5_dest
24  */
25
26 #ifndef __VMS_H_INCLUDED
27 #define __VMS_H_INCLUDED
28
29 /* Emergency replacement for <utime.h> for VMS before V7.3. */
30
31 #if __CRTL_VER < 70300000
32
33 #include <types.h>
34
35 /* The "utimbuf" structure is used by "utime()". */
36 struct utimbuf {
37         time_t actime;          /* access time */
38         time_t modtime;         /* modification time */
39 };
40
41 /* Function prototypes for utime(), */
42
43 int utime( const char *path, const struct utimbuf *times);
44
45 #else /* __CRTL_VER < 70300000 */
46
47 #include <utime.h>
48
49 #endif /* __CRTL_VER < 70300000 */
50
51
52 /* Emergency substitution of stat() for lstat() for VAX and VMS CRTL
53    before V7.3-1.
54 */
55 #if defined(__VAX) || __CRTL_VER < 70301000
56
57 #define lstat( __p1, __p2) stat( __p1, __p2)
58
59 #endif /* defined(__VAX) || __CRTL_VER < 70301000 */
60
61
62 /* Global storage. */
63
64 /*    VMS destination file system type.  < 0: unset/unknown
65                                          = 0: ODS2
66                                          > 0: ODS5
67 */
68
69 extern int ods5_dest;
70
71
72 /* Function prototypes. */
73
74 extern int acc_cb();
75
76 char *ods_conform( char *path);
77
78 int set_ods5_dest( char *path);
79
80 char *vms_arch( void);
81
82 char *vms_basename( char *file_spec);
83
84 char *vms_vers( void);
85
86 /* Emergency replacement for <pwd.h> (for VMS CRTL before V7.0). */
87
88 /* Declare "passwd" structure, if needed. */
89
90 #ifndef HAVE_PWD_H
91
92 struct passwd {
93         char    *pw_name;
94         char    *pw_passwd;
95         int     pw_uid;
96         int     pw_gid;
97         short   pw_salt;
98         int     pw_encrypt;
99         char    *pw_age;
100         char    *pw_comment;
101         char    *pw_gecos;
102         char    *pw_dir;
103         char    *pw_shell;
104 };
105
106 struct passwd *getpwuid();
107
108 #endif /* HAVE_PWD_H */
109
110 #endif /* __VMS_H_INCLUDED */