PSA: libcap2 needed to build on Linux

852 views
Skip to first unread message

Julien Tinnes

unread,
Oct 29, 2013, 11:11:06 PM10/29/13
to Chromium-dev
TL;DR: If you see "error: sys/capability.h: No such file or directory", run "sudo build/install-build-deps.sh" or "sudo apt-get install libcap-dev libcap2".

As part of the move away from the setuid sandbox (crbug.com/312380), we're going to use libcap2 to handle capabilities.

On Ubuntu, this means that you need to "apt-get install libcap-dev libcap2". Both have been added to the handy build/install-build-deps.sh script.

This is currently pending on Chrome infrastructure installing these on our bots, which should happen soon, so do it now!

Julien

Michael Moss

unread,
Oct 29, 2013, 11:52:08 PM10/29/13
to j...@chromium.org, Chromium-dev
And if you get in the habit of doing:

build/install-build-deps.sh --quick-check && ninja ...

you won't be caught by surprise by a missing build dependency again* :)

Michael

*except when "quick" == "incomplete" and it misses something, but it's a start (and works in this instance).


--
--
Chromium Developers mailing list: chromi...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-dev

Nico Weber

unread,
Nov 5, 2013, 1:05:24 AM11/5/13
to Michael Moss, j...@chromium.org, Chromium-dev
It looks like this now landed, since many (all?) of my linux_rel tryjobs are failing with "fatalerror: sys/capability.h: No such file or directory". I guess that's not expected? Was the header not installed on the bots?

Lei Zhang

unread,
Nov 5, 2013, 1:15:08 AM11/5/13
to Nico Weber, Michael Moss, Julien Tinnes, Chromium-dev
I mentioned it on bug 312572. How important is it for us to get this
CL in for M32? We'd either have to fix the trybots soon or revert,
otherwise nobody will be able to commit through the CQ.

Julien Tinnes

unread,
Nov 5, 2013, 1:43:26 AM11/5/13
to Lei Zhang, Nico Weber, Michael Moss, Chromium-dev, c...@chromium.org, jo...@chromium.org, Jorge Lucangeli Obes, Isaac Levy, Paweł Hajdan, Jr.
Yeah, it's supposed to work since last Wednesday, see
crbug.com/312572, but there are always bots that aren't updated for
some reason. Isaac reverted it a few minutes ago.

I thought that John had double-checked that it was installed on all
bots. Try bots seem to be the issue, the main WF is fine (it was even
in LKGR).

Nico: can you please report your failing bots to the bug?

John/Chase: any way out of this situation ? It looks like we're not
equipped to handle new packages, which is problematic. Hopefully this
can be fixed very soon, I'm really blocked.
In the medium term, should we switch everything to use sysroot?

Julien

Dominic Mazzoni

unread,
Nov 5, 2013, 11:34:27 AM11/5/13
to j...@chromium.org, Lei Zhang, Nico Weber, Michael Moss, Chromium-dev, c...@chromium.org, jo...@chromium.org, Jorge Lucangeli Obes, Isaac Levy, Paweł Hajdan, Jr.
On Mon, Nov 4, 2013 at 10:43 PM, Julien Tinnes <j...@chromium.org> wrote:
but there are always bots that aren't updated for some reason.

The same thing happened with libbrl just last month, it took three tries before *all* of the bots successfully ran install-build-deps. Any reason we couldn't just make install-build-deps one of the build steps? Or why not just run it as part of gclient runhooks? (Maybe it should be --quick-check for most users)

Paweł Hajdan, Jr.

unread,
Nov 5, 2013, 2:31:45 PM11/5/13
to Dominic Mazzoni, Julien Tinnes, Lei Zhang, Nico Weber, Michael Moss, Chromium-dev, c...@chromium.org, jo...@chromium.org, Jorge Lucangeli Obes, Isaac Levy
+1 to always run --quick-check before building.

Paweł

Lei Zhang

unread,
Nov 5, 2013, 2:39:37 PM11/5/13
to Paweł Hajdan, Jr., Dominic Mazzoni, Julien Tinnes, Nico Weber, Michael Moss, Chromium-dev, c...@chromium.org, jo...@chromium.org, Jorge Lucangeli Obes, Isaac Levy
Takes less than 1 second to run here. Filed http://crbug.com/315198

Sam Clegg

unread,
Nov 8, 2013, 12:33:53 PM11/8/13
to j...@chromium.org, Lei Zhang, Nico Weber, Michael Moss, Chromium-dev, c...@chromium.org, jo...@chromium.org, Jorge Lucangeli Obes, Isaac Levy, Paweł Hajdan, Jr.
On Mon, Nov 4, 2013 at 10:43 PM, Julien Tinnes <j...@chromium.org> wrote:
> Yeah, it's supposed to work since last Wednesday, see
> crbug.com/312572, but there are always bots that aren't updated for
> some reason. Isaac reverted it a few minutes ago.
>
> I thought that John had double-checked that it was installed on all
> bots. Try bots seem to be the issue, the main WF is fine (it was even
> in LKGR).
>
> Nico: can you please report your failing bots to the bug?
>
> John/Chase: any way out of this situation ? It looks like we're not
> equipped to handle new packages, which is problematic. Hopefully this
> can be fixed very soon, I'm really blocked.
> In the medium term, should we switch everything to use sysroot?


I like the idea of always using a sysroot on the bots. We already do
this for the official builders IIUC. Seems like a lot of advantages:

- reduce the bot maintenance burden.
- less dependence on the state of the bot.
- more reproducible builds/failures.
- makes it possible to build two branches with mutually conflicting
deps (e.g. different versions of the same -dev package).

Might even make sense to make this the default for all linux builds
including local devleoper builds. No more PSA messages about having
to run install-build-deps.
Reply all
Reply to author
Forward
0 new messages