home *** CD-ROM | disk | FTP | other *** search
- #include <proto/exec.h>
- #include "demo_pragmas.h"
- #include <stdlib.h>
- #include <math.h>
-
- /*
- * This would normally be in a proto file
- */
- int SquareMe(int);
-
- struct Library *DemoBase;
-
- void main(int argc, char *argv[])
- {
-
- DemoBase = OpenLibrary("demo.library", 0);
- if (!DemoBase) {
- printf("Where's demo.library?\n");
- exit(0);
- }
- printf("Base is %08X\n", DemoBase);
- printf("Square of input is: %d\n", SquareMe(atoi(argv[1])));
- CloseLibrary(DemoBase);
- }
-
-