================================================================================
B A S T A R D                                            disassembly environment

                           Source  Code  Layout



bastard                          /* bastard 'home' directory */
|-- KNOWN_BUGS                   /* A list of things to be safely ignored */
|-- Makefile                     /* the, er, makefile */
|-- README.CODERS                /* info for developers */
|-- README.TXT                   /* breaking news & howto's */
|-- TODO                         /* /dev/null */
|-- arch                         /* Location of loadable ARCH extensions */
|   |-- README.arch              /* Description of arch extensions */
|   `-- libi386.so               /* x86 Arch extension */
|-- asm                          /* Location of loadable ASM extensions */
|   |-- README.asm               /* Description of asm extensions */
|   `-- libintel.so              /* Intel Assembler extension */
|-- bastard                      /* main executable : CLI frontend */
|-- db                           /* location of .dbd files */
|   |-- bdb.dbd                  /* Target database defintion file */
|   `-- cfg.dbd                  /* Configuration database definition file */
|-- doc                          /* Main documentation/man page directory */
|   |-- BCScript.txt             /* Bastard BC Scripting Manual */
|   |-- DBSchema.txt             /* Bastard Database Schematics */
|   |-- Disasm-HOWTO.txt         /* HowTo for basic bastard disassembly */
|   |-- EiC.ps                   /* Postscript version of the EiC manual */
|   |-- EiC.txt                  /* Bad ASCII version of the EiC manual */
|   |-- ExtensionProg.txt        /* Bastard Extension Programming Guide */
|   |-- FrontEndProg.txt         /* Bastard Front-End Programming Guide */
|   |-- Function-HOWTO.txt       /* HowTo for creating/using FUNCTIONs */
|   |-- SourceLayout.txt         /* This file */
|   |-- Structure-HOWTO.txt      /* HowTo for creating/using STRUCTUREs*/
|   |-- TheoryOfOp.txt           /* Bastard Theory of Operations */
|   |-- bastard.spec             /* ancient spec */
|   |-- bastard.txt              /* ancient manual */
|   |-- libi386.txt              /* readme for the x86 ARCH extension */
|   |-- man                      /* bastard, EiC, Typhoon man pages */
|       |-- ddlp.1               /* Typhoon ddlp utility man page */
|       `-- eic.1                /* EiC interpreter man page */
|   `-- typhoon.txt              /* Typhoon user manual */
|-- engines                      /* Location of loadable ENGINE extensions */
|   |-- pass1.bc                 /* post disassembly pass 1: Subroutine Rec */
|   |-- pass2.bc                 /* post disassembly pass 2: Sub Arhs/Rets */
|   |-- pass3.bc                 /* post disassembly pass 3: String Creation */
|   |-- pass4.bc                 /* post disassembly pass 4: */
|   `-- pass5.bc                 /* post disassembly pass 5: Sub Naming */
|-- formats                      /* Location of loadable FORMAT extensions */
|   |-- ELF.bc                   /* ELF file format parser */
|   `-- README.TXT               /* Description of formats directory */
|-- include                      /* Main include directory */
|   |-- api                         /* API internal header files */
|   |   |-- api_error.h             /* bastard error codes */
|   |   |-- api_main.h              /* main API includes/dependencies */
|   |   `-- util.h                  /* general purpose utility functions */ 
|   |-- bastard.h                   /* Main bastard API include file */
|   |                               /*    Defines :      */
|   |                               /*      AddrExists( ) */
|   |                               /*      ApplyInlineFunction( ) */
|   |                               /*      ApplyStructure( ) */
|   |                               /*      asmsprintf( ) */
|   |                               /*      ClearEnv( ) */
|   |                               /*      ClearEnvFlag( ) */
|   |                               /*      ClearOption( ) */
|   |                               /*      ClearTarget( ) */
|   |                               /*      CloseDB( ) */
|   |                               /*      CompileScript( ) */
|   |                               /*      Core( ) */
|   |                               /*      CreateHeader( ) */
|   |                               /*      CreateSection( ) */
|   |                               /*      DBFindClosestNext( ) */
|   |                               /*      DBFindClosestPrev( ) */
|   |                               /*      DBIndexFind( ) */
|   |                               /*      DBIndexFirst( ) */
|   |                               /*      DBIndexLast( ) */
|   |                               /*      DBIndexNext( ) */
|   |                               /*      DBIndexPrev( ) */
|   |                               /*      DBRecordDelete( ) */
|   |                               /*      DBRecordInsert( ) */
|   |                               /*      DBRecordUpdate( ) */
|   |                               /*      DBRestoreState( ) */
|   |                               /*      DBRestoreState( ) */
|   |                               /*      DBSaveState( ) */
|   |                               /*      DBSaveState( ) */
|   |                               /*      DBTableFirst( ) */
|   |                               /*      DBTableLast( ) */
|   |                               /*      DBTableNext( ) */
|   |                               /*      DBTablePrev( ) */
|   |                               /*      Debug( ) */
|   |                               /*      DefineAddr( ) */
|   |                               /*      DefineAddrComment( ) */
|   |                               /*      DefineAddrExp( ) */
|   |                               /*      DefineCode( ) */
|   |                               /*      DefineComment( ) */
|   |                               /*      DefineConstant( ) */
|   |                               /*      DefineExport( ) */
|   |                               /*      DefineFunc( ) */
|   |                               /*      DefineImport( ) */
|   |                               /*      DefineLibrary( ) */
|   |                               /*      DefineMacro( ) */
|   |                               /*      DefineRef( ) */
|   |                               /*      DefineString( ) */
|   |                               /*      DelComment( ) */
|   |                               /*      DelConstant( ) */
|   |                               /*      DeleteSection( ) */
|   |                               /*      DisAddrSize( ) */
|   |                               /*      DisByteOrder( ) */
|   |                               /*      DisByteSize( ) */
|   |                               /*      DisDwordSize( ) */
|   |                               /*      DisEpilogue( ) */
|   |                               /*      DisGetIP( ) */
|   |                               /*      DisGetSP( ) */
|   |                               /*      DisPrologue( ) */
|   |                               /*      DisWordSize( ) */
|   |                               /*      DisassembleAllPasses( ) */
|   |                               /*      DisassembleDumb( ) */
|   |                               /*      DisassembleForward( ) */
|   |                               /*      DisassembleFull( ) */
|   |                               /*      DisassemblePass( ) */
|   |                               /*      DisassembleRange( ) */
|   |                               /*      DisassembleSection( ) */
|   |                               /*      DumpExports( ) */
|   |                               /*      DumpImports( ) */
|   |                               /*      DumpLibs( ) */
|   |                               /*      DumpStrings( ) */
|   |                               /*      ErrorMsg( ) */
|   |                               /*      Exec( ) */
|   |                               /*      FindBytes( ) */
|   |                               /*      FindClosestAddr( ) */
|   |                               /*      FindConstant( ) */
|   |                               /*      FindMnemonic( ) */
|   |                               /*      FindNextOpExec( ) */
|   |                               /*      FindNextOpRead( ) */
|   |                               /*      FindNextOpWrite( ) */
|   |                               /*      FindOperand( ) */
|   |                               /*      FindPrevOpExec( ) */
|   |                               /*      FindPrevOpRead( ) */
|   |                               /*      FindPrevOpWrite( ) */
|   |                               /*      FindStringsInRange( ) */
|   |                               /*      FreeSearchHandle( ) */
|   |                               /*      GetAddrByName( ) */
|   |                               /*      GetAddrBytes( ) */
|   |                               /*      GetAddrComment( ) */
|   |                               /*      GetAddrConstant( ) */
|   |                               /*      GetAddrExpObject( ) */
|   |                               /*      GetAddrExpr( ) */
|   |                               /*      GetAddrExprString( ) */
|   |                               /*      GetAddrSize( ) */
|   |                               /*      GetAddrStruct( ) */
|   |                               /*      GetAddrType( ) */
|   |                               /*      GetAddressObject( ) */
|   |                               /*      GetAux( ) */
|   |                               /*      GetAuxType( ) */
|   |                               /*      GetBCMacroObject( ) */
|   |                               /*      GetBranchCode( ) */
|   |                               /*      GetCodeObject( ) */
|   |                               /*      GetCodeRep( ) */
|   |                               /*      GetCodeRep( ) */
|   |                               /*      GetComment( ) */
|   |                               /*      GetCommentObject( ) */
|   |                               /*      GetConstant( ) */
|   |                               /*      GetConstantID( ) */
|   |                               /*      GetConstantName( ) */
|   |                               /*      GetConstantNext( ) */
|   |                               /*      GetConstantObject( ) */
|   |                               /*      GetDataTypeObject( ) */
|   |                               /*      GetDebugger( ) */
|   |                               /*      GetDest( ) */
|   |                               /*      GetDestType( ) */
|   |                               /*      GetDisasmAsm( ) */
|   |                               /*      GetDisasmEng( ) */
|   |                               /*      GetDisasmEnv( ) */
|   |                               /*      GetDisasmHome( ) */
|   |                               /*      GetDisasmLang( ) */
|   |                               /*      GetDisasmPrefs( ) */
|   |                               /*      GetDisasmTgt( ) */
|   |                               /*      GetEditor( ) */
|   |                               /*      GetEntireString( ) */
|   |                               /*      GetEnvFlag( ) */
|   |                               /*      GetExport( ) */
|   |                               /*      GetExportObject( ) */
|   |                               /*      GetFInlineObject( ) */
|   |                               /*      GetFinCodeObject( ) */
|   |                               /*      GetFlags( ) */
|   |                               /*      GetFlags( ) */
|   |                               /*      GetFuncByName( ) */
|   |                               /*      GetFuncEnd( ) */
|   |                               /*      GetFuncLocalObject( ) */
|   |                               /*      GetFuncName( ) */
|   |                               /*      GetFuncParamObject( ) */
|   |                               /*      GetFuncStart( ) */
|   |                               /*      GetFunctionComment( ) */
|   |                               /*      GetFunctionObject( ) */
|   |                               /*      GetFunctionPrototype( ) */
|   |                               /*      GetImportLib( ) */
|   |                               /*      GetImportName( ) */
|   |                               /*      GetImportObject( ) */
|   |                               /*      GetImportType( ) */
|   |                               /*      GetInlineTypeObject( ) */
|   |                               /*      GetIntCodeObject( ) */
|   |                               /*      GetLastError( ) */
|   |                               /*      GetLastError( ) */
|   |                               /*      GetLastErrorString( ) */
|   |                               /*      GetMnemType( ) */
|   |                               /*      GetMnemonic( ) */
|   |                               /*      GetName( ) */
|   |                               /*      GetName( ) */
|   |                               /*      GetNameObject( ) */
|   |                               /*      GetNameType( ) */
|   |                               /*      GetNextAddr( ) */
|   |                               /*      GetNextCode( ) */
|   |                               /*      GetNextData( ) */
|   |                               /*      GetNextRefFrom( ) */
|   |                               /*      GetNextRefTo( ) */
|   |                               /*      GetOption( ) */
|   |                               /*      GetPA( ) */
|   |                               /*      GetPager( ) */
|   |                               /*      GetPrevAddr( ) */
|   |                               /*      GetPrevCode( ) */
|   |                               /*      GetPrevData( ) */
|   |                               /*      GetRVA( ) */
|   |                               /*      GetRefFrom( ) */
|   |                               /*      GetRefTo( ) */
|   |                               /*      GetSection( ) */
|   |                               /*      GetSectionEnd( ) */
|   |                               /*      GetSectionFlags( ) */
|   |                               /*      GetSectionName( ) */
|   |                               /*      GetSectionObject( ) */
|   |                               /*      GetSectionStart( ) */
|   |                               /*      GetSrc( ) */
|   |                               /*      GetSrcType( ) */
|   |                               /*      GetString( ) */
|   |                               /*      GetStringObject( ) */
|   |                               /*      GetStructMemberObject( ) */
|   |                               /*      GetStructureTypeObject( ) */
|   |                               /*      GetTargetFD( ) */
|   |                               /*      GetTargetImage( ) */
|   |                               /*      GetTargetSize( ) */
|   |                               /*      GetValidArchs( ) */
|   |                               /*      GetValidArchs( ) */
|   |                               /*      GetValidFormats( ) */
|   |                               /*      GetValidFormats( ) */
|   |                               /*      GetXrefObject( ) */
|   |                               /*      Init( ) */
|   |                               /*      InitDisassembler( ) */
|   |                               /*      IsValidAddr( ) */
|   |                               /*      IsValidCodeAddr( ) */
|   |                               /*      JumpTo( ) */
|   |                               /*      LoadBDB( ) */
|   |                               /*      LoadTarget( ) */
|   |                               /*      MakeCode( ) */
|   |                               /*      MakeData( ) */
|   |                               /*      MakeData( ) */
|   |                               /*      MakeFunction( ) */
|   |                               /*      MakeInlineFunction( ) */
|   |                               /*      Message( ) */
|   |                               /*      Panic( ) */
|   |                               /*      PrintAddress( ) */
|   |                               /*      PrintErrorMsg( ) */
|   |                               /*      PrintHeader( ) */
|   |                               /*      Quit( ) */
|   |                               /*      ReInit( ) */
|   |                               /*      ReInit( ) */
|   |                               /*      RecordMacro( ) */
|   |                               /*      RunCompiledScript( ) */
|   |                               /*      RunMacro( ) */
|   |                               /*      RunScript( ) */
|   |                               /*      RunScriptText( ) */
|   |                               /*      SaveAsASM( ) */
|   |                               /*      SaveAsBinary( ) */
|   |                               /*      SaveAsDiff( ) */
|   |                               /*      SaveAsDump( ) */
|   |                               /*      SaveDB( ) */
|   |                               /*      SaveDBAs( ) */
|   |                               /*      SaveDBBak( ) */
|   |                               /*      SetAddrComment( ) */
|   |                               /*      SetAddrConstant( ) */
|   |                               /*      SetAddrStruct( ) */
|   |                               /*      SetComment( ) */
|   |                               /*      SetDebugger( ) */
|   |                               /*      SetEditor( ) */
|   |                               /*      SetEnvDefaults( ) */
|   |                               /*      SetEnvFlag( ) */
|   |                               /*      SetFileArch( ) */
|   |                               /*      SetFileAsmFmt( ) */
|   |                               /*      SetFileDataFmt( ) */
|   |                               /*      SetFileFormat( ) */
|   |                               /*      SetFlags( ) */
|   |                               /*      SetFuncName( ) */
|   |                               /*      SetFuncSize( ) */
|   |                               /*      SetFunctionComment( ) */
|   |                               /*      SetFunctionPrototype( ) */
|   |                               /*      SetLastError( ) */
|   |                               /*      SetLprAsmFmt( ) */
|   |                               /*      SetLprDataFmt( ) */
|   |                               /*      SetName( ) */
|   |                               /*      SetOption( ) */
|   |                               /*      SetOutputAssembler( ) */
|   |                               /*      SetPager( ) */
|   |                               /*      SetPrefDefaults( ) */
|   |                               /*      SetSectionEnd( ) */
|   |                               /*      SetSectionFlags( ) */
|   |                               /*      SetSectionName( ) */
|   |                               /*      SetSectionStart( ) */
|   |                               /*      SetTargetDefaults( ) */
|   |                               /*      SetTargetLanguage( ) */
|   |                               /*      SetTtyAsmFmt( ) */
|   |                               /*      SetTtyDataFmt( ) */
|   |                               /*      SprintErrorMsg( ) */
|   |                               /*      UndefineAddr( ) */
|   |                               /*      UndefineCode( ) */
|   |                               /*      UndefineMacro( ) */
|   |-- bdb.h                       /* Structure defs for TargetDB */
|   |-- cfg.h                       /* Structure defs for ConfigDB */
|   |-- cli                         /* Include files for CLI front-end */
|   |   |-- bastard_main.h          /* Main bastard executable include */
|   |   |                           /*    Defines :      */
|   |   |                           /*      ReadPrefs( ) */
|   |   |-- cli_cmd.h               /* CLI commands and aliases */
|   |   |                           /*    Defines :      */
|   |   |                           /*      cmd*( ) */
|   |   |-- cli_db.h                /* CLI DB access routines */
|   |   |                           /*    Defines :      */
|   |   |                           /*      dbPrint*( ) */
|   |   |                           /*      db_cmd( ) */
|   |   `-- parser.h                /* Command line scanner/parser */
|   |                               /*    Defines :      */
|   |                               /*      ProcessCommand( ) */
|   |-- config.h                    /* Include for ConfigDB routines */
|   |                               /*    Defines :      */
|   |                               /*      CreateProfile( ) */
|   |                               /*      DeleteProfile( ) */
|   |                               /*      GetProfile( ) */
|   |                               /*      LoadConfigDB( ) */
|   |                               /*      LoadProfile( ) */
|   |                               /*      UnloadConfigDB( ) */
|   |                               /*      UpdateProfile( ) */
|   |-- db                          /* includes for Typhoon DB and interface */
|   |   |-- db.h                    /* Typhoon DB interface include */
|   |   |                           /*    Defines :      */
|   |   |                           /*      LoadDB( ) */
|   |   |                           /*      SwitchDB( ) */
|   |   |                           /*      UnloadDB( ) */
|   |   |                           /*      dbError( ) */
|   |   |                           /*      dbErrorMsg( ) */
|   |   |                           /*      doTyphoon( ) */
|   |   |                           /*      initSequences( ) */
|   |   |-- db_main.h               /* DB interface main include */
|   |   |-- environ.h               /* Typhoon-generated header file */
|   |   `-- typhoon.h               /* Typhoon DB main header file */
|   |                               /*    Defines :      */
|   |                               /*      d_close( ) */
|   |                               /*      d_crget( ) */
|   |                               /*      d_crread( ) */
|   |                               /*      d_crset( ) */
|   |                               /*      d_dbdpath( ) */
|   |                               /*      d_dbfpath( ) */
|   |                               /*      d_dbget( ) */
|   |                               /*      d_dbset( ) */
|   |                               /*      d_delete( ) */
|   |                               /*      d_destroy( ) */
|   |                               /*      d_fillnew( ) */
|   |                               /*      d_getkeyid( ) */
|   |                               /*      d_keyfind( ) */
|   |                               /*      d_keyfrst( ) */
|   |                               /*      d_keylast( ) */
|   |                               /*      d_keynext( ) */
|   |                               /*      d_keyprev( ) */
|   |                               /*      d_keyread( ) */
|   |                               /*      d_open( ) */
|   |                               /*      d_recfrst( ) */
|   |                               /*      d_reclast( ) */
|   |                               /*      d_recnext( ) */
|   |                               /*      d_recprev( ) */
|   |                               /*      d_recread( ) */
|   |                               /*      d_recwrite( ) */
|   |-- debug.h                     /* Debug output macros */
|   |                               /*    Defines :      */
|   |                               /*      DEBUG_PrintVar(x, y) */
|   |                               /*      DEBUG_PrintMsg(x, y) */
|   |-- extension.h                 /* Bastard Extensions interface */
|   |                               /*    Defines :      */
|   |                               /*     CleanupExtensions( ) */
|   |                               /*     GetExtensionFlags( ) */
|   |                               /*     InitExtensions( ) */
|   |                               /*     LoadExtension( ) */
|   |                               /*     UnloadExtension( ) */
|   |-- script                      /* EiC/macro include directory */
|   |   |-- eic                     /* Location of EiC include tree */
|   |   |                           /* NOTE: this include directory is */
|   |   |                           /* used by EiC at runtime to resolve */
|   |   |                           /* standard C library routine refs */
|   |   |-- eic.h                   /* EiC main header file */
|   |   |                           /*    Defines :      */
|   |   |                           /*      EiC_callBack( ) */
|   |   |                           /*      EiC_init_EiC( ) */
|   |   |                           /*      EiC_parseString( ) */
|   |   |                           /*      EiC_run( ) */
|   |   |                           /*      EiC_setMessageDisplay( ) */
|   |   |                           /*      EiC_startEiC( ) */
|   |   |-- eicval.h                /* EiC 'val_t' header file */
|   |   |-- macro.h                 /* EiC interface header */
|   |   |                           /*    Defines :      */
|   |   |                           /*      ExecMacroLine( ) */
|   |   |                           /*      checkLine( ) */
|   |   |                           /*      doSeer( ) */
|   |   |                           /*      finSeer( ) */
|   |   `-- script_main.h           /* Main Script interface header */
|   |-- util.h                      /* Generic utility header */
|   |                               /*    Defines :      */
|   |                               /*      istrncmp( ) */
|   |                               /*      strtoupper( ) */
|   |                               /*      endian_check( ) */
|   |                               /*      encmp_range( ) */
|   |                               /*      encmp_short( ) */
|   |                               /*      encmp_int( ) */
|   |                               /*      encpy_range( ) */
|   |                               /*      encpy_short( ) */
|   |                               /*      encpy_int( ) */
|   `-- vm.h                        /* PsuedoVirtualMachine interface */
|                                   /*    Defines :      */
|                                   /*      AddRegTableEntry( ) */
|                                   /*      CleanupVM( ) */
|                                   /*      GetRegMnemonic( ) */
|                                   /*      GetRegSize( ) */
|                                   /*      InitVM( ) */
|-- lang                            /* Location of loadable LANG extensions */  
|   |-- README.lang                 /* Description of the LANG extensions */
|   `-- libC.so                     /* C LANG extension (default) */
|-- lib                             /* Shared and Static library files */
|   |-- libbastard.a                /* Static library version of the bastard */
|   |-- libbastard.so               /* Shared library version of the bastard */
|   |-- libeic.a                    /* Static library for EiC interpreter */
|   |-- libstdClib.a                /* Static library for EiC interpreter */
|   `-- libtyphoon.a                /* Static library for Tyhoon RDBMS */
|   |-- disasm.text.bc              /* Extension for .text section Disassembly */
|   |-- libdisasm.dumb.so           /* Extension for Dumb Disassembly */
|   `-- libdisasm.full.so           /* Extension for Full Disassembly */
|-- scripts                         /* Location of loadable SCRIPT extensions */
|   |-- call_tree.bc                /* Unwritten Call Tree script */
|   |-- exports.bc                  /* List all exports */
|   |-- functions.bc                /* List all functions */
|   |-- imports.bc                  /* List all imports */
|   |-- macros                      /* Location of saved macros */
|   |-- names.bc                    /* List all names */
|   |-- strings.bc                  /* List all strings */
|   |-- top_xrefs.bc                /* Unwritten "Most used Xrefs" script */
|   `-- xrefs.bc                    /* List all Xrefs */		
|-- src                             /* main bastard source tree */
|   |-- EiC                         /* Source tree for EiC C interpreter */
|   |-- api                         /* Bastard API implementation */
|   |   |-- api_address.c           /* Bastard API ADDRESS routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      AddrExists( ) */
|   |   |                           /*      DefineAddr( ) */
|   |   |                           /*      DefineAddrComment( ) */
|   |   |                           /*      FindClosestAddr( ) */
|   |   |                           /*      GetAddrBytes( ) */
|   |   |                           /*      GetAddrComment( ) */
|   |   |                           /*      GetAddrConstant( ) */
|   |   |                           /*      GetAddrSize( ) */
|   |   |                           /*      GetAddrStruct( ) */
|   |   |                           /*      GetAddrType( ) */
|   |   |                           /*      GetFlags( ) */
|   |   |                           /*      GetNextAddr( ) */
|   |   |                           /*      GetPA( ) */
|   |   |                           /*      GetPrevAddr( ) */
|   |   |                           /*      GetRVA( ) */
|   |   |                           /*      IsValidAddr( ) */
|   |   |                           /*      IsValidCodeAddr( ) */
|   |   |                           /*      MakeCode( ) */
|   |   |                           /*      MakeData( ) */
|   |   |                           /*      MergeAddress( ) */
|   |   |                           /*      PrintAddress( ) */
|   |   |                           /*      SetAddrComment( ) */
|   |   |                           /*      SetAddrConstant( ) */
|   |   |                           /*      SetAddrStruct( ) */
|   |   |                           /*      SetFlags( ) */
|   |   |                           /*      SplitAddress( ) */
|   |   |                           /*      UndefineAddr( ) */
|   |   |                           /*      asmsprintf( ) */
|   |   |-- api_code.c              /* Bastard API CODE routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      DefineCode( ) */
|   |   |                           /*      GetAux( ) */
|   |   |                           /*      GetAuxType( ) */
|   |   |                           /*      GetCodeRep( ) */
|   |   |                           /*      GetDest( ) */
|   |   |                           /*      GetDestType( ) */
|   |   |                           /*      GetMnemType( ) */
|   |   |                           /*      GetMnemonic( ) */
|   |   |                           /*      GetNextCode( ) */
|   |   |                           /*      GetNextData( ) */
|   |   |                           /*      GetSrc( ) */
|   |   |                           /*      GetSrcType( ) */
|   |   |                           /*      SetAux( ) */
|   |   |                           /*      SetDest( ) */
|   |   |                           /*      SetMnemonic( ) */
|   |   |                           /*      SetSrc( ) */
|   |   |                           /*      UndefineCode( ) */
|   |   |-- api_disasm.c            /* Bastard API Disassembly routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      AnalyzeCurrInst( ) */
|   |   |                           /*      AnalyzeCurrOp( ) */
|   |   |                           /*      CreateHeader( ) */
|   |   |                           /*      DisAddr( ) */
|   |   |                           /*      DisassembleAllPasses( ) */
|   |   |                           /*      DisassembleDumb( ) */
|   |   |                           /*      DisassembleForward( ) */
|   |   |                           /*      DisassembleFull( ) */
|   |   |                           /*      DisassemblePass( ) */
|   |   |                           /*      DisassembleRange( ) */
|   |   |                           /*      DisassembleSection( ) */
|   |   |                           /*      InitDisassembler( ) */
|   |   |                           /*      PrintHeader( ) */
|   |   |-- api_env.c               /* Bastard API Environment routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      ClearEnvFlag( ) */
|   |   |                           /*      ClearOption( ) */
|   |   |                           /*      GetEnvFlag( ) */
|   |   |                           /*      GetOption( ) */
|   |   |                           /*      SetEnvFlag( ) */
|   |   |                           /*      SetFileAsmFmt( ) */
|   |   |                           /*      SetFileDataFmt( ) */
|   |   |                           /*      SetLprAsmFmt( ) */
|   |   |                           /*      SetLprDataFmt( ) */
|   |   |                           /*      SetOption( ) */
|   |   |                           /*      SetTtyAsmFmt( ) */
|   |   |                           /*      SetTtyDataFmt( ) */
|   |   |-- api_functions.c         /* Bastard API FUNCTION INLINE routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      DefineFunc( ) */
|   |   |                           /*      GetFuncByName( ) */
|   |   |                           /*      GetFuncEnd( ) */
|   |   |                           /*      GetFuncName( ) */
|   |   |                           /*      GetFuncStart( ) */
|   |   |                           /*      SetFuncName( ) */
|   |   |                           /*      SetFuncSize( ) */
|   |   |-- api_importexport.c      /* Bastard API IMPORT EXPORT routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      DefineExport( ) */
|   |   |                           /*      DefineLibrary( ) */
|   |   |                           /*      DumpExports( ) */
|   |   |                           /*      DumpImports( ) */
|   |   |                           /*      DumpLibs( ) */
|   |   |                           /*      GetExport( ) */
|   |   |                           /*      GetImportLib( ) */
|   |   |                           /*      GetImportName( ) */
|   |   |                           /*      GetImportType( ) */
|   |   |-- api_loadsave.c          /* Bastard API loading, saving routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      CloseDB( ) */
|   |   |                           /*      LoadBDB( ) */
|   |   |                           /*      LoadTarget( ) */
|   |   |                           /*      SaveAsASM( ) */
|   |   |                           /*      SaveAsBinary( ) */
|   |   |                           /*      SaveAsDiff( ) */
|   |   |                           /*      SaveAsDump( ) */
|   |   |                           /*      SaveDB( ) */
|   |   |                           /*      SaveDBAs( ) */
|   |   |                           /*      SaveDBBak( ) */
|   |   |                           /*      SetFileArch( ) */
|   |   |                           /*      SetFileFormat( ) */
|   |   |                           /*      SetOutputAssembler( ) */
|   |   |-- api_macros.c            /* Bastard API MACRO, script routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      CompileScript( ) */
|   |   |                           /*      DefineMacro( ) */
|   |   |                           /*      RecordMacro( ) */
|   |   |                           /*      RunCompiledScript( ) */
|   |   |                           /*      RunMacro( ) */
|   |   |                           /*      RunScript( ) */
|   |   |                           /*      RunScriptText( ) */
|   |   |                           /*      UndefineMacro( ) */
|   |   |-- api_namecomment.c       /* Bastard API NAME COMMENT routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      DefineComment( ) */
|   |   |                           /*      DelComment( ) */
|   |   |                           /*      DelName( ) */
|   |   |                           /*      GetAddrByName( ) */
|   |   |                           /*      GetComment( ) */
|   |   |                           /*      GetName( ) */
|   |   |                           /*      GetNameType( ) */
|   |   |                           /*      SetComment( ) */
|   |   |                           /*      SetName( ) */
|   |   |-- api_search.c            /* Bastard API search routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      FindBytes( ) */
|   |   |                           /*      FindConstant( ) */
|   |   |                           /*      FindMnemonic( ) */
|   |   |                           /*      FindNextOpExec( ) */
|   |   |                           /*      FindNextOpRead( ) */
|   |   |                           /*      FindNextOpWrite( ) */
|   |   |                           /*      FindOpTTL( ) */
|   |   |                           /*      FindOperand( ) */
|   |   |                           /*      FindPrevOpExec( ) */
|   |   |                           /*      FindPrevOpRead( ) */
|   |   |                           /*      FindPrevOpWrite( ) */
|   |   |                           /*      FreeSearchHandle( ) */
|   |   |                           /*      PrepDBSearch( ) */
|   |   |-- api_section.c           /* Bastard API SECTION routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      CreateSection( ) */
|   |   |                           /*      DeleteSection( ) */
|   |   |                           /*      GetSection( ) */
|   |   |                           /*      GetSectionEnd( ) */
|   |   |                           /*      GetSectionStart( ) */
|   |   |-- api_strings.c           /* Bastard API STRING routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      DefineString( ) */
|   |   |                           /*      DumpStrings( ) */
|   |   |                           /*      FindStringsInRange( ) */
|   |   |                           /*      GetEntireString( ) */
|   |   |                           /*      GetString( ) */
|   |   |-- api_structconst.c       /* Bastard API STRUCTURE CONSTANT funcs */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      ApplyStructure( ) */
|   |   |                           /*      DefineConstant( ) */
|   |   |                           /*      DefineDataType( ) */
|   |   |                           /*      DefineStructMember( ) */
|   |   |                           /*      DelConstant( ) */
|   |   |                           /*      DelStruct( ) */
|   |   |                           /*      DelStructMember( ) */
|   |   |                           /*      GetConstant( ) */
|   |   |                           /*      GetConstantName( ) */
|   |   |                           /*      GetConstantNext( ) */
|   |   |                           /*      GetStruct( ) */
|   |   |                           /*      GetStructMember( ) */
|   |   |-- api_system.c            /* Bastard API system routines */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      Core( ) */
|   |   |                           /*      Debug( ) */
|   |   |                           /*      ErrorMsg( ) */
|   |   |                           /*      Exec( ) */
|   |   |                           /*      GetLastError( ) */
|   |   |                           /*      GetValidArchs( ) */
|   |   |                           /*      GetValidFormats( ) */
|   |   |                           /*      Init( ) */
|   |   |                           /*      Message( ) */
|   |   |                           /*      Panic( ) */
|   |   |                           /*      PrintErrorMsg( ) */
|   |   |                           /*      Quit( ) */
|   |   |                           /*      ReInit( ) */
|   |   |                           /*      SetLastError( ) */
|   |   |                           /*      SprintErrorMsg( ) */
|   |   `-- api_xref.c              /* bastard API XREF routines */
|   |                               /*   Contains:              */ 
|   |                               /*      DefineRef( ) */
|   |                               /*      GetNextRefFrom( ) */
|   |                               /*      GetNextRefTo( ) */
|   |                               /*      GetRefFrom( ) */
|   |                               /*      GetRefTo( ) */
|   |-- arch                        /* source code for ARCH extensions */
|   |   |-- i386.c                  /* x86 ARCH extension */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      DecodeByte( ) */
|   |   |                           /*      DecodeSIB( ) */
|   |   |                           /*      GetSizedOperand( ) */
|   |   |                           /*      InitRegTable( ) */
|   |   |                           /*      InstDecode( ) */
|   |   |                           /*      disasm_addr( ) */
|   |   |                           /*      ext_arch_cleanup( ) */
|   |   |                           /*      ext_arch_init( ) */
|   |   |                           /*      get_epilogue( ) */
|   |   |                           /*      get_prologue( ) */
|   |   |-- i386.h                  /* x86 ARCH extension interface, defs */
|   |   |-- i386.opcode.map         /* x86 opcode definitions */
|   |   `-- Template.c              /* Template for writing ARCH extensions */
|   |-- asm                         /* source code for ASM extensions */
|   |   |-- intel.c                 /* Intel assembler extension */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      ext_asm_init( ) */
|   |   |                           /*      sprint_code( ) */
|   |   |                           /*      sprint_sec_end( ) */
|   |   |                           /*      sprint_sec_start( ) */
|   |   `-- Template.c              /* Template for writing ASM extensions */
|   |-- bdb.ddl                     /* source code for Target (bdb.dbd) DB */
|   |-- cfg.ddl                     /* source code for Config (cfg.dbd) DB */
|   |-- cli                         /* CLI front-end to libbastard.so */
|   |   |-- bastard.c               /* CLI front-end main() and etc */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      ReadPrefs( ) */
|   |   |                           /*      user_kill( ) */
|   |   |-- cli_cmd.c               /* CLI front-end commands */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      cmd*( ) */
|   |   |-- cli_db.c                /* command line interface to the DB */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      dbPrint*( ) */
|   |   |                           /*      db_cmd( ) */
|   |   `-- parser.c                /* command scanner/parser */
|   |                               /*   Contains:              */ 
|   |                               /*      ProcessCommand( ) */
|   |                               /*      istrcmp( ) */
|   |-- config.c                    /* Routines for manipulating cfg.bdb */
|   |                               /*   Contains:              */ 
|   |                               /*      CreateProfile( ) */
|   |                               /*      DeleteProfile( ) */
|   |                               /*      GetProfile( ) */
|   |                               /*      LoadConfigDB( ) */
|   |                               /*      UnloadConfigDB( ) */
|   |                               /*      UpdateProfile( ) */
|   |-- db.c                        /* Routines for accessing Typhoon */
|   |                               /*   Contains:              */ 
|   |                               /*      DBIndexFind( ) */
|   |                               /*      DBIndexFirst( ) */
|   |                               /*      DBIndexLast( ) */
|   |                               /*      DBIndexNext( ) */
|   |                               /*      DBIndexPrev( ) */
|   |                               /*      DBRecordDelete( ) */
|   |                               /*      DBRecordInsert( ) */
|   |                               /*      DBRecordUpdate( ) */
|   |                               /*      DBRestoreState( ) */
|   |                               /*      DBTableFirst( ) */
|   |                               /*      DBTableLast( ) */
|   |                               /*      DBTableNext( ) */
|   |                               /*      DBTablePrev( ) */
|   |                               /*      InitDB( ) */
|   |                               /*      LoadDB( ) */
|   |                               /*      SwitchDB( ) */
|   |                               /*      UnloadDB( ) */
|   |                               /*      dbError( ) */
|   |                               /*      dbErrorMsg( ) */
|   |                               /*      initSequences( ) */
|   |-- eic_wrappers.c              /* Bastard API wrappers for EiC access */
|   |                               /*   Contains:              */ 
|   |                               /*      EicLoadApi( ) */
|   |-- engines                     /* directory for ENGINE extension source */
|   |   `-- Template.c              /* Template for writing ENGINE extensions */
|   |-- extension.c                 /* Routines for manipulating extensions */
|   |                               /*   Contains:          */
|   |                               /*      CleanupExtensions( ) */
|   |                               /*      GetExtensionFlags( ) */
|   |                               /*      InitExtensions( ) */
|   |                               /*      LoadExtension( ) */
|   |                               /*      UnloadExtension( ) */
|   |-- formats                     /* directory for FORMAT extension source */
|   |   `-- Template.c              /* Template for writing FORMAT extensions */
|   |-- graph.ddl                   /* source code for Graph (graph.dbd) DB */
|   |-- lang                        /* source code for LANG extensions */
|   |   |-- C.c                     /* C Language extension */
|   |   |                           /*   Contains:              */ 
|   |   |                           /*      ext_lang_init( ) */
|   |   |                           /*      findstr( ) */
|   |   |                           /*      makestr( ) */
|   |   `-- Template.c              /* Template for writing LANG extensions */
|   |-- macro.c                     /* Routines for accessing EiC */
|   |                               /*   Contains:              */ 
|   |                               /*      ExecMacroLine( ) */
|   |                               /*      ExecScript( ) */
|   |                               /*      InitInterpreter( ) */
|   |                               /*      LoadScript( ) */
|   |-- plugins                     /* directory for PLUGIN extension source */
|   |   `-- Template.c              /* Template for writing ARCH extensions */
|   |-- typhoon                     /* Source tree for Typhoon RDBMS */
|   |-- util.c                      /* Generic helper functions */
|   |                               /*   Contains:              */ 
|   |                               /*      istrncmp( ) */
|   |                               /*      strtoupper( ) */
|   |                               /*      endian_check( ) */
|   |                               /*      encmp_range( ) */
|   |                               /*      encmp_short( ) */
|   |                               /*      encmp_int( ) */
|   |                               /*      encpy_range( ) */
|   |                               /*      encpy_short( ) */
|   |                               /*      encpy_int( ) */
|   `-- vm.c                        /* Routines for Psuedo-VM operations */
|                                   /*   Contains:              */ 
|                                   /*      AddRegTableEntry( ) */
|                                   /*      CleanupVM( ) */
|                                   /*      InitVM( ) */
`-- utils                           /* utility programs */
    |-- bastard_api.pl              /* used for development purposes */
    |-- dbdview                     /* display the contents of a .dbd file */
    |-- ddlp                        /* utility to create .dbd, .h from .ddl */
    |-- disasm.color.sh             /* .sh performing a full disasm in color */
    |-- disasm.full.sh              /* .sh performing a full disasm */
    |-- disasm.text.sh              /* .sh disassembling a .text section */
    |-- eic                         /* command-line eic interpreter */
    |-- fix_bdb.sh                  /* used for development purposes */
	 |-- lgb                         /* Tk frontend to the bastard */
    |-- op-conv.pl                  /* used for development purposes */
    |-- tyexport                    /* export data from a Typhoon DB file */
    `-- tyimport                    /* import data to a Typhoon DB file */
