| 120 | } |
| 121 | |
| 122 | static Path flatpakBuildDirPath(const IProject* project, const QString& arch) |
| 123 | { |
| 124 | // TODO: Should we offer building a runtime if it's outside a project? |
| 125 | if (!project || !project->path().isLocalFile()) { |
| 126 | qCWarning(FLATPAK) << "Cannot create the flatpak-builder directory for" << project << arch; |
| 127 | return {}; |
| 128 | } |
| 129 | |
| 130 | auto ret = project->path(); |
| 131 | ret.addPath(QStringLiteral(".kdev4")); |
| 132 | ret.addPath(QStringLiteral("flatpak")); |
| 133 | ret.addPath(arch); |
| 134 | if (!QDir().mkpath(ret.toLocalFile())) { |
| 135 | qCWarning(FLATPAK) << "Cannot create path" << ret; |
| 136 | return {}; |
| 137 | } |
| 138 | return ret; |
| 139 | } |
| 140 | |
| 141 | void FlatpakPlugin::createRuntime(const KDevelop::Path &file, const QString &arch) |
| 142 | { |
no test coverage detected