Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update appstream metainfo #3423

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .ci/flatpak/generate_flatpak_config.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ cmake_minimum_required(VERSION 3.5...3.24)
# Automatically generate a Flatpak manifest from the template file
#
# Required input defines:
# - TEMPLATE_FILE: the full filename + path for the input net.wz2100.warzone2100.appdata.xml.in template file
# - OUTPUT_FILE: the full filename + path for the output net.wz2100.warzone2100.appdata.xml file
# - TEMPLATE_FILE: the full filename + path for the input net.wz2100.wz2100.yaml.in template file
# - OUTPUT_FILE: the full filename + path for the output net.wz2100.wz2100.yaml file
# - PROJECT_ROOT: the path the project root (${PROJECT_SOURCE_DIR})
#
# And also, these input defines:
Expand Down
2 changes: 1 addition & 1 deletion .snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ parts:
parse-info:
# Parse this appdata/metainfo file for summary, description,
# and icon. Use the installed path relative to the Snap's root
- usr/share/metainfo/net.wz2100.warzone2100.appdata.xml
- usr/share/metainfo/net.wz2100.warzone2100.metainfo.xml
override-pull: |
craftctl default
SNAP_VERSION_DESC=$(git describe --always | sed 's/[^a-zA-Z0-9\.\:\+\~\-]/~/g')
Expand Down
18 changes: 9 additions & 9 deletions icons/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,26 +6,26 @@ if(UNIX AND NOT APPLE AND NOT WIN32)
endif()

############################
# Generate appdata.xml (w/ autorevision)
# Generate metainfo.xml (w/ autorevision)

# IMPORTANT: Must set GENERATED property at this directory level for autorevision.h
set_source_files_properties("${wz2100_autorevision_cache_file}" PROPERTIES GENERATED TRUE)
set_source_files_properties("${wz2100_autorevision_h_file}" PROPERTIES GENERATED TRUE)

# Generate the appdata.xml info (with version info)
set(_appdata_xml_template_file "${CMAKE_CURRENT_SOURCE_DIR}/net.wz2100.warzone2100.appdata.xml.in")
set(_appdata_xml_output_file "${CMAKE_CURRENT_BINARY_DIR}/${WZ_APPSTREAM_ID}${WZ_OUTPUT_NAME_SUFFIX}.appdata.xml")
# Generate the metainfo.xml info (with version info)
set(_metainfo_xml_template_file "${CMAKE_CURRENT_SOURCE_DIR}/net.wz2100.warzone2100.metainfo.xml.in")
set(_metainfo_xml_output_file "${CMAKE_CURRENT_BINARY_DIR}/${WZ_APPSTREAM_ID}${WZ_OUTPUT_NAME_SUFFIX}.metainfo.xml")
add_custom_command(
OUTPUT "${_appdata_xml_output_file}"
COMMAND ${CMAKE_COMMAND} -DCACHEFILE=${wz2100_autorevision_cache_file} -DPROJECT_ROOT=${PROJECT_SOURCE_DIR} -DTEMPLATE_FILE=${_appdata_xml_template_file} -DOUTPUT_FILE=${_appdata_xml_output_file} -DWZ_OUTPUT_NAME_SUFFIX=${WZ_OUTPUT_NAME_SUFFIX} -DWZ_NAME_SUFFIX=${WZ_NAME_SUFFIX} -DWZ_APPSTREAM_ID=${WZ_APPSTREAM_ID} -P ${CMAKE_CURRENT_SOURCE_DIR}/autorevision_metainfo.cmake
OUTPUT "${_metainfo_xml_output_file}"
COMMAND ${CMAKE_COMMAND} -DCACHEFILE=${wz2100_autorevision_cache_file} -DPROJECT_ROOT=${PROJECT_SOURCE_DIR} -DTEMPLATE_FILE=${_metainfo_xml_template_file} -DOUTPUT_FILE=${_metainfo_xml_output_file} -DWZ_OUTPUT_NAME_SUFFIX=${WZ_OUTPUT_NAME_SUFFIX} -DWZ_NAME_SUFFIX=${WZ_NAME_SUFFIX} -DWZ_APPSTREAM_ID=${WZ_APPSTREAM_ID} -P ${CMAKE_CURRENT_SOURCE_DIR}/autorevision_metainfo.cmake
WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
DEPENDS "${_appdata_xml_template_file}" "${wz2100_autorevision_cache_file}" "${CMAKE_CURRENT_SOURCE_DIR}/autorevision_metainfo.cmake"
DEPENDS "${_metainfo_xml_template_file}" "${wz2100_autorevision_cache_file}" "${CMAKE_CURRENT_SOURCE_DIR}/autorevision_metainfo.cmake"
VERBATIM
)

add_custom_target(autorevision_metainfo ALL
DEPENDS
"${_appdata_xml_output_file}"
"${_metainfo_xml_output_file}"
)
set_property(TARGET autorevision_metainfo PROPERTY FOLDER "_WZBuildProcessTargets")
add_dependencies(autorevision_metainfo autorevision) # Ensure ordering and non-concurrency
Expand All @@ -48,7 +48,7 @@ if(UNIX AND NOT APPLE AND NOT WIN32)
DESTINATION "${CMAKE_INSTALL_DATADIR}/applications"
COMPONENT Core
)
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/${WZ_APPSTREAM_ID}${WZ_OUTPUT_NAME_SUFFIX}.appdata.xml"
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/${WZ_APPSTREAM_ID}${WZ_OUTPUT_NAME_SUFFIX}.metainfo.xml"
DESTINATION "${CMAKE_INSTALL_DATADIR}/metainfo"
COMPONENT Core
)
Expand Down
6 changes: 3 additions & 3 deletions icons/autorevision_metainfo.cmake
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
cmake_minimum_required(VERSION 3.5...3.24)

# Automatically update the Release and other info in the net.wz2100.warzone2100.appdata.xml.in file
# Automatically update the Release and other info in the net.wz2100.warzone2100.metainfo.xml.in file
#
# Required input defines:
# - CACHEFILE: the path to the autorevision.cache file generated for the build
# - PROJECT_ROOT: the path the project root (${PROJECT_SOURCE_DIR})
# - TEMPLATE_FILE: the full filename + path for the input net.wz2100.warzone2100.appdata.xml.in template file
# - OUTPUT_FILE: the full filename + path for the output net.wz2100.warzone2100.appdata.xml file
# - TEMPLATE_FILE: the full filename + path for the input net.wz2100.warzone2100.metainfo.xml.in template file
# - OUTPUT_FILE: the full filename + path for the output net.wz2100.warzone2100.metainfo.xml file
#
# And also, passed from the main CMake build:
# - WZ_OUTPUT_NAME_SUFFIX
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@
<project_license>GPL-2.0-or-later</project_license>
<name>Warzone 2100@WZ_NAME_SUFFIX@</name>
<summary>Command the forces of The Project in a battle to rebuild the world.</summary>
<summary xml:lang="de">Befehlige die Truppen des Projektes in dem Kampf die Welt wieder aufzubauen.</summary>
<summary xml:lang="fr">Commandez les forces du Projet dans une bataille pour reconstruire le monde.</summary>
<summary xml:lang="it">Comanda le forze del Progetto in una battaglia per ricostruire il mondo.</summary>
<summary xml:lang="pl">Przejmij dowództwo nad siłami Projektu w bitwie o odbudowę świata.</summary>
<summary xml:lang="pt">Comande as forças do Projecto numa batalha para reconstruir o mundo.</summary>
<summary xml:lang="pt-BR">Comande as forças do Projeto em uma batalha para reconstruir o mundo.</summary>
<summary xml:lang="ru">Управляйте вооруженными силами Проекта в бою за восстановление мира.</summary>
<summary xml:lang="uk">Керуйте збройними силами Проєкту в бою за відновлення миру.</summary>
<launchable type="desktop-id">@WZ_APPSTREAM_ID@@[email protected]</launchable>
<description>
<p>
Expand Down Expand Up @@ -48,6 +56,7 @@
<kudo>HiDpiIcon</kudo>
<kudo>UserDocs</kudo>
</kudos>
<translation type="gettext">warzone2100</translation>
<screenshots>
<screenshot type="default">
<caption>Compete in massive battles, with up to 10 players</caption>
Expand Down
18 changes: 4 additions & 14 deletions pkg/dpkg/README
Original file line number Diff line number Diff line change
@@ -1,21 +1,11 @@
To make Debian packages of the main game, do the following from the root of the
source tree:
To build Debian packages of the main game, use CPack.

ln -s pkg/dpkg debian
dpkg-buildpackage -b -uc
Standard CPack configuration options can be used to configure a single .deb, split .debs by components, etc.

The second step might need additional packages to be installed, it should tell
you which.

After that you'll have three packages, warzone2100, warzone2100-data and
warzone2100-music in the parent folder. The music package is not necessary to
play. Install them as root with "dpkg -i warzone*.deb".
See: https://cmake.org/cmake/help/latest/cpack_gen/deb.html

--------

For the videos, download the sequences.wz you want from
http://wz2100.net/download, put it into pkg/dpkg/video, then run
"dpkg-buildpackage -uc -b" from that folder.


NOTE: These packages will override your repository's Warzone packages, if you
install these, you'll have to update manually.
5 changes: 0 additions & 5 deletions pkg/dpkg/README.Debian

This file was deleted.

Loading
Loading