home *** CD-ROM | disk | FTP | other *** search
-
- ' a program to show various info about any library
- ' if run from the CLI then can specify library name on command line
- ' else prompted; .library not required
-
- ' when compiling to disk, un-comment the next two lines
- 'REM $option y
- 'IF PEEKL(SYSTAB+8) THEN WINDOW 1,"LibVersion"
-
- LIBRARY "exec.library"
- DECLARE FUNCTION OpenLibrary&(ptr&,ver&) LIBRARY
- DECLARE SUB CloseLibrary(lptr&) LIBRARY
-
- PRINT "Compiled with HiSoft BASIC"
-
- lib$=COMMAND$
- IF LEN(lib$)=0 THEN INPUT "Library name";lib$
- lib$=lib$+".library"+CHR$(0)
- l&=OpenLibrary(SADD(lib$),0)
- IF l&=0 THEN
- PRINT "Library not found"
- ELSE
- PRINT "Library: ";LEFT$(lib$,LEN(lib$)-1)," $";HEX$(l&)
- PRINT "Version:";PEEKW(l&+20);"rev";PEEKW(l&+22)
- id&=PEEKL(l&+24)
- IF id& THEN
- PRINT "ID : ";
- WHILE PEEKB(id&)>=32
- PRINT CHR$(PEEKB(id&));
- INCR id&
- WEND
- PRINT
- END IF
- PRINT "OpenCnt:";PEEKW(l&+32)
- CloseLibrary l&
- END IF
-
-