home *** CD-ROM | disk | FTP | other *** search
/ Amiga MA Magazine 1998 #6 / amigamamagazinepolishissue1998.iso / cdrom / amicdrom / src / device.h < prev    next >
C/C++ Source or Header  |  1977-12-31  |  2KB  |  94 lines

  1. /* device.h: */
  2.  
  3. #define CheckIO foo
  4.  
  5. #include <exec/types.h>
  6. #include <exec/memory.h>
  7. #include <exec/execbase.h>
  8. #include <dos/dos.h>
  9. #include <dos/dosextens.h>
  10. #include <dos/dostags.h>
  11. #include <dos/filehandler.h>
  12. #include <devices/timer.h>
  13. #include <devices/input.h>
  14. #include <devices/inputevent.h>
  15. #include <utility/date.h>
  16.  
  17. #include <clib/dos_protos.h>
  18. #include <clib/alib_protos.h>
  19. #include <clib/exec_protos.h>
  20. #include <clib/utility_protos.h>
  21.  
  22. #include "generic.h"
  23.  
  24. #undef CheckIO
  25. struct IORequest *CheckIO(struct IORequest *);
  26.  
  27. #ifdef LATTICE
  28. #include <pragmas/dos_pragmas.h>
  29. #include <pragmas/exec_pragmas.h>
  30. #include <pragmas/utility_pragmas.h>
  31. extern struct Library *DOSBase, *SysBase, *UtilityBase;
  32. #endif
  33.  
  34. #ifdef NDEBUG
  35. #define BUG(x) /* nothing */
  36. #else
  37. #define BUG(x) x
  38. #endif
  39.  
  40. #if !defined(NDEBUG) || defined(DEBUG_SECTORS)
  41. #define BUG2(x) x
  42. #else
  43. #define BUG2(x) /* nothing */
  44. #endif
  45.  
  46. #define CTOB(x) (void *)(((long)(x))>>2)    /*    BCPL conversion */
  47. #define BTOC(x) (void *)(((long)(x))<<2)
  48.  
  49. #define bmov(ss,dd,nn) CopyMem(ss,dd,nn)    /*    my habit    */
  50.  
  51. #define DOS_FALSE   0
  52. #define DOS_TRUE    -1
  53.  
  54. typedef unsigned char    ubyte;            /*    unsigned quantities        */
  55. typedef unsigned short    uword;
  56. typedef unsigned long    ulong;
  57.  
  58. typedef struct Interrupt    INTERRUPT;
  59. typedef struct Task        TASK;
  60. typedef struct FileLock     LOCK;        /*    See LOCKLINK    */
  61. typedef struct FileInfoBlock    FIB;
  62. typedef struct DosPacket    PACKET;
  63. typedef struct Process        PROC;
  64. typedef struct DeviceNode    DEVNODE;
  65. typedef struct DeviceList    DEVLIST;
  66. typedef struct DosInfo        DOSINFO;
  67. typedef struct RootNode     ROOTNODE;
  68. typedef struct FileHandle    FH;
  69. typedef struct MsgPort        PORT;
  70. typedef struct Message        MSG;
  71. typedef struct MinList        LIST;
  72. typedef struct MinNode        NODE;
  73. typedef struct DateStamp    STAMP;
  74. typedef struct InfoData     INFODATA;
  75. typedef struct DosLibrary    DOSLIB;
  76. typedef struct ExecBase        EXECLIB;
  77. typedef struct Library        LIB;
  78.  
  79. #define FILE_DIR    1
  80. #define FILE_FILE   -1
  81.  
  82. void Register_Lock (LOCK *p_lock);
  83. void Unregister_Lock (LOCK *p_lock);
  84. int Reinstall_Locks (void);
  85. void Register_File_Handle (CDROM_OBJ *p_obj);
  86. void Unregister_File_Handle (CDROM_OBJ *p_obj);
  87. DEVLIST *Find_Dev_List (CDROM_OBJ *p_obj);
  88. int Reinstall_File_Handles (void);
  89. void Register_Volume_Node (DEVLIST *p_volume);
  90. void Unregister_Volume_Node (DEVLIST *p_volume);
  91. DEVLIST *Find_Volume_Node (char *p_name);
  92.  
  93. extern t_bool g_disk_inserted;
  94.