forked from qt-creator/qt-creator
CompilationDatabaseProjectManager: Fix flags extraction
The code would blindly remove all "options" starting with /, which meant that all file paths arguments got lost on Unix-like hosts. Fixes: QTCREATORBUG-22949 Change-Id: I43e2b1e57ed0e9ced9da8fa46d98d9ac25f83d13 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -206,7 +206,7 @@ void filteredFlags(const QString &fileName,
|
||||
}
|
||||
|
||||
// Skip all remaining Windows flags except feature flags.
|
||||
if (flag.startsWith("/") && !flag.startsWith("/Z"))
|
||||
if (Utils::HostOsInfo::isWindowsHost() && flag.startsWith("/") && !flag.startsWith("/Z"))
|
||||
continue;
|
||||
|
||||
filtered.push_back(flag);
|
||||
|
||||
Reference in New Issue
Block a user