Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/2] package/qt6/qt6tools: allow building host Qt Linguist Tools
@ 2024-09-04 12:20 Roy Kollen Svendsen
  2024-09-04 12:20 ` [Buildroot] [PATCH 2/2] package/qt6/qt6base: allow selecting the host Qt Print Support module Roy Kollen Svendsen
  2024-09-04 12:30 ` [Buildroot] [PATCH 1/2] package/qt6/qt6tools: allow building host Qt Linguist Tools Thomas Petazzoni via buildroot
  0 siblings, 2 replies; 6+ messages in thread
From: Roy Kollen Svendsen @ 2024-09-04 12:20 UTC (permalink / raw)
  To: buildroot; +Cc: Jesse Van Gavere, Roy Kollen Svendsen, Thomas Petazzoni

According to src/linguist/CMakeLists.txt we need to enable the
linguist feature:

...
if(NOT QT_FEATURE_linguist)
    return()
endif()
add_subdirectory(lconvert)
add_subdirectory(lprodump)
add_subdirectory(lrelease)
add_subdirectory(lrelease-pro)
add_subdirectory(lupdate)
add_subdirectory(lupdate-pro)
if(QT_FEATURE_process AND QT_FEATURE_pushbutton AND QT_FEATURE_toolbutton AND TARGET Qt::Widgets AND NOT no-png)
    add_subdirectory(linguist)
endif()
...

And according to configure.cmake we need to select print support:
...
qt_feature("linguist" PRIVATE
    LABEL "Qt Linguist"
    PURPOSE "Qt Linguist can be used by translator to translate text in Qt applications."
    CONDITION TARGET Qt::PrintSupport
)
...

Signed-off-by: Roy Kollen Svendsen <roykollensvendsen@gmail.com>
---
 package/qt6/qt6tools/Config.in   | 11 +++++++++++
 package/qt6/qt6tools/qt6tools.mk | 10 ++++++++--
 2 files changed, 19 insertions(+), 2 deletions(-)

diff --git a/package/qt6/qt6tools/Config.in b/package/qt6/qt6tools/Config.in
index 5f52c5644f..eea461a2a9 100644
--- a/package/qt6/qt6tools/Config.in
+++ b/package/qt6/qt6tools/Config.in
@@ -15,3 +15,14 @@ config BR2_PACKAGE_QT6TOOLS
 	  and design of applications.
 
 	  https://github.com/qt/qttools
+
+if BR2_PACKAGE_QT6TOOLS
+
+config BR2_PACKAGE_HOST_QT6TOOLS_LINGUIST_TOOLS
+	bool "linguist tools (host)"
+	select BR2_PACKAGE_HOST_QT6BASE_PRINTSUPPORT
+	help
+	  Translate Qt C++ and Qt Quick applications into local
+	  languages.
+
+endif
diff --git a/package/qt6/qt6tools/qt6tools.mk b/package/qt6/qt6tools/qt6tools.mk
index 09c986cfc6..897cf43054 100644
--- a/package/qt6/qt6tools/qt6tools.mk
+++ b/package/qt6/qt6tools/qt6tools.mk
@@ -37,11 +37,17 @@ QT6TOOLS_DEPENDENCIES = \
 	qt6base \
 	host-qt6tools
 
+HOST_QT6TOOLS_DEPENDENCIES = host-qt6base
+
+ifeq ($(BR2_PACKAGE_HOST_QT6TOOLS_LINGUIST_TOOLS),y)
+HOST_QT6TOOLS_CONF_OPTS += -DFEATURE_linguist=ON
+else
+HOST_QT6TOOLS_CONF_OPTS += -DFEATURE_linguist=OFF
+endif
+
 ifeq ($(BR2_PACKAGE_QT6DECLARATIVE),y)
 QT6TOOLS_DEPENDENCIES += qt6declarative
 endif
 
-HOST_QT6TOOLS_DEPENDENCIES = host-qt6base
-
 $(eval $(cmake-package))
 $(eval $(host-cmake-package))
-- 
2.46.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2024-09-04 21:27 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-04 12:20 [Buildroot] [PATCH 1/2] package/qt6/qt6tools: allow building host Qt Linguist Tools Roy Kollen Svendsen
2024-09-04 12:20 ` [Buildroot] [PATCH 2/2] package/qt6/qt6base: allow selecting the host Qt Print Support module Roy Kollen Svendsen
2024-09-04 12:33   ` Thomas Petazzoni via buildroot
2024-09-04 21:23     ` Roy Kollen Svendsen
2024-09-04 12:30 ` [Buildroot] [PATCH 1/2] package/qt6/qt6tools: allow building host Qt Linguist Tools Thomas Petazzoni via buildroot
2024-09-04 21:27   ` Roy Kollen Svendsen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox