
/*----------------------------------*/
/*                                  */
/*----------------------------------*/
ULONG           main(ULONG argc, PUCHAR *argv, PUCHAR envp);
ULONG           atolx( PBYTE s, PULONG v );

/*----------------------------------*/
/*                                  */
/*----------------------------------*/
ULONG           Pass1( PMODINFO pMI );
ULONG           ExpandObject( PMODINFO pMI, POBJINFO pOI, PO32_OBJ pO32Obj );

/*----------------------------------*/
/*                                  */
/*----------------------------------*/
ULONG           Pass2( PMODINFO pMI );
ULONG           CalcTgtAddr( PFIXINFO pFI );
ULONG           TgtToSrcFmt( PFIXINFO pFI );
ULONG           ApplyFixups( PFIXINFO pFI );
POBJINFO        ObjFromIndex( PMODINFO pMI, ULONG ObjIndex );
PMODINFO        ModOrdToMI( PMODINFO pMI, ULONG ModOrd, PBYTE *pTgtProcName );
ULONG           ProcNameToOrd( PMODINFO pMI, PBYTE pProcName, PULONG pProcOrd );
ULONG           ProcOrdToAddr( PMODINFO pMI, ULONG ProcOrd, PULONG pTgtAddr );

/*----------------------------------*/
/*                                  */
/*----------------------------------*/
ULONG           OpenLXExe( PMODINFO pMI );
ULONG           OpenOutFile( PBYTE pFileName );
ULONG           ReadFileAt( FILE *hFile, ULONG FilePos, PVOID pBuf, ULONG ReadLen );
ULONG           WriteFileAt( FILE *hFile, ULONG FilePos, PVOID pBuf, ULONG WriteLen );
ULONG           errmsg( ULONG MsgId, PBYTE pSrcFile, ULONG LineNum, PBYTE pFileName );

/*----------------------------------*/
/*                                  */
/*----------------------------------*/
ULONG           EP2_32_Decompress(ULONG DataLen, ULONG PageSize, PBYTE pScrBuf, PBYTE pScrBuf2);
