Author: dgorbachev
Date: Sun Sep 13 23:18:21 2009
New Revision: 43040
URL:
http://svn.reactos.org/svn/reactos?rev=43040&view=rev
Log:
Fix GCC detection in RBuild (first check TARGET_CC).
Modified:
trunk/reactos/tools/rbuild/backend/mingw/mingw.cpp
Modified: trunk/reactos/tools/rbuild/backend/mingw/mingw.cpp
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/rbuild/backend/mingw…
==============================================================================
--- trunk/reactos/tools/rbuild/backend/mingw/mingw.cpp [iso-8859-1] (original)
+++ trunk/reactos/tools/rbuild/backend/mingw/mingw.cpp [iso-8859-1] Sun Sep 13 23:18:21
2009
@@ -740,12 +740,24 @@
if ( ProjectNode.configuration.Compiler == GnuGcc )
{
+ const string& TARGET_CCValue = Environment::GetVariable ( "TARGET_CC" );
const string& ROS_PREFIXValue = Environment::GetVariable ( "ROS_PREFIX"
);
+
if ( ROS_PREFIXValue.length () > 0 )
{
- compilerPrefix = ROS_PREFIXValue;
- compilerCommand = compilerPrefix + "-gcc";
+ compilerPrefix = "";
+ compilerCommand = TARGET_CCValue;
detectedCompiler = TryToDetectThisCompiler ( compilerCommand );
+ }
+
+ if ( !detectedCompiler )
+ {
+ if ( ROS_PREFIXValue.length () > 0 )
+ {
+ compilerPrefix = ROS_PREFIXValue;
+ compilerCommand = compilerPrefix + "-gcc";
+ detectedCompiler = TryToDetectThisCompiler ( compilerCommand );
+ }
}
#if defined(WIN32)
if ( !detectedCompiler )