Move over to ABSL logging and flags.

Removes gperftools too since that wants gflags.

Here come the fireworks.

Change-Id: I79cb7bcf60f1047fbfa28bfffc21a0fd692e4b1c
Signed-off-by: Austin Schuh <austin.linux@gmail.com>
diff --git a/aos/flatbuffers/BUILD b/aos/flatbuffers/BUILD
index e4f7d1d..f7e4670 100644
--- a/aos/flatbuffers/BUILD
+++ b/aos/flatbuffers/BUILD
@@ -11,7 +11,8 @@
         ":static_vector",
         "//aos:json_to_flatbuffer",
         "@com_github_google_flatbuffers//:flatbuffers",
-        "@com_github_google_glog//:glog",
+        "@com_google_absl//absl/log",
+        "@com_google_absl//absl/log:check",
         "@com_google_absl//absl/strings",
         "@com_google_absl//absl/strings:str_format",
     ],
@@ -32,8 +33,9 @@
         "//aos/containers:resizeable_buffer",
         "//aos/ipc_lib:data_alignment",
         "@com_github_google_flatbuffers//:flatbuffers",
-        "@com_github_google_glog//:glog",
         "@com_google_absl//absl/base",
+        "@com_google_absl//absl/log",
+        "@com_google_absl//absl/log:check",
         "@com_google_absl//absl/types:span",
     ],
 )
@@ -54,7 +56,8 @@
     deps = [
         ":base",
         "@com_github_google_flatbuffers//:flatbuffers",
-        "@com_github_google_glog//:glog",
+        "@com_google_absl//absl/log",
+        "@com_google_absl//absl/log:check",
     ],
 )
 
@@ -67,7 +70,8 @@
         "//aos/containers:inlined_vector",
         "//aos/containers:sized_array",
         "@com_github_google_flatbuffers//:flatbuffers",
-        "@com_github_google_glog//:glog",
+        "@com_google_absl//absl/log",
+        "@com_google_absl//absl/log:check",
     ],
 )
 
diff --git a/aos/flatbuffers/base.cc b/aos/flatbuffers/base.cc
index f0e7a8b..77988da 100644
--- a/aos/flatbuffers/base.cc
+++ b/aos/flatbuffers/base.cc
@@ -4,6 +4,9 @@
 
 #include <iomanip>
 
+#include "absl/log/check.h"
+#include "absl/log/log.h"
+
 namespace aos::fbs {
 
 namespace {
diff --git a/aos/flatbuffers/base.h b/aos/flatbuffers/base.h
index 6e93f93..a0d3810 100644
--- a/aos/flatbuffers/base.h
+++ b/aos/flatbuffers/base.h
@@ -12,9 +12,10 @@
 #include <utility>
 #include <vector>
 
+#include "absl/log/check.h"
+#include "absl/log/log.h"
 #include "absl/types/span.h"
 #include "flatbuffers/base.h"
-#include "glog/logging.h"
 
 #include "aos/containers/resizeable_buffer.h"
 #include "aos/ipc_lib/data_alignment.h"
diff --git a/aos/flatbuffers/generate.cc b/aos/flatbuffers/generate.cc
index 9a2e5fd..4c76785 100644
--- a/aos/flatbuffers/generate.cc
+++ b/aos/flatbuffers/generate.cc
@@ -1,7 +1,7 @@
 #include <stdlib.h>
 
+#include "absl/flags/flag.h"
 #include "flatbuffers/reflection_generated.h"
-#include "gflags/gflags.h"
 
 #include "aos/flatbuffers.h"
 #include "aos/flatbuffers/static_flatbuffers.h"
@@ -9,19 +9,22 @@
 #include "aos/json_to_flatbuffer.h"
 #include "aos/util/file.h"
 
-DEFINE_string(reflection_bfbs, "", "Path to the .bfbs reflection file.");
-DEFINE_string(output_file, "", "Path to the output header to write.");
-DEFINE_string(base_file_name, "",
-              "Name of the base file to generate code for as used by the "
-              "reflection::Schema object.");
+ABSL_FLAG(std::string, reflection_bfbs, "",
+          "Path to the .bfbs reflection file.");
+ABSL_FLAG(std::string, output_file, "", "Path to the output header to write.");
+ABSL_FLAG(std::string, base_file_name, "",
+          "Name of the base file to generate code for as used by the "
+          "reflection::Schema object.");
 
 namespace aos::fbs {
 int Main() {
   aos::FlatbufferVector<reflection::Schema> schema =
-      aos::FileToFlatbuffer<reflection::Schema>(FLAGS_reflection_bfbs);
+      aos::FileToFlatbuffer<reflection::Schema>(
+          absl::GetFlag(FLAGS_reflection_bfbs));
   aos::util::WriteStringToFileOrDie(
-      FLAGS_output_file,
-      GenerateCodeForRootTableFile(&schema.message(), FLAGS_base_file_name));
+      absl::GetFlag(FLAGS_output_file),
+      GenerateCodeForRootTableFile(&schema.message(),
+                                   absl::GetFlag(FLAGS_base_file_name)));
   return EXIT_SUCCESS;
 }
 }  // namespace aos::fbs
diff --git a/aos/flatbuffers/static_flatbuffers.cc b/aos/flatbuffers/static_flatbuffers.cc
index 449bcbc..e3130bb 100644
--- a/aos/flatbuffers/static_flatbuffers.cc
+++ b/aos/flatbuffers/static_flatbuffers.cc
@@ -10,6 +10,8 @@
 #include <utility>
 #include <vector>
 
+#include "absl/log/check.h"
+#include "absl/log/log.h"
 #include "absl/strings/numbers.h"
 #include "absl/strings/str_cat.h"
 #include "absl/strings/str_format.h"
@@ -19,7 +21,6 @@
 #include "flatbuffers/base.h"
 #include "flatbuffers/string.h"
 #include "flatbuffers/vector.h"
-#include "glog/logging.h"
 
 #include "aos/flatbuffers/base.h"
 #include "aos/json_to_flatbuffer.h"
diff --git a/aos/flatbuffers/static_flatbuffers_test.cc b/aos/flatbuffers/static_flatbuffers_test.cc
index 187c72a..aee8067 100644
--- a/aos/flatbuffers/static_flatbuffers_test.cc
+++ b/aos/flatbuffers/static_flatbuffers_test.cc
@@ -12,6 +12,8 @@
 #include <utility>
 #include <vector>
 
+#include "absl/log/check.h"
+#include "absl/log/log.h"
 #include "absl/strings/str_format.h"
 #include "absl/strings/str_join.h"
 #include "absl/types/span.h"
@@ -23,7 +25,6 @@
 #include "flatbuffers/stl_emulation.h"
 #include "flatbuffers/string.h"
 #include "flatbuffers/vector.h"
-#include "glog/logging.h"
 #include "gtest/gtest.h"
 
 #include "aos/flatbuffers.h"
diff --git a/aos/flatbuffers/static_table.h b/aos/flatbuffers/static_table.h
index a7f96d1..cd3ae5c 100644
--- a/aos/flatbuffers/static_table.h
+++ b/aos/flatbuffers/static_table.h
@@ -3,8 +3,9 @@
 #include <algorithm>
 #include <span>
 
+#include "absl/log/check.h"
+#include "absl/log/log.h"
 #include "flatbuffers/base.h"
-#include "glog/logging.h"
 
 #include "aos/flatbuffers/base.h"
 namespace aos::fbs {
diff --git a/aos/flatbuffers/static_vector.h b/aos/flatbuffers/static_vector.h
index f0c48cd..c835864 100644
--- a/aos/flatbuffers/static_vector.h
+++ b/aos/flatbuffers/static_vector.h
@@ -2,9 +2,10 @@
 #define AOS_FLATBUFFERS_STATIC_VECTOR_H_
 #include <span>
 
+#include "absl/log/check.h"
+#include "absl/log/log.h"
 #include "flatbuffers/base.h"
 #include "flatbuffers/vector.h"
-#include "glog/logging.h"
 
 #include "aos/containers/inlined_vector.h"
 #include "aos/containers/sized_array.h"