Changeset View
Changeset View
Standalone View
Standalone View
kde-modules/KDECMakeSettings.cmake
Show First 20 Lines • Show All 78 Lines • ▼ Show 20 Line(s) | |||||
79 | # | 79 | # | ||
80 | # ``KDE_L10N_BRANCH`` will be responsible for choosing which l10n branch to use | 80 | # ``KDE_L10N_BRANCH`` will be responsible for choosing which l10n branch to use | ||
81 | # for the translations. | 81 | # for the translations. | ||
82 | # | 82 | # | ||
83 | # ``KDE_L10N_AUTO_TRANSLATIONS`` (OFF by default) will indicate whether translations | 83 | # ``KDE_L10N_AUTO_TRANSLATIONS`` (OFF by default) will indicate whether translations | ||
84 | # should be downloaded when building the project. | 84 | # should be downloaded when building the project. | ||
85 | # | 85 | # | ||
86 | # Since 5.34.0 | 86 | # Since 5.34.0 | ||
87 | # | ||||
88 | # Flatpak builds | ||||
89 | # ~~~~~~~~~~~~~~ | ||||
90 | # If there is a ``org.kde.app.json`` flatpak recipe in the git repository, an optional | ||||
91 | # ``build-flatpak`` target will be added to automate running ``flatpak-builder`` on it. | ||||
92 | # | ||||
93 | # Don't forget to run ``flatpak update`` after you run the target. | ||||
94 | # | ||||
95 | # See https://community.kde.org/Guidelines_and_HOWTOs/Flatpak#Compile_your_application | ||||
96 | # | ||||
97 | # Since 5.38 | ||||
87 | 98 | | |||
88 | #============================================================================= | 99 | #============================================================================= | ||
89 | # Copyright 2014 Alex Merry <alex.merry@kde.org> | 100 | # Copyright 2014 Alex Merry <alex.merry@kde.org> | ||
90 | # Copyright 2013 Aleix Pol <aleixpol@kde.org> | 101 | # Copyright 2013 Aleix Pol <aleixpol@kde.org> | ||
91 | # Copyright 2012-2013 Stephen Kelly <steveire@gmail.com> | 102 | # Copyright 2012-2013 Stephen Kelly <steveire@gmail.com> | ||
92 | # Copyright 2007 Matthias Kretz <kretz@kde.org> | 103 | # Copyright 2007 Matthias Kretz <kretz@kde.org> | ||
93 | # Copyright 2006-2007 Laurent Montel <montel@kde.org> | 104 | # Copyright 2006-2007 Laurent Montel <montel@kde.org> | ||
94 | # Copyright 2006-2013 Alex Neundorf <neundorf@kde.org> | 105 | # Copyright 2006-2013 Alex Neundorf <neundorf@kde.org> | ||
▲ Show 20 Lines • Show All 242 Lines • ▼ Show 20 Line(s) | 346 | COMMAND ruby "${CMAKE_BINARY_DIR}/releaseme/fetchpo.rb" | |||
337 | --project "${_reponame}" | 348 | --project "${_reponame}" | ||
338 | --output-dir "${_l10n_po_dir}" | 349 | --output-dir "${_l10n_po_dir}" | ||
339 | --output-poqm-dir "${_l10n_poqm_dir}" | 350 | --output-poqm-dir "${_l10n_poqm_dir}" | ||
340 | "${CMAKE_CURRENT_SOURCE_DIR}" | 351 | "${CMAKE_CURRENT_SOURCE_DIR}" | ||
341 | ${extra} | 352 | ${extra} | ||
342 | DEPENDS "${CMAKE_BINARY_DIR}/releaseme" | 353 | DEPENDS "${CMAKE_BINARY_DIR}/releaseme" | ||
343 | ) | 354 | ) | ||
344 | endif() | 355 | endif() | ||
356 | | ||||
357 | ################################################################### | ||||
358 | # Build flatpak recipe | ||||
359 | | ||||
360 | function(_find_json_recipe json_recipe) | ||||
361 | execute_process(COMMAND git ls-files *org.kde.*.json | ||||
krop: find_package(Git)
if(Git_FOUND)
execute_process(COMMAND GIT_EXECUTABLE...
else()
print some… | |||||
362 | OUTPUT_VARIABLE json | ||||
363 | WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}") | ||||
364 | | ||||
365 | set(${json_recipe} ${json}) | ||||
366 | set(${json_recipe} ${${json_recipe}} PARENT_SCOPE) | ||||
367 | endfunction() | ||||
368 | | ||||
369 | if(NOT TARGET build-flatpak) | ||||
370 | set(_json_recipe "") | ||||
371 | _find_json_recipe(_json_recipe) | ||||
372 | if(_json_recipe) | ||||
373 | string(TIMESTAMP _build_date) | ||||
374 | add_custom_target(build-flatpak | ||||
375 | COMMENT "Building flatpak recipe: ${_json_recipe}..." | ||||
376 | COMMAND flatpak-builder --force-clean --ccache --require-changes --repo=repo --subject="Build of ${PROJECT_NAME}, ${_build_date}" app ${CMAKE_SOURCE_DIR}/${_json_recipe}) | ||||
377 | endif() | ||||
378 | endif() |
find_package(Git)
if(Git_FOUND)
execute_process(COMMAND GIT_EXECUTABLE...
else()
print some message