Skip to content

Commit d0cafb4

Browse files
author
Kjell Morgenstern
committed
Untested: make sure destination is used as a directory
1 parent 0a29e02 commit d0cafb4

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/deployers/BasicPluginsDeployer.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,13 @@ bool BasicPluginsDeployer::deployStandardQtPlugins(const std::vector<std::string
3838
{
3939
for (const auto &pluginName : plugins) {
4040
ldLog() << "Deploying Qt" << pluginName << "plugins" << std::endl;
41+
fs::path pluginSubDir = pluginName;
42+
// add a trailing slash, so it is used as a destination directory, not a file.
43+
if (pluginSubDir.has_filename()) {
44+
pluginSubDir += "/";
45+
}
4146
for (fs::directory_iterator i(qtPluginsPath / pluginName); i != fs::directory_iterator(); ++i) {
42-
if (!appDir.deployLibrary(*i, appDir.path() / "usr/plugins" / pluginName))
47+
if (!appDir.deployLibrary(*i, appDir.path() / "usr/plugins" / pluginSubDir))
4348
return false;
4449
}
4550
}

0 commit comments

Comments
 (0)