Code::Blocks
SVN r11506
|
#include <directcommands.h>
Public Attributes | |
bool | m_doYield |
Protected Member Functions | |
bool | AreExternalDepsOutdated (ProjectBuildTarget *target, const wxString &buildOutput, wxArrayString *filesMissing) const |
external deps are manually set by the user e.g. More... | |
bool | IsObjectOutdated (ProjectBuildTarget *target, const pfDetails &pfd, wxString *errorStr=0) const |
void | DepsSearchStart (ProjectBuildTarget *target) const |
MyFilesArray | GetProjectFilesSortedByWeight (ProjectBuildTarget *target, bool compile, bool link) const |
void | AddCommandsToArray (const wxString &cmds, wxArrayString &array, bool isWaitCmd=false, bool isLinkCmd=false) const |
Protected Attributes | |
int | m_PageIndex |
CompilerGCC * | m_pCompilerPlugin |
Compiler * | m_pCompiler |
cbProject * | m_pProject |
CompilerCommandGenerator * | m_pGenerator |
Private Member Functions | |
DirectCommands (DirectCommands &) | |
DirectCommands & | operator= (DirectCommands &) |
Definition at line 31 of file directcommands.h.
|
private |
DirectCommands::DirectCommands | ( | CompilerGCC * | compilerPlugin, |
Compiler * | compiler, | ||
cbProject * | project, | ||
int | logPageIndex = 0 |
||
) |
Definition at line 45 of file directcommands.cpp.
References _(), _T, wxFileName::Assign(), LogManager::DebugLog(), F(), Manager::Get(), CompileTargetBase::GetBasePath(), wxString::GetChar(), Compiler::GetCommandGenerator(), CompileTargetBase::GetFilename(), Manager::GetLogManager(), wxFileName::GetPath(), wxString::Len(), m_pCompiler, m_pGenerator, m_pProject, wxString::mb_str(), wxString::RemoveLast(), wxFileName::SetExt(), and wxString::wx_str().
DirectCommands::~DirectCommands | ( | ) |
Definition at line 85 of file directcommands.cpp.
References _(), _T, LogManager::DebugLog(), F(), Manager::Get(), CompileTargetBase::GetFilename(), Manager::GetLogManager(), m_pGenerator, m_pProject, and wxFileName::SetExt().
|
protected |
Definition at line 108 of file directcommands.cpp.
References _T, wxArrayString::Add(), COMPILER_WAIT, COMPILER_WAIT_LINK, wxString::Find(), wxString::IsEmpty(), wxString::Left(), wxString::Remove(), and wxString::Trim().
Referenced by GetCompileFileCommand(), GetCompileSingleFileCommand(), and GetTargetLinkCommands().
|
protected |
external deps are manually set by the user e.g.
a static library linked to the project is an external dep (if set as such by the user) so that a re-linking is forced if the static lib is updated
Definition at line 928 of file directcommands.cpp.
References _T, wxArrayString::Add(), AppendArray(), wxString::Contains(), LogManager::DebugLog(), wxString::EndsWith(), F(), Manager::Get(), ProjectBuildTarget::GetAdditionalOutputFiles(), GetArrayFromString(), CompilerFactory::GetCompiler(), CompileTargetBase::GetCompilerID(), wxArrayString::GetCount(), ProjectBuildTarget::GetExternalDeps(), CompileOptionsBase::GetLibDirs(), CompileOptionsBase::GetLinkLibs(), Manager::GetLogManager(), Manager::GetMacrosManager(), ProjectBuildTarget::GetParentProject(), Compiler::GetSwitches(), CompileTargetBase::GetTitle(), wxString::IsEmpty(), CompilerSwitches::libExtension, CompilerSwitches::libPrefix, wxString::mb_str(), MacrosManager::ReplaceMacros(), wxString::StartsWith(), UnixFilename(), and wxString::wx_str().
Referenced by GetTargetLinkCommands().
wxArrayString DirectCommands::CompileFile | ( | ProjectBuildTarget * | target, |
ProjectFile * | pf, | ||
bool | force = false |
||
) | const |
Definition at line 159 of file directcommands.cpp.
References _(), wxArrayString::Add(), AppendArray(), ProjectFile::compile, COMPILER_TARGET_CHANGE, COMPILER_WARNING_LOG, ProjectFile::compilerVar, LogManager::DebugLog(), DepsSearchStart(), Manager::Get(), ProjectFile::GetBuildTargets(), GetCompileFileCommand(), ProjectFile::GetFileDetails(), Manager::GetLogManager(), CompileTargetBase::GetTitle(), wxArrayString::Index(), wxString::IsEmpty(), IsObjectOutdated(), and wxNOT_FOUND.
Referenced by CompilerGCC::CompileFileDefault().
|
protected |
Definition at line 1124 of file directcommands.cpp.
References Manager::Get(), CompilerCommandGenerator::GetCompilerSearchDirs(), wxArrayString::GetCount(), Manager::GetMacrosManager(), m_pGenerator, and MacrosManager::ReplaceMacros().
Referenced by CompileFile(), and GetTargetCompileCommands().
wxArrayString DirectCommands::GetCleanCommands | ( | ProjectBuildTarget * | target, |
bool | distclean = false |
||
) | const |
Definition at line 858 of file directcommands.cpp.
References AppendArray(), cbProject::GetBuildTarget(), cbProject::GetBuildTargetsCount(), GetTargetCleanCommands(), and m_pProject.
Referenced by CompilerGCC::BuildStateManagement().
wxArrayString DirectCommands::GetCleanSingleFileCommand | ( | const wxString & | filename | ) | const |
This is to be used only for files not belonging to a project!!!
Definition at line 429 of file directcommands.cpp.
References wxArrayString::Add(), FileFilters::EXECUTABLE_EXT, FileTypeOf(), ftSource, wxFileName::GetFullPath(), Compiler::GetSwitches(), m_pCompiler, CompilerSwitches::objectExtension, and wxFileName::SetExt().
wxArrayString DirectCommands::GetCompileCommands | ( | ProjectBuildTarget * | target, |
bool | force = false |
||
) | const |
Definition at line 452 of file directcommands.cpp.
References AppendArray(), cbProject::GetBuildTarget(), cbProject::GetBuildTargetsCount(), ProjectBuildTarget::GetIncludeInTargetAll(), GetTargetCompileCommands(), and m_pProject.
Referenced by CompilerGCC::BuildStateManagement().
wxArrayString DirectCommands::GetCompileFileCommand | ( | ProjectBuildTarget * | target, |
ProjectFile * | pf | ||
) | const |
Definition at line 194 of file directcommands.cpp.
References _(), _T, wxArrayString::Add(), AddCommandsToArray(), AppendArray(), pfCustomBuild::buildCommand, clogFull, clogNone, clogSimple, CompilerTool::command, ProjectFile::compile, COMPILER_SIMPLE_LOG, COMPILER_WAIT, ProjectFile::compilerVar, CreateDirRecursively(), ctCompileObjectCmd, ctCompileResourceCmd, ProjectFile::customBuild, LogManager::DebugLog(), pfDetails::dep_file, F(), ProjectFile::file, FileTypeOf(), ftHeader, ftResource, CompilerCommandGenerator::GenerateCommandLine(), ProjectFile::generatedFiles, Manager::Get(), CompilerFactory::GetCompiler(), CompileTargetBase::GetCompilerID(), Compiler::GetCompilerTool(), wxArrayString::GetCount(), wxFileName::GetExt(), ProjectFile::GetFileDetails(), Compiler::GetID(), Manager::GetLogManager(), wxFileName::GetShortPath(), Compiler::GetSwitches(), wxString::IsEmpty(), CompilerSwitches::logging, m_pCompiler, m_pGenerator, pfDetails::object_dir_flat_native, pfDetails::object_dir_native, pfDetails::object_file, pfDetails::object_file_absolute_native, pfDetails::object_file_flat, pfDetails::object_file_flat_absolute_native, QuoteStringIfNeeded(), ProjectFile::relativeFilename, pfDetails::source_file, pfDetails::source_file_absolute_native, pfDetails::source_file_native, CompilerSwitches::supportsPCH, UnixFilename(), pfCustomBuild::useCustomBuildCommand, CompilerSwitches::UseFlatObjects, CompilerSwitches::UseFullSourcePaths, wxString::wx_str(), wxEmptyString, and wxRemoveFile().
Referenced by CompileFile(), and GetTargetCompileCommands().
wxArrayString DirectCommands::GetCompileSingleFileCommand | ( | const wxString & | filename | ) | const |
This is to be used only for files not belonging to a project!!!
Definition at line 340 of file directcommands.cpp.
References _(), _T, wxArrayString::Add(), AddCommandsToArray(), cbThrow, clogFull, clogNone, clogSimple, COMPILER_SIMPLE_LOG, ctCompileObjectCmd, ctLinkConsoleExeCmd, FileFilters::EXECUTABLE_EXT, FileTypeOf(), ftSource, CompilerCommandGenerator::GenerateCommandLine(), Compiler::GetCommand(), CompilerFactory::GetDefaultCompiler(), wxFileName::GetExt(), wxFileName::GetFullPath(), Compiler::GetSwitches(), wxString::IsEmpty(), CompilerSwitches::logging, m_pCompiler, m_pGenerator, CompilerSwitches::objectExtension, QuoteStringIfNeeded(), wxFileName::SetExt(), and wxEmptyString.
Referenced by CompilerGCC::CompileFileWithoutProject().
wxArrayString DirectCommands::GetLinkCommands | ( | ProjectBuildTarget * | target, |
bool | force = false |
||
) | const |
Definition at line 600 of file directcommands.cpp.
References AppendArray(), cbProject::GetBuildTarget(), cbProject::GetBuildTargetsCount(), ProjectBuildTarget::GetIncludeInTargetAll(), GetTargetLinkCommands(), and m_pProject.
Referenced by GetTargetCompileCommands().
wxArrayString DirectCommands::GetPostBuildCommands | ( | ProjectBuildTarget * | target | ) | const |
Definition at line 561 of file directcommands.cpp.
References _(), wxArrayString::Add(), COMPILER_SIMPLE_LOG, COMPILER_WAIT, CompilerCommandGenerator::GenerateCommandLine(), CompileOptionsBase::GetCommandsAfterBuild(), CompilerFactory::GetCompiler(), CompileTargetBase::GetCompilerID(), cbProject::GetCurrentlyCompilingTarget(), CompileTargetBase::GetTitle(), wxArrayString::Insert(), m_doYield, m_pCompiler, m_pGenerator, m_pProject, wxEmptyString, and Manager::Yield().
Referenced by CompilerGCC::BuildStateManagement(), and GetTargetLinkCommands().
wxArrayString DirectCommands::GetPreBuildCommands | ( | ProjectBuildTarget * | target | ) | const |
Definition at line 528 of file directcommands.cpp.
References _(), wxArrayString::Add(), COMPILER_SIMPLE_LOG, COMPILER_WAIT, CompilerCommandGenerator::GenerateCommandLine(), CompileOptionsBase::GetCommandsBeforeBuild(), CompilerFactory::GetCompiler(), CompileTargetBase::GetCompilerID(), cbProject::GetCurrentlyCompilingTarget(), CompileTargetBase::GetTitle(), wxArrayString::Insert(), m_doYield, m_pCompiler, m_pGenerator, m_pProject, wxEmptyString, and Manager::Yield().
Referenced by CompilerGCC::BuildStateManagement().
|
protected |
Definition at line 138 of file directcommands.cpp.
References ProjectFile::buildTargets, ProjectFile::compile, cbProject::GetFilesList(), CompileTargetBase::GetTitle(), wxArrayString::Index(), ProjectFile::link, m_pProject, MySortProjectFilesByWeight(), and wxNOT_FOUND.
Referenced by GetTargetCleanCommands(), GetTargetCompileCommands(), and GetTargetLinkCommands().
wxArrayString DirectCommands::GetTargetCleanCommands | ( | ProjectBuildTarget * | target, |
bool | distclean = false |
||
) | const |
Definition at line 876 of file directcommands.cpp.
References wxArrayString::Add(), ProjectFile::AutoGeneratedBy(), pfDetails::dep_file_absolute_native, ProjectFile::file, Manager::Get(), CompilerFactory::GetCompiler(), CompileTargetBase::GetCompilerID(), ProjectFile::GetFileDetails(), wxFileName::GetFullPath(), Manager::GetMacrosManager(), CompileTargetBase::GetOutputFilename(), GetProjectFilesSortedByWeight(), CompileTargetBase::GetStaticLibFilename(), Compiler::GetSwitches(), CompileTargetBase::GetTargetType(), m_pCompiler, pfDetails::object_file_absolute_native, pfDetails::object_file_flat_absolute_native, MacrosManager::ReplaceMacros(), ttCommandsOnly, ttDynamicLib, and CompilerSwitches::UseFlatObjects.
Referenced by GetCleanCommands().
wxArrayString DirectCommands::GetTargetCompileCommands | ( | ProjectBuildTarget * | target, |
bool | force = false |
||
) | const |
Definition at line 473 of file directcommands.cpp.
References wxArrayString::Add(), AppendArray(), ProjectFile::AutoGeneratedBy(), COMPILER_WAIT, COMPILER_WARNING_LOG, DepsSearchStart(), GetCompileFileCommand(), wxArrayString::GetCount(), ProjectFile::GetFileDetails(), GetLinkCommands(), GetProjectFilesSortedByWeight(), wxArrayString::IsEmpty(), wxString::IsEmpty(), IsObjectOutdated(), wxArrayString::Last(), m_doYield, ProjectFile::weight, and Manager::Yield().
Referenced by GetCompileCommands().
wxArrayString DirectCommands::GetTargetLinkCommands | ( | ProjectBuildTarget * | target, |
bool | force = false |
||
) | const |
Definition at line 621 of file directcommands.cpp.
References _(), _T, wxArrayString::Add(), AddCommandsToArray(), AppendArray(), AreExternalDepsOutdated(), cbMessageBox(), cbThrow, wxArrayString::Clear(), clogFull, clogNone, clogSimple, COMPILER_NOTE_LOG, COMPILER_SIMPLE_LOG, COMPILER_TARGET_CHANGE, COMPILER_WARNING_LOG, CreateDirRecursively(), ctCount, ctLinkConsoleExeCmd, ctLinkDynamicCmd, ctLinkExeCmd, ctLinkNativeCmd, ctLinkStaticCmd, FileTypeOf(), ftResource, CompilerCommandGenerator::GenerateCommandLine(), Manager::Get(), CompileTargetBase::GetBasePath(), Compiler::GetCommand(), CompilerFactory::GetCompiler(), CompileTargetBase::GetCompilerID(), wxArrayString::GetCount(), ProjectFile::GetFileDetails(), wxFileName::GetFullPath(), ProjectBuildTarget::GetFullTitle(), Manager::GetMacrosManager(), wxRegEx::GetMatch(), CompileTargetBase::GetOutputFilename(), wxFileName::GetPath(), GetPostBuildCommands(), GetProjectFilesSortedByWeight(), Compiler::GetSwitches(), CompileTargetBase::GetTargetType(), CompileTargetBase::GetTitle(), wxArrayString::IsEmpty(), wxString::IsEmpty(), wxString::IsSameAs(), CompilerSwitches::logging, m_pCompiler, m_pGenerator, m_pProject, wxFileName::MakeAbsolute(), wxRegEx::Matches(), wxString::mb_str(), pfDetails::object_file, pfDetails::object_file_flat, pfDetails::object_file_native, CompilerSwitches::objectSeparator, wxString::Printf(), ProjectFile::relativeFilename, MacrosManager::ReplaceMacros(), wxString::Trim(), ttCommandsOnly, ttConsoleOnly, ttDynamicLib, ttExecutable, ttNative, ttStaticLib, UnixFilename(), CompilerSwitches::UseFlatObjects, wxString::wx_str(), wxEmptyString, and wxT.
Referenced by GetLinkCommands().
|
protected |
Definition at line 1069 of file directcommands.cpp.
References _(), _T, Manager::Get(), CompilerFactory::GetCompiler(), CompileTargetBase::GetCompilerID(), Manager::GetConfigManager(), Compiler::GetSwitches(), m_pCompiler, wxString::mb_str(), pfDetails::object_file_absolute_native, pfDetails::object_file_flat_absolute_native, ConfigManager::ReadBool(), ParserConsts::ref, pfDetails::source_file_absolute_native, CompilerSwitches::UseFlatObjects, and wxFileExists().
Referenced by CompileFile(), and GetTargetCompileCommands().
|
private |
bool DirectCommands::m_doYield |
Definition at line 55 of file directcommands.h.
Referenced by CompilerGCC::BuildStateManagement(), GetPostBuildCommands(), GetPreBuildCommands(), and GetTargetCompileCommands().
|
protected |
Definition at line 63 of file directcommands.h.
|
protected |
Definition at line 65 of file directcommands.h.
Referenced by DirectCommands(), GetCleanSingleFileCommand(), GetCompileFileCommand(), GetCompileSingleFileCommand(), GetPostBuildCommands(), GetPreBuildCommands(), GetTargetCleanCommands(), GetTargetLinkCommands(), and IsObjectOutdated().
|
protected |
Definition at line 64 of file directcommands.h.
|
protected |
Definition at line 67 of file directcommands.h.
Referenced by DepsSearchStart(), DirectCommands(), GetCompileFileCommand(), GetCompileSingleFileCommand(), GetPostBuildCommands(), GetPreBuildCommands(), GetTargetLinkCommands(), and ~DirectCommands().
|
protected |
Definition at line 66 of file directcommands.h.
Referenced by DirectCommands(), GetCleanCommands(), GetCompileCommands(), GetLinkCommands(), GetPostBuildCommands(), GetPreBuildCommands(), GetProjectFilesSortedByWeight(), GetTargetLinkCommands(), and ~DirectCommands().