Commit graph

8 commits

Author SHA1 Message Date
Dennis Kempin
1e80b0d6a3 Refactoring Script: Move win_(sys_)util
This script moves win_util from crosvm/common/ to crosvm/
and win_sys_util into base::windows.

The CL makes some prerequisite code changes needed to enable
building of tests after the script is applied.

BUG=b:223206469
TEST=presubmit

Change-Id: I5c1952596d3161730be3f42ce5d6cb554ab66b4a
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/3537257
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Tested-by: kokoro <noreply+kokoro@google.com>
2022-03-22 22:23:41 +00:00
Dennis Kempin
4fa9b5147c Refactoring script: Copy sys_util(_core) to base
This will allow us to merge sys_util and win_sys_util.
The original source locations will remain until they
are moved into the ChromeOS source base.

See go/future-of-sys-util for details

BUG=b:22320646
TEST=run it

Change-Id: Ie1adcadba9d35f18cc7472dc78f05262114a726f
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/3536890
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Tested-by: kokoro <noreply+kokoro@google.com>
2022-03-21 19:52:56 +00:00
Dennis Kempin
00cbeb7d4c Refactoring script: Copy common/io_uring to io_uring
The crate is only used by cros_async, which has already been
copied to crosvm.
The old source location will eventually move to ChromeOS.

See go/future-of-sys-util for details

BUG=b:22320646
TEST=presubmit

Change-Id: Icf3522497cb4e8c04a4687403466b781f0d7a9ee
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/3534501
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Tested-by: Dennis Kempin <denniskempin@google.com>
2022-03-21 19:52:56 +00:00
Dennis Kempin
dca90f49bd Refactoring script: Copy common/cros_async to cros_async
The copy is going to be used by crosvm going forward, while the
old version will eventually be moved to ChromeOS.

See go/future-of-sys-util for details

BUG=b:22320646
TEST=presubmit

Change-Id: Ic3216855fc244e366423160464dc722a04dfc56d
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/3533607
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Tested-by: kokoro <noreply+kokoro@google.com>
2022-03-21 19:52:56 +00:00
Dennis Kempin
fd0b4cb74a Refactoring script to move common/base/ to base/
This is a prerequisite for sys_util* to move into the base
crate. The crate should never have been in common in the
first place since it is not shared.

BUG=b:223206469
TEST=python tools/contrib/cargo_refactor.py

Change-Id: I60115e0418c6980d7bf7ff624a3cc0a24e71a57d
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/3530502
Reviewed-by: Anton Romanov <romanton@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Vikram Auradkar <auradkar@google.com>
2022-03-17 00:01:27 +00:00
Daniel Verkamp
c13c0c210b enumn: switch to upstream crates.io version
Developers may need to manually clean up the common/enumn directory - it
will be left behind if there are build artifacts (Cargo.lock, target
directory, etc.):

  rm -rf common/enumn

BUG=b:205344148
TEST=cargo build
TEST=tools/presubmit
TEST=emerge-hatch crosvm # with https://crrev.com/c/3265967

Change-Id: I1af3bdd22f40e87895a78a5cbc8033476058c927
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/3278774
Reviewed-by: Dennis Kempin <denniskempin@google.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Commit-Queue: Daniel Verkamp <dverkamp@chromium.org>
2021-11-15 21:03:25 +00:00
Dennis Kempin
6e3350a956 Add base crate to cargo_refactor
We are adding an ebuild file for this crate in a future
CL: https://crrev.com/c/3251800

BUG=b:195126527
TEST=Run the script

Change-Id: If58c28075d5f3a3d2ad2b8c55714d1f8cdb968ab
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/3251784
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Tested-by: kokoro <noreply+kokoro@google.com>
Commit-Queue: Dennis Kempin <denniskempin@google.com>
2021-10-28 21:04:59 +00:00
Dennis Kempin
783791441d Refactor script: Move non-workspace crates to common/
This CL contains just a refactoring script, a follow-up contains
the result of running it. This is easier to review than 100s of
search/replace.

I think it makes sense to leave this script around for future
reference if we need to shuffle things around again.

BUG=b:195126527
TEST=None

Change-Id: Ic8cc69946b8e6908877e4fbde44230d40a1ea566
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/3232967
Tested-by: kokoro <noreply+kokoro@google.com>
Commit-Queue: Dennis Kempin <denniskempin@google.com>
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
2021-10-27 22:51:25 +00:00