forked from qt-creator/qt-creator
		
	ProjectExplorer: Improve "same file" detection for toolchains
Only use the file size heuristic on Windows, as it actually helps us filter out duplicates there. On Unix, there is no such compensation for the risk of false positives. For instance, on my Linux machine, i686-w64-mingw32-gcc and x86_64-w64- mingw32-gcc have the same file size, but they are not the same file. Change-Id: I427d2ff36a33ffb045c71851c91312e129616f69 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
		@@ -967,7 +967,8 @@ QList<ToolChain *> GccToolChainFactory::autoDetectToolchains(
 | 
			
		||||
            } else {
 | 
			
		||||
                existingTcMatches = Environment::systemEnvironment().isSameExecutable(
 | 
			
		||||
                            existingCommand.toString(), compilerPath.toString())
 | 
			
		||||
                        || existingCommand.toFileInfo().size() == compilerPath.toFileInfo().size();
 | 
			
		||||
                        || (HostOsInfo::isWindowsHost() && existingCommand.toFileInfo().size()
 | 
			
		||||
                            == compilerPath.toFileInfo().size());
 | 
			
		||||
            }
 | 
			
		||||
            if (existingTcMatches) {
 | 
			
		||||
                if (!result.contains(existingTc))
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user