diff --git a/sandboxed_api/sandbox2/examples/crc4/BUILD.bazel b/sandboxed_api/sandbox2/examples/crc4/BUILD.bazel index 88d213d..a91e251 100644 --- a/sandboxed_api/sandbox2/examples/crc4/BUILD.bazel +++ b/sandboxed_api/sandbox2/examples/crc4/BUILD.bazel @@ -35,6 +35,7 @@ cc_binary( "//sandboxed_api/sandbox2/util:bpf_helper", "//sandboxed_api/sandbox2/util:runfiles", "@com_google_absl//absl/flags:flag", + "@com_google_absl//absl/flags:parse", "@com_google_absl//absl/memory", ], ) @@ -50,6 +51,7 @@ cc_binary( "//sandboxed_api/sandbox2:util", "@com_google_absl//absl/base:core_headers", "@com_google_absl//absl/flags:flag", + "@com_google_absl//absl/flags:parse", ], ) diff --git a/sandboxed_api/sandbox2/examples/crc4/crc4bin.cc b/sandboxed_api/sandbox2/examples/crc4/crc4bin.cc index b3b6ed2..0b07336 100644 --- a/sandboxed_api/sandbox2/examples/crc4/crc4bin.cc +++ b/sandboxed_api/sandbox2/examples/crc4/crc4bin.cc @@ -22,6 +22,7 @@ #include #include "absl/flags/flag.h" +#include "absl/flags/parse.h" #include "sandboxed_api/sandbox2/client.h" #include "sandboxed_api/sandbox2/comms.h" #include "sandboxed_api/sandbox2/util.h" @@ -46,7 +47,7 @@ static uint32_t ComputeCRC4Impl(const uint8_t* ptr, uint64_t len) { } int main(int argc, char** argv) { - google::ParseCommandLineFlags(&argc, &argv, false); + absl::ParseCommandLine(argc, argv); // Set-up the sandbox2::Client object, using a file descriptor (1023). sandbox2::Comms comms(sandbox2::Comms::kSandbox2ClientCommsFD); diff --git a/sandboxed_api/sandbox2/examples/crc4/crc4sandbox.cc b/sandboxed_api/sandbox2/examples/crc4/crc4sandbox.cc index ec87d4b..508f8da 100644 --- a/sandboxed_api/sandbox2/examples/crc4/crc4sandbox.cc +++ b/sandboxed_api/sandbox2/examples/crc4/crc4sandbox.cc @@ -29,6 +29,7 @@ #include #include "absl/flags/flag.h" +#include "absl/flags/parse.h" #include "absl/memory/memory.h" #include "sandboxed_api/sandbox2/comms.h" #include "sandboxed_api/sandbox2/executor.h" @@ -82,7 +83,7 @@ bool SandboxedCRC4(sandbox2::Comms* comms, uint32_t* crc4) { } // namespace int main(int argc, char** argv) { - google::ParseCommandLineFlags(&argc, &argv, true); + absl::ParseCommandLine(argc, argv); google::InitGoogleLogging(argv[0]); if (absl::GetFlag(FLAGS_input).empty()) {