[AFDO] Add support for xz profiles

Chrome OS wants to start uploading xz compressed profiles for simplicity
(other cros bits use xz, apparently) and better compression:
https://chromium-review.googlesource.com/c/chromiumos/chromite/+/996904

The intent is to support both bzip and xz in Chromium while they make
the transition, then remove bzip support after it's been stable for a
week or so.

This also makes us close our `urlopen` properly. It's not a big deal
that we weren't before, but...

Bug: None
Test: Ran update_afdo_profile.py on bzip2 and xz profiles.
Change-Id: I23cff0818c28b3f49c57376d76bf8144dcdab032
Reviewed-on: https://chromium-review.googlesource.com/997023
Commit-Queue: George Burgess <gbiv@chromium.org>
Reviewed-by: Tommy Nyquist <nyquist@chromium.org>
Reviewed-by: agrieve <agrieve@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#548625}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: f1ef9d9b72dcf1091919aa29cb6567d5fe204993
This commit is contained in:
George Burgess IV 2018-04-06 00:45:36 +00:00 коммит произвёл Commit Bot
Родитель 25157aa29b
Коммит 16d86dd7c4
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -38,7 +38,7 @@ sudo apt-get -y install libncurses5:i386 libstdc++6:i386 zlib1g:i386
sudo apt-get -y install bsdiff
# Needed to unpack the profiles we pull with `gclient runhooks`
sudo apt-get -y install bzip2
sudo apt-get -y install bzip2 xz-utils
# Do our own error handling for java.
set +e