X-Git-Url: http://sjero.net/git/?p=wget;a=blobdiff_plain;f=vms%2Fvms.h;fp=vms%2Fvms.h;h=05f995bbd8baeee81ffdedd5975c03936a83609e;hp=0000000000000000000000000000000000000000;hb=714ccdcd844314cc3902fa4fd1b48757d9db9296;hpb=0a0d73a03f87ca6393d49869604922ee884c6021 diff --git a/vms/vms.h b/vms/vms.h new file mode 100644 index 00000000..05f995bb --- /dev/null +++ b/vms/vms.h @@ -0,0 +1,107 @@ +/* + * Various VMS-specific items. + * + * Includes: + * + * Emergency replacement for for VMS CRTL before V7.3. + * + * Emergency replacement for for VMS CRTL before V7.0. + * + * Emergency substitution of stat() for lstat() for VAX and VMS CRTL + * before V7.3-1. + * + * Prototypes for VMS-specific functions: + * acc_cb() + * utime() (CRTL < V7.3) + * ods_conform() + * set_ods5_dest() + * vms_arch() + * vms_vers() + * + * Global storage: + * ods5_dest + */ + +#ifndef __VMS_H_INCLUDED +#define __VMS_H_INCLUDED + +/* Emergency replacement for for VMS before V7.3. */ + +#if __CRTL_VER < 70300000 + +#include + +/* The "utimbuf" structure is used by "utime()". */ +struct utimbuf { + time_t actime; /* access time */ + time_t modtime; /* modification time */ +}; + +/* Function prototypes for utime(), */ + +int utime( const char *path, const struct utimbuf *times); + +#else /* __CRTL_VER < 70300000 */ + +#include + +#endif /* __CRTL_VER < 70300000 */ + + +/* Emergency substitution of stat() for lstat() for VAX and VMS CRTL + before V7.3-1. +*/ +#if defined(__VAX) || __CRTL_VER < 70301000 + +#define lstat( __p1, __p2) stat( __p1, __p2) + +#endif /* defined(__VAX) || __CRTL_VER < 70301000 */ + + +/* Global storage. */ + +/* VMS destination file system type. < 0: unset/unknown + = 0: ODS2 + > 0: ODS5 +*/ + +extern int ods5_dest; + + +/* Function prototypes. */ + +extern int acc_cb(); + +char *ods_conform( char *path); + +int set_ods5_dest( char *path); + +char *vms_arch( void); + +char *vms_vers( void); + +/* Emergency replacement for (for VMS CRTL before V7.0). */ + +/* Declare "passwd" structure, if needed. */ + +#ifndef HAVE_PWD_H + +struct passwd { + char *pw_name; + char *pw_passwd; + int pw_uid; + int pw_gid; + short pw_salt; + int pw_encrypt; + char *pw_age; + char *pw_comment; + char *pw_gecos; + char *pw_dir; + char *pw_shell; +}; + +struct passwd *getpwuid(); + +#endif /* HAVE_PWD_H */ + +#endif /* __VMS_H_INCLUDED */