Code::Blocks
SVN r11506
|
#include <compilerLCC.h>
Public Member Functions | |
CompilerLCC () | |
virtual | ~CompilerLCC () |
virtual bool | IsValid () |
Check if the compiler is actually valid (installed). More... | |
virtual void | Reset () |
Reset settings to defaults. More... | |
virtual AutoDetectResult | AutoDetectInstallationDir () |
Try to auto-detect the compiler's installation directory. More... | |
Public Member Functions inherited from Compiler | |
Compiler (const wxString &name, const wxString &ID, const wxString &parentID=wxEmptyString, int weight=50) | |
~Compiler () override | |
virtual CompilerLineType | CheckForWarningsAndErrors (const wxString &line) |
Check if the supplied string is a compiler warning/error. More... | |
virtual wxString | GetLastErrorFilename () |
Returns warning/error filename. More... | |
virtual wxString | GetLastErrorLine () |
Returns warning/error line number (as a string). More... | |
virtual wxString | GetLastError () |
Returns warning/error actual string. More... | |
virtual const wxString & | GetName () const |
Get the compiler's name. More... | |
virtual const wxString & | GetMasterPath () const |
Get the compiler's master path (must contain "bin", "include" and "lib") More... | |
virtual const wxArrayString & | GetExtraPaths () const |
Get the compiler's extra paths. More... | |
virtual const CompilerPrograms & | GetPrograms () const |
Get the compiler's programs. More... | |
virtual const CompilerSwitches & | GetSwitches () const |
Get the compiler's generic switches. More... | |
virtual const CompilerOptions & | GetOptions () const |
Get the compiler's options. More... | |
virtual const wxString & | GetCommand (CommandType ct, const wxString &fileExtension=wxEmptyString) const |
Get a command based on CommandType. More... | |
virtual const CompilerTool * | GetCompilerTool (CommandType ct, const wxString &fileExtension=wxEmptyString) const |
Get a compiler tool based on CommandType. More... | |
virtual CompilerToolsVector & | GetCommandToolsVector (CommandType ct) |
Get a command tool vector based on CommandType (used by advanced compiler dialog) More... | |
virtual const RegExArray & | GetRegExArray () |
Get the array of regexes used in errors/warnings recognition. More... | |
virtual void | LoadDefaultRegExArray (bool globalPrecedence=false) |
Load the default (preset) array of regexes used in errors/warnings recognition. More... | |
virtual void | SetName (const wxString &name) |
Set the compiler's name. More... | |
virtual void | SetMasterPath (const wxString &path) |
Set the compiler's master path (must contain "bin", "include" and "lib") More... | |
virtual void | SetExtraPaths (const wxArrayString &paths) |
Set the compiler's extra paths. More... | |
virtual void | SetPrograms (const CompilerPrograms &programs) |
Set the compiler's programs. More... | |
virtual void | SetSwitches (const CompilerSwitches &switches) |
Set the compiler's generic switches. More... | |
virtual void | SetOptions (const CompilerOptions &options) |
Set the compiler's options. More... | |
virtual void | SetRegExArray (const RegExArray ®exes) |
Set the array of regexes used in errors/warnings recognition. More... | |
virtual void | SaveSettings (const wxString &baseKey) |
Save settings. More... | |
virtual void | LoadSettings (const wxString &baseKey) |
Load settings. More... | |
virtual void | ReloadOptions () |
Reload option flags (for copied compilers). More... | |
const wxString & | GetID () const |
Get this compiler's unique ID. More... | |
const wxString & | GetParentID () const |
Get this compiler's parent's unique ID. More... | |
virtual void | SetVersionString () |
Set the compiler version string. More... | |
const wxString | GetVersionString () const |
Get the compiler version string. More... | |
virtual CompilerCommandGenerator * | GetCommandGenerator (cbProject *project) |
This is to be overridden, if compiler needs to alter the default command line generation. More... | |
void | SetCOnlyFlags (const wxString &flags) |
void | SetCPPOnlyFlags (const wxString &flags) |
const wxString & | GetCOnlyFlags () |
const wxString & | GetCPPOnlyFlags () |
bool | WithMultiLineMsg () |
Do compiler writes multi-line messages? More... | |
wxString | MakeInvalidCompilerMessages () const |
Returns messages which might be useful to the use for debugging why the compiler is invalid. More... | |
Public Member Functions inherited from CompileOptionsBase | |
CompileOptionsBase () | |
virtual | ~CompileOptionsBase () |
virtual void | AddPlatform (int platform) |
virtual void | RemovePlatform (int platform) |
virtual void | SetPlatforms (int platforms) |
virtual int | GetPlatforms () const |
virtual bool | SupportsCurrentPlatform () const |
virtual void | SetLinkerOptions (const wxArrayString &linkerOpts) |
virtual const wxArrayString & | GetLinkerOptions () const |
virtual void | AddLinkerOption (const wxString &option) |
virtual void | ReplaceLinkerOption (const wxString &option, const wxString &new_option) |
virtual void | RemoveLinkerOption (const wxString &option) |
virtual void | SetLinkLibs (const wxArrayString &linkLibs) |
virtual const wxArrayString & | GetLinkLibs () const |
virtual void | AddLinkLib (const wxString &option) |
virtual void | ReplaceLinkLib (const wxString &option, const wxString &new_option) |
virtual void | RemoveLinkLib (const wxString &option) |
virtual void | SetCompilerOptions (const wxArrayString &compilerOpts) |
virtual const wxArrayString & | GetCompilerOptions () const |
virtual void | AddCompilerOption (const wxString &option) |
virtual void | ReplaceCompilerOption (const wxString &option, const wxString &new_option) |
virtual void | RemoveCompilerOption (const wxString &option) |
virtual void | SetResourceCompilerOptions (const wxArrayString &resourceCompilerOpts) |
virtual const wxArrayString & | GetResourceCompilerOptions () const |
virtual void | AddResourceCompilerOption (const wxString &option) |
virtual void | ReplaceResourceCompilerOption (const wxString &option, const wxString &new_option) |
virtual void | RemoveResourceCompilerOption (const wxString &option) |
virtual void | SetIncludeDirs (const wxArrayString &includeDirs) |
virtual const wxArrayString & | GetIncludeDirs () const |
virtual void | AddIncludeDir (const wxString &option) |
virtual void | ReplaceIncludeDir (const wxString &option, const wxString &new_option) |
virtual void | RemoveIncludeDir (const wxString &option) |
virtual void | SetResourceIncludeDirs (const wxArrayString &resIncludeDirs) |
virtual const wxArrayString & | GetResourceIncludeDirs () const |
virtual void | AddResourceIncludeDir (const wxString &option) |
virtual void | ReplaceResourceIncludeDir (const wxString &option, const wxString &new_option) |
virtual void | RemoveResourceIncludeDir (const wxString &option) |
virtual void | SetLibDirs (const wxArrayString &libDirs) |
virtual const wxArrayString & | GetLibDirs () const |
virtual void | AddLibDir (const wxString &option) |
virtual void | ReplaceLibDir (const wxString &option, const wxString &new_option) |
virtual void | RemoveLibDir (const wxString &option) |
virtual void | SetCommandsBeforeBuild (const wxArrayString &commands) |
virtual const wxArrayString & | GetCommandsBeforeBuild () const |
virtual void | AddCommandsBeforeBuild (const wxString &command) |
virtual void | RemoveCommandsBeforeBuild (const wxString &command) |
virtual void | SetCommandsAfterBuild (const wxArrayString &commands) |
virtual const wxArrayString & | GetCommandsAfterBuild () const |
virtual void | AddCommandsAfterBuild (const wxString &command) |
virtual void | RemoveCommandsAfterBuild (const wxString &command) |
virtual void | SetBuildScripts (const wxArrayString &scripts) |
virtual const wxArrayString & | GetBuildScripts () const |
virtual void | AddBuildScript (const wxString &script) |
virtual void | RemoveBuildScript (const wxString &script) |
virtual bool | GetModified () const |
virtual void | SetModified (bool modified) |
virtual bool | GetAlwaysRunPostBuildSteps () const |
virtual void | SetAlwaysRunPostBuildSteps (bool always) |
virtual bool | SetVar (const wxString &key, const wxString &value, bool onlyIfExists=false) |
virtual bool | UnsetVar (const wxString &key) |
virtual void | UnsetAllVars () |
virtual bool | HasVar (const wxString &key) const |
virtual const wxString & | GetVar (const wxString &key) const |
virtual const StringHash & | GetAllVars () const |
Protected Member Functions | |
virtual Compiler * | CreateCopy () |
Implement this in new compilers, to return a new copy. More... | |
Protected Member Functions inherited from Compiler | |
Compiler (const Compiler &other) | |
bool | IsUniqueID (const wxString &ID) |
void | MakeValidID () |
void | LoadDefaultOptions (const wxString &name, int recursion=0) |
void | LoadRegExArray (const wxString &name, bool globalPrecedence=false, int recursion=0) |
bool | EvalXMLCondition (const wxXmlNode *node) |
wxString | GetExecName (const wxString &name) |
void | MirrorCurrentSettings () |
Private Attributes | |
bool | m_RegistryUpdated |
Definition at line 6 of file compilerLCC.h.
CompilerLCC::CompilerLCC | ( | ) |
Definition at line 24 of file compilerLCC.cpp.
References _T, Compiler::m_Weight, and Reset().
Referenced by CreateCopy().
|
virtual |
Definition at line 32 of file compilerLCC.cpp.
|
virtual |
Try to auto-detect the compiler's installation directory.
Implements Compiler.
Definition at line 58 of file compilerLCC.cpp.
References _T, wxArrayString::Add(), CompileOptionsBase::AddIncludeDir(), CompileOptionsBase::AddLibDir(), adrDetected, adrGuessed, CompilerPrograms::C, wxString::EndsWith(), wxRegKey::Exists(), wxString::IsEmpty(), wxString::Length(), wxString::Lower(), Compiler::m_ExtraPaths, Compiler::m_MasterPath, Compiler::m_Programs, m_RegistryUpdated, wxRegKey::Open(), wxRegKey::QueryValue(), wxRegKey::Read, wxString::Remove(), wxRegKey::SetName(), wxEmptyString, and wxFileExists().
|
protectedvirtual |
Implement this in new compilers, to return a new copy.
Implements Compiler.
Definition at line 37 of file compilerLCC.cpp.
References CompilerLCC().
|
virtual |
Check if the compiler is actually valid (installed).
Reimplemented from Compiler.
Definition at line 150 of file compilerLCC.cpp.
References _T, CompilerPrograms::C, wxRegKey::Create(), LogManager::DebugLog(), wxRegKey::Exists(), Manager::Get(), Manager::GetLogManager(), Compiler::IsValid(), Compiler::m_MasterPath, Compiler::m_Programs, m_RegistryUpdated, wxRegKey::SetName(), wxRegKey::SetValue(), and wxFileExists().
|
virtual |
Reset settings to defaults.
Put initialization code here or leave blank for standard XML loading. Call this from the default constructor.
Reimplemented from Compiler.
Definition at line 42 of file compilerLCC.cpp.
References wxArrayString::Clear(), CompilerOptions::ClearOptions(), Compiler::GetID(), Compiler::LoadDefaultOptions(), Compiler::LoadDefaultRegExArray(), CompileOptionsBase::m_CmdsAfter, CompileOptionsBase::m_CmdsBefore, CompileOptionsBase::m_CompilerOptions, CompileOptionsBase::m_LinkerOptions, CompileOptionsBase::m_LinkLibs, Compiler::m_Options, and m_RegistryUpdated.
Referenced by CompilerLCC().
|
private |
Definition at line 19 of file compilerLCC.h.
Referenced by AutoDetectInstallationDir(), IsValid(), and Reset().