New issue
Advanced search Search tips

Issue 645332 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Feb 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 2
Type: Bug



Sign in to add a comment

Error compiling libsecret when use_ozone=1: glib.h not found

Project Member Reported by sque@chromium.org, Sep 9 2016

Issue description

I'm building Chrome on Linux using GN with the following options:
   is_component_build = false
   use_goma = true
   goma_dir = "/usr/local/ssd/cros/chromium/.cros_cache/common/goma+2/"
   use_ozone = true

I'm getting the following error:
In file included from ../../chrome/browser/password_manager/native_backend_libsecret.cc:5:
In file included from ../../chrome/browser/password_manager/native_backend_libsecret.h:17:
In file included from ../../components/os_crypt/libsecret_util_linux.h:8:
../../third_party/libsecret/libsecret/secret.h:18:10: fatal error: 'glib.h' file not found
#include <glib.h>

See full command and error here: http://pastebin.com/atUJZkCt

I see that this error was fixed in http://crrev.com/1934193002, and the GN file (components/os_crypt/BUILD.gn) has been changed since then. The glib dependency is now behind a "if (use_glib)" conditional.

use_glib is set to false if use_ozone = true (see GN args), which is probably the cause of this error:
https://cs.chromium.org/chromium/src/build/common.gypi?q=%5Cbuse_glib%5Cb&sq=package:chromium&l=761&dr=C

But setting use_ozone = true shouldn't break the build.

 
Components: -Build UI>Browser>Passwords
Labels: -Pri-1 Pri-2
native_backend_libsecret.* and friend may need to be gated on use_glib and not just is_desktop_linux. In r417481, I merged the libsecret is_desktop_linux block, but we may need to pull it out again to add the use_glib conditional.

sources += [
  "password_manager/native_backend_libsecret.cc",
  "password_manager/native_backend_libsecret.h",
]
defines += [ "USE_LIBSECRET" ]
deps += [ "//third_party/libsecret" ]


Here's another question - is Linux (but not ChromeOS) Ozone a supported build config? Is there a bot that builds with this config? If not, then there's no guarantees that the config will always work.

https://build.chromium.org/p/chromium.chromiumos/builders/Linux%20ChromiumOS%20Ozone%20Builder is green...

Comment 2 by vabr@chromium.org, Sep 15 2016

Labels: Hotlist-TechnicalDebt
Owner: toniki...@chromium.org
Status: Fixed (was: Untriaged)
This is long fixed since https://codereview.chromium.org/2341773004 and https://codereview.chromium.org/2452063002
Cc: -vabr@chromium.org

Sign in to add a comment