File tree Expand file tree Collapse file tree 4 files changed +56
-0
lines changed Expand file tree Collapse file tree 4 files changed +56
-0
lines changed Original file line number Diff line number Diff line change @@ -17,6 +17,7 @@ set(CLASSES
17
17
Qt3DPluginsDeployer
18
18
GamepadPluginsDeployer
19
19
PrintSupportPluginsDeployer
20
+ TextToSpeechPluginsDeployer
20
21
)
21
22
22
23
# TODO: CMake <= 3.7 (at least!) doesn't allow for using OBJECT libraries with target_link_libraries
Original file line number Diff line number Diff line change 11
11
#include " Qt3DPluginsDeployer.h"
12
12
#include " SqlPluginsDeployer.h"
13
13
#include " SvgPluginsDeployer.h"
14
+ #include " TextToSpeechPluginsDeployer.h"
14
15
#include " WebEnginePluginsDeployer.h"
15
16
#include " XcbglIntegrationPluginsDeployer.h"
16
17
@@ -79,6 +80,10 @@ std::vector<std::shared_ptr<PluginsDeployer>> PluginsDeployerFactory::getDeploye
79
80
return {getInstance<PrintSupportPluginsDeployer>(moduleName)};
80
81
}
81
82
83
+ if (moduleName == " texttospeech" ) {
84
+ return {getInstance<TextToSpeechPluginsDeployer>(moduleName)};
85
+ }
86
+
82
87
// fallback
83
88
return {getInstance<BasicPluginsDeployer>(moduleName)};
84
89
}
Original file line number Diff line number Diff line change
1
+ // library headers
2
+ #include < linuxdeploy/core/log.h>
3
+ #include < boost/filesystem.hpp>
4
+
5
+ // local headers
6
+ #include " TextToSpeechPluginsDeployer.h"
7
+
8
+ using namespace linuxdeploy ::plugin::qt;
9
+ using namespace linuxdeploy ::core::log;
10
+
11
+ namespace bf = boost::filesystem;
12
+
13
+ bool TextToSpeechPluginsDeployer::deploy () {
14
+ // calling the default code is optional, but it won't hurt for now
15
+ if (!BasicPluginsDeployer::deploy ())
16
+ return false ;
17
+
18
+ const std::string pluginsName = " texttospeech" ;
19
+
20
+ ldLog () << " Deploying" << pluginsName << " plugins" << std::endl;
21
+
22
+ for (bf::directory_iterator i (qtPluginsPath / pluginsName); i != bf::directory_iterator (); ++i) {
23
+ if (i->path ().extension () == " .debug" ) {
24
+ ldLog () << LD_DEBUG << " skipping .debug file:" << i->path () << std::endl;
25
+ continue ;
26
+ }
27
+
28
+ if (!appDir.deployLibrary (*i, appDir.path () / " usr/plugins/" / pluginsName))
29
+ return false ;
30
+ }
31
+
32
+ return true ;
33
+ }
Original file line number Diff line number Diff line change
1
+ #pragma once
2
+
3
+ #include " BasicPluginsDeployer.h"
4
+
5
+ namespace linuxdeploy {
6
+ namespace plugin {
7
+ namespace qt {
8
+ class TextToSpeechPluginsDeployer : public BasicPluginsDeployer {
9
+ public:
10
+ // we can just use the base class's constructor
11
+ using BasicPluginsDeployer::BasicPluginsDeployer;
12
+
13
+ bool deploy () override ;
14
+ };
15
+ }
16
+ }
17
+ }
You can’t perform that action at this time.
0 commit comments