diff options
author | Joerg Bornemann <joerg.bornemann@qt.io> | 2016-11-22 19:09:52 +0100 |
---|---|---|
committer | Joerg Bornemann <joerg.bornemann@qt.io> | 2016-11-23 16:19:38 +0000 |
commit | 0ab562cae6fd6b5c334714efad5eb5a2882ef2ab (patch) | |
tree | 104309fe78b51c9ffbf99bc7c2788c4d760ae2b7 /src/lib/corelib/buildgraph/depscanner.cpp | |
parent | caa0784c18b6900ea856a9f8bf1050d37964c19a (diff) | |
download | qbs-0ab562cae6fd6b5c334714efad5eb5a2882ef2ab.tar.gz |
Fix input.fileName for Scanner items
Let fileName contain the file name and filePath the file path like
everywhere else.
[ChangeLog] In Scanner items input.fileName now contains a file name,
and input.filePath contains the file path.
Change-Id: I3abc01989c56940df935047db56055936b3ab224
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'src/lib/corelib/buildgraph/depscanner.cpp')
-rw-r--r-- | src/lib/corelib/buildgraph/depscanner.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lib/corelib/buildgraph/depscanner.cpp b/src/lib/corelib/buildgraph/depscanner.cpp index dd206d158..d88759f3b 100644 --- a/src/lib/corelib/buildgraph/depscanner.cpp +++ b/src/lib/corelib/buildgraph/depscanner.cpp @@ -179,7 +179,9 @@ QStringList UserDependencyScanner::evaluate(Artifact *artifact, const ScriptFunc QScriptValue artifactConfig = m_engine->newObject(); ModuleProperties::init(artifactConfig, artifact); - artifactConfig.setProperty(QLatin1String("fileName"), artifact->filePath(), 0); + artifactConfig.setProperty(QLatin1String("fileName"), + FileInfo::fileName(artifact->filePath()), 0); + artifactConfig.setProperty(QLatin1String("filePath"), artifact->filePath(), 0); const QStringList fileTags = artifact->fileTags().toStringList(); artifactConfig.setProperty(QLatin1String("fileTags"), m_engine->toScriptValue(fileTags)); if (!m_scanner->module->name.isEmpty()) |