News:

Accounts with zero posts and zero activity during the last months will be deleted periodically to fight SPAM!

Main Menu

CB ignores search directories/Global variables

Started by eb, January 20, 2012, 03:02:34 AM

Previous topic - Next topic

eb

#30
D'Oh!

btw - It seems that the settings under Project->Build options trump those under Compiler and debugger settings.
Things are starting to make sense now.
Thanks again Tim S.

oBFusCATed

Yes, also you can manage if the target or project options take precedence by using the Policy combo box.

@devs:
Another patch to improve debuggability:


Index: src/plugins/compilergcc/compilergcc.cpp
===================================================================
--- src/plugins/compilergcc/compilergcc.cpp     (revision 7810)
+++ src/plugins/compilergcc/compilergcc.cpp     (working copy)
@@ -2366,9 +2366,19 @@
             ProjectBuildTarget* tgt = prj->GetBuildTarget(tlist[x]);
             if (!CompilerValid(tgt))
             {
+                Compiler *compiler = CompilerFactory::GetCompiler(GetCurrentCompilerID(tgt));
+                wxString compilerName, compilerName2(wxT("unknown"));
+                if (compiler)
+                {
+                    compilerName = wxT("(") + compiler->GetName() + wxT(") ");
+                    compilerName2 = compiler->GetName();
+                }
                 wxString msg;
-                msg.Printf(_T("\"%s - %s\": The compiler's setup is invalid so Code::Blocks cannot find/run the compiler. Probably the toolchain path within the compiler options is not setup correctly?! Skipping..."),
-                            prj->GetTitle().wx_str(), tlist[x].wx_str());
+                msg.Printf(_T("\"%s - %s\": The compiler's setup %sis invalid, so Code::Blocks cannot find/run the compiler.\n")
+                           _T("Probably the toolchain path within the compiler options is not setup correctly?!\n")
+                           _T("Goto Settings->Compiler and debugger...->Global compiler settings->%s->Toolchain executables\n")
+                           _T("Skipping..."),
+                           prj->GetTitle().wx_str(), tlist[x].wx_str(), compilerName.wx_str(), compilerName2.wx_str());
                 Manager::Get()->GetLogManager()->LogWarning(msg, m_PageIndex);
                 continue;
             }

What do you think?
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

oBFusCATed

(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Jenna


MortenMacFly

Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]