Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(403)

Unified Diff: net/tools/transport_security_state_generator/BUILD.gn

Issue 2680933009: Add unittests for HSTS decoding. (Closed)
Patch Set: rebase & comments rsleevi. Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/tools/transport_security_state_generator/BUILD.gn
diff --git a/net/tools/transport_security_state_generator/BUILD.gn b/net/tools/transport_security_state_generator/BUILD.gn
new file mode 100644
index 0000000000000000000000000000000000000000..0d90577fbb2c8b9c879ce84c60964ac1a505a1a2
--- /dev/null
+++ b/net/tools/transport_security_state_generator/BUILD.gn
@@ -0,0 +1,59 @@
+# Copyright (c) 2017 The Chromium Authors. All rights reserved.
brettw 2017/03/20 20:42:41 uber-nit: The current reference copyright block ha
martijnc 2017/03/20 21:46:25 Removed.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+import("//build/compiled_action.gni")
+
+if (host_toolchain == current_toolchain) {
+ executable("transport_security_state_generator") {
+ sources = [
+ "bit_writer.cc",
+ "bit_writer.h",
+ "cert_util.cc",
+ "cert_util.h",
+ "huffman/huffman_builder.cc",
+ "huffman/huffman_builder.h",
+ "pinset.cc",
+ "pinset.h",
+ "pinsets.cc",
+ "pinsets.h",
+ "preloaded_state_generator.cc",
+ "preloaded_state_generator.h",
+ "spki_hash.cc",
+ "spki_hash.h",
+ "transport_security_state_entry.cc",
+ "transport_security_state_entry.h",
+ "transport_security_state_generator.cc",
+ "trie/trie_bit_buffer.cc",
+ "trie/trie_bit_buffer.h",
+ "trie/trie_writer.cc",
+ "trie/trie_writer.h",
+ ]
+ deps = [
+ "//base",
+ "//crypto",
+ "//third_party/boringssl",
+ ]
+ }
+}
+
+compiled_action_foreach("generate_test_data") {
+ tool = ":transport_security_state_generator"
+ sources = [
+ "//net/http/transport_security_state_static_unittest1.json",
+ "//net/http/transport_security_state_static_unittest2.json",
+ "//net/http/transport_security_state_static_unittest3.json",
+ ]
+
+ # Inputs in order expected by the command line of the tool.
+ inputs = [
+ "//net/http/transport_security_state_static_unittest.pins",
+ "resources/transport_security_state_static_unittest.template",
+ ]
+ outputs = [
+ get_label_info("//net/http/{{source_name_part}}.h", "target_gen_dir"),
+ ]
+ args =
+ [ rebase_path("//net/http/{{source_name_part}}.json", root_build_dir) ] +
+ rebase_path(inputs, root_build_dir) + rebase_path(outputs, root_build_dir)
+}

Powered by Google App Engine
This is Rietveld 408576698