| # Copyright 2016 The Chromium OS Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| # CL:422446 fixes a bug that was resulting in /build/${BOARD}/autotest/logs to |
| # be a directory instead of a symlink (via chromeos-base/autotest-server |
| # package). |
| # But, gentoo's PMS spec doesn't allow an ebuild uprev to convert a directory to |
| # symlink (https://bugs.gentoo.org/show_bug.cgi?id=326685), so we need to clean |
| # up the directory manually. |
| for board_root in /build/*; do |
| if [[ -d "${board_root}/autotest/logs" ]]; then |
| sudo rm -rf "${board_root}/autotest/logs" |
| sudo ln -s "/var/log/autotest" "${board_root}/autotest/logs" |
| fi |
| done |