started reworking linker
This commit is contained in:
@@ -94,6 +94,46 @@ public:
|
||||
virtual CUtlString Link( LinkProject_t *pProject ) = 0;
|
||||
|
||||
virtual bool IsLibraryExists( CUtlString szName ) = 0;
|
||||
|
||||
protected:
|
||||
// Link
|
||||
// Returns file name of the
|
||||
CUtlString GetOutputObjectName( LinkProject_t *pProject, unsigned int hash, CUtlString szFileName );
|
||||
|
||||
virtual CUtlVector<CUtlString> BuildLinkCommandLine( LinkProject_t *pProject, const char *szOutputFileName );
|
||||
virtual CUtlVector<CUtlString> BuildArchiveCommandLine( LinkProject_t *pProject, const char *szOutputFileName );
|
||||
|
||||
// Returns executable which should the OS run
|
||||
virtual const char *GetCompilerExecutable( LinkProject_t *pProject ) = 0;
|
||||
|
||||
// returns object file format, eg .obj or .o
|
||||
virtual const char *GetOutputObjectFormat() = 0;
|
||||
|
||||
virtual void SetTarget( CUtlVector<CUtlString> &cmd, LinkProject_t *pProject ) = 0;
|
||||
virtual void SetSysroot( CUtlVector<CUtlString> &cmd, LinkProject_t *pProject , const char *szSysroot ) = 0;
|
||||
virtual void SetOutputFile( CUtlVector<CUtlString> &cmd ) = 0;
|
||||
|
||||
|
||||
// sets rpath
|
||||
// for windows should be ignored
|
||||
virtual void SetDefaultLibraryPaths( CUtlVector<CUtlString> &cmd ) = 0;
|
||||
|
||||
virtual void UseStdLib( CUtlVector<CUtlString> &cmd, bool bUse ) = 0;
|
||||
|
||||
// windows doesn't use it as well
|
||||
virtual void UseDynamicLookup( CUtlVector<CUtlString> &cmd, bool bUse ) = 0;
|
||||
|
||||
// includes whole file
|
||||
virtual void UseFullFile( CUtlVector<CUtlString> &cmd ) = 0;
|
||||
|
||||
// includes used stuff in a file
|
||||
virtual void UsePartialFile( CUtlVector<CUtlString> &cmd ) = 0;
|
||||
|
||||
virtual void LinkFile( CUtlVector<CUtlString> &cmd, const char *szName ) = 0;
|
||||
virtual void LinkLibraryObject( CUtlVector<CUtlString> &cmd, const char *szName ) = 0;
|
||||
virtual void LinkLibrary( CUtlVector<CUtlString> &cmd, const char *szName ) = 0;
|
||||
virtual void LinkLibraryPath( CUtlVector<CUtlString> &cmd, const char *szName ) = 0;
|
||||
|
||||
};
|
||||
|
||||
extern ILinker *linker;
|
||||
|
||||
Reference in New Issue
Block a user