[fuchsia] Add build rules for flags.
Change-Id: Ieccb6df61e5ff67c3416ab53fdfe908ad18e0779
diff --git a/absl/BUILD.gn b/absl/BUILD.gn
index 31344d2..7120502 100644
--- a/absl/BUILD.gn
+++ b/absl/BUILD.gn
@@ -13,5 +13,6 @@
public_deps = [
"//third_party/abseil-cpp/absl/strings",
+ "//third_party/abseil-cpp/absl/flags",
]
}
diff --git a/absl/flags/BUILD.gn b/absl/flags/BUILD.gn
new file mode 100644
index 0000000..f0e7ac4
--- /dev/null
+++ b/absl/flags/BUILD.gn
@@ -0,0 +1,75 @@
+# Copyright 2019 The Fuchsia Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+# Please do not add more entries to this list. We plan to remove
+# abseil-cpp from the Fuchsia platform source tree once cobalt
+# moves out-of-tree.
+visibility = [
+ "//src/ledger/*",
+ "//third_party/abseil-cpp/*",
+ "$cobalt_root/*",
+ "//third_party/tink/*",
+]
+
+static_library("flags") {
+ public_configs = [ "//third_party/abseil-cpp:abseil_config" ]
+
+ sources = [
+ "config.h",
+ "declare.h",
+ "flag.cc",
+ "flag.h",
+ "marshalling.cc",
+ "marshalling.h",
+ "parse.cc",
+ "parse.h",
+ "usage.cc",
+ "usage_config.cc",
+ "usage_config.h",
+ "usage.h",
+ ]
+
+ public_deps = [
+ "../strings",
+ "../synchronization",
+ ]
+
+ deps = [
+ ":internal",
+ "../base",
+ "../base:config",
+ "../base:core_headers",
+ "../base:endian",
+ "../base:throw_delegate",
+ "../memory",
+ "../meta:type_traits",
+ "../numeric:int128",
+ ]
+}
+
+static_library("internal") {
+ public_configs = [ "//third_party/abseil-cpp:abseil_config" ]
+
+ public_deps = [
+ "../strings",
+ "../synchronization",
+ ]
+
+ sources = [
+ "internal/commandlineflag.cc",
+ "internal/commandlineflag.h",
+ "internal/flag.cc",
+ "internal/flag.h",
+ "internal/parse.h",
+ "internal/path_util.h",
+ "internal/program_name.cc",
+ "internal/program_name.h",
+ "internal/registry.cc",
+ "internal/registry.h",
+ "internal/type_erased.cc",
+ "internal/type_erased.h",
+ "internal/usage.cc",
+ "internal/usage.h",
+ ]
+}