Subversion Repositories Kolibri OS

Rev

Blame | Last modification | View Log | Download | RSS feed

  1. /*
  2.   Copyright (c) 1990-2000 Info-ZIP.  All rights reserved.
  3.  
  4.   See the accompanying file LICENSE, version 2000-Apr-09 or later
  5.   (the contents of which are also included in unzip.h) for terms of use.
  6.   If, for some reason, all these files are missing, the Info-ZIP license
  7.   also may be found at:  ftp://ftp.info-zip.org/pub/infozip/license.html
  8. */
  9. /*---------------------------------------------------------------------------
  10.  
  11.   aosvs.h
  12.  
  13.   AOS/VS-specific header file for use with Info-ZIP's UnZip 5.2 and later.
  14.  
  15.   ---------------------------------------------------------------------------*/
  16.  
  17.  
  18. /* stuff to set up for system calls (?FSTAT & ?SACL) and the extra field */
  19.  
  20. #include <paru.h>                   /* parameter definitions */
  21. #include <packets/filestatus.h>     /* AOS/VS ?FSTAT packet defs */
  22. #include <packets/create.h>         /* AOS/VS ?CREATE packet defs */
  23. #include <sys_calls.h>              /* AOS/VS system call interface */
  24.  
  25. #define ZEXTRA_HEADID   "VS"
  26. #define ZEXTRA_SENTINEL "FCI"
  27. #define ZEXTRA_REV      ((uch)10)   /* change/use this in later revs */
  28.  
  29.  
  30. /* functions defined in zvs_create.c */
  31.  
  32. extern int   zvs_create(ZCONST char *fname, long cretim, long modtim,
  33.                         long acctim, char *pacl, int ftyp, int eltsize,
  34.                         int maxindlev);
  35. extern int   zvs_credir(ZCONST char *dname, long cretim, long modtim,
  36.                         long acctim, char *pacl, int ftyp, long maxblocks,
  37.                         int hashfsize, int maxindlev);
  38. extern long  dgdate(short mm, short dd, short yy);
  39. extern char  *ux_to_vs_name(char *outname, ZCONST char *inname);
  40.  
  41.  
  42. /* could probably avoid the unions - all elements in each one are the same
  43.  * size, and we're going to assume this */
  44.  
  45. typedef union zvsfstat_stru {
  46.     P_FSTAT       norm_fstat_packet;      /* normal fstat packet */
  47.     P_FSTAT_DIR   dir_fstat_packet;       /* DIR/CPD fstat packet */
  48.     P_FSTAT_UNIT  unit_fstat_packet;      /* unit (device) fstat packet */
  49.     P_FSTAT_IPC   ipc_fstat_packet;       /* IPC file fstat packet */
  50. } ZVSFSTAT_STRU;
  51.  
  52. typedef union zvscreate_stru {
  53.     P_CREATE      norm_create_packet;     /* normal create packet */
  54.     P_CREATE_DIR  dir_create_packet;      /* DIR/CPD create packet */
  55.     P_CREATE_IPC  ipc_create_packet;      /* IPC file create packet */
  56. } ZVSCREATE_STRU;
  57.  
  58.  
  59. typedef struct zextrafld {
  60.     char            extra_header_id[2];   /* set to VS - in theory, an int */
  61.     char            extra_data_size[2];   /* size of rest (little-endian) */
  62.     char            extra_sentinel[4];    /* set to FCI w/ trailing null */
  63.     uch             extra_rev;            /* set to 10 for rev 1.0 */
  64.     ZVSFSTAT_STRU   fstat_packet;         /* the fstat packet */
  65.     char            aclbuf[$MXACL];       /* the raw ACL */
  66. } ZEXTRAFLD;
  67.