[oe] [meta-browser][PATCH][resend] chromium: conditionally compile routines for use with GLIB

Eric Nelson eric.nelson at boundarydevices.com
Wed Oct 8 18:46:32 UTC 2014


The routine QuoteArgForDesktopFileExec is only called when GLIB is
used, and compilation will fail with the following error message
if it is compiled without GLIB support (e.g. under Wayland):
	"defined but not used [-Werror=unused-function]"

Signed-off-by: Eric Nelson <eric.nelson at boundarydevices.com>
---
 First e-mail bounced because I wasn't subscribed to the list

 ...ration-conditionally-compile-routines-for.patch | 41 ++++++++++++++++++++++
 recipes-browser/chromium/chromium_37.0.2062.94.bb  |  1 +
 2 files changed, 42 insertions(+)
 create mode 100644 recipes-browser/chromium/chromium/0001-shell-integration-conditionally-compile-routines-for.patch

diff --git a/recipes-browser/chromium/chromium/0001-shell-integration-conditionally-compile-routines-for.patch b/recipes-browser/chromium/chromium/0001-shell-integration-conditionally-compile-routines-for.patch
new file mode 100644
index 0000000..bf0f274
--- /dev/null
+++ b/recipes-browser/chromium/chromium/0001-shell-integration-conditionally-compile-routines-for.patch
@@ -0,0 +1,41 @@
+From 40659667549d1eec5c9ed29c6120584f6628d761 Mon Sep 17 00:00:00 2001
+From: Eric Nelson <eric.nelson at boundarydevices.com>
+Date: Mon, 6 Oct 2014 18:11:29 -0700
+Subject: [PATCH] shell integration: conditionally compile routines for use
+ with GLIB
+
+The routine QuoteArgForDesktopFileExec is only called when GLIB is
+used, and compilation will fail with the following error message
+if it is compiled.
+
+	"defined but not used [-Werror=unused-function]"
+
+Signed-off-by: Eric Nelson <eric.nelson at boundarydevices.com>
+---
+ chrome/browser/shell_integration_linux.cc | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/chrome/browser/shell_integration_linux.cc b/chrome/browser/shell_integration_linux.cc
+index 24a1c55..bd82db4 100644
+--- a/chrome/browser/shell_integration_linux.cc
++++ b/chrome/browser/shell_integration_linux.cc
+@@ -260,6 +260,7 @@ void DeleteShortcutInApplicationsMenu(
+   LaunchXdgUtility(argv, &exit_code);
+ }
+ 
++#if defined(USE_GLIB)
+ // Quote a string such that it appears as one verbatim argument for the Exec
+ // key in a desktop file.
+ std::string QuoteArgForDesktopFileExec(const std::string& arg) {
+@@ -307,6 +308,8 @@ std::string QuoteCommandLineForDesktopFileExec(
+   return quoted_path;
+ }
+ 
++#endif
++
+ const char kDesktopEntry[] = "Desktop Entry";
+ 
+ const char kXdgOpenShebang[] = "#!/usr/bin/env xdg-open";
+-- 
+1.9.1
+
diff --git a/recipes-browser/chromium/chromium_37.0.2062.94.bb b/recipes-browser/chromium/chromium_37.0.2062.94.bb
index 3d4524b..c2b2b8b 100644
--- a/recipes-browser/chromium/chromium_37.0.2062.94.bb
+++ b/recipes-browser/chromium/chromium_37.0.2062.94.bb
@@ -13,6 +13,7 @@ SRC_URI = "\
         file://unistd-2.patch \
         file://google-chrome \
         file://google-chrome.desktop \
+        file://0001-shell-integration-conditionally-compile-routines-for.patch \
 "
 SRC_URI[md5sum] = "49bcf221a2e2e5406ae2e69964d01093"
 SRC_URI[sha256sum] = "d27c19580b74cbe143131f0bc097557b3b2fb3d2be966e688d8af51a779ce533"
-- 
1.9.1




More information about the Openembedded-devel mailing list