home *** CD-ROM | disk | FTP | other *** search
- #include <libraries/mui.h>
-
- #include <dos/dos.h>
-
- #include <graphics/gfxmacros.h>
-
- #include <workbench/workbench.h>
-
- #include <clib/alib_protos.h>
- #include <clib/exec_protos.h>
- #include <clib/dos_protos.h>
- #include <clib/icon_protos.h>
- #include <clib/graphics_protos.h>
- #include <clib/intuition_protos.h>
- #include <clib/gadtools_protos.h>
- #include <clib/utility_protos.h>
- #include <clib/asl_protos.h>
- #include <clib/muimaster_protos.h>
-
- #include <stdlib.h>
- #include <string.h>
- #include <stdio.h>
-
-
- /* Compiler specific stuff */
-
- #ifdef _DCC
-
- #define REG(x) __ ## x
- #define ASM
- #define SAVEDS __geta4
-
- #else
-
- #define REG(x) register __ ## x
-
-
- #include <pragmas/exec_pragmas.h>
- #include <pragmas/dos_pragmas.h>
- #include <pragmas/icon_pragmas.h>
- #include <pragmas/graphics_pragmas.h>
- #include <pragmas/intuition_pragmas.h>
- #include <pragmas/gadtools_pragmas.h>
- #include <pragmas/utility_pragmas.h>
- #include <pragmas/asl_pragmas.h>
- #include <pragmas/muimaster_pragmas.h>
-
- extern struct Library *SysBase,*IntuitionBase,*UtilityBase,*GfxBase,*DOSBase,*IconBase;
- struct Library *MUIMasterBase;
-
- #endif
-
-
- /*************************/
- /* Init & Fail Functions */
- /*************************/
-
- static VOID fail(APTR app,char *str)
- {
- if (app)
- MUI_DisposeObject(app);
-
- if (MUIMasterBase)
- CloseLibrary(MUIMasterBase);
-
- exit(0);
- }
-
-
- #ifdef _DCC
-
- int brkfunc(void) { return(0); }
-
- #endif
-
-
-
- static VOID init(VOID)
- {
- onbreak(brkfunc);
-
- if (!(MUIMasterBase = OpenLibrary(MUIMASTER_NAME,MUIMASTER_VMIN)))
- fail(NULL,"Failed to open "MUIMASTER_NAME".");
- }
-
-
-