From 378f071124b232cf238f88f8af073bcfb74b17f3 Mon Sep 17 00:00:00 2001 From: Alex Humesky Date: Tue, 3 Jul 2018 20:32:51 -0400 Subject: [PATCH] Create third_party directory. Rename GenerateFirebaseXml to GenerateGoogleServicesXml. Create WORKSPACE file. Change-Id: Ib4130792dd5dc081bd98ca4b07e9e52d6f9b76e3 --- WORKSPACE | 0 third_party/googleservices/BUILD | 6 ++++++ .../gms/googleservices/GenerateGoogleServicesXml.java | 2 +- tools/googleservices/BUILD | 7 +------ tools/googleservices/defs.bzl | 4 ++-- 5 files changed, 10 insertions(+), 9 deletions(-) create mode 100644 WORKSPACE create mode 100644 third_party/googleservices/BUILD rename tools/googleservices/java/com/google/gms/googleservices/GenerateFirebaseXml.java => third_party/googleservices/java/com/google/gms/googleservices/GenerateGoogleServicesXml.java (99%) diff --git a/WORKSPACE b/WORKSPACE new file mode 100644 index 0000000..e69de29 diff --git a/third_party/googleservices/BUILD b/third_party/googleservices/BUILD new file mode 100644 index 0000000..f896ce7 --- /dev/null +++ b/third_party/googleservices/BUILD @@ -0,0 +1,6 @@ +java_binary( + name = "GenerateGoogleServicesXml", + srcs = ["java/com/google/gms/googleservices/GenerateGoogleServicesXml.java"], + deps = ["@com_google_code_gson_2_8_2//jar"], + visibility = ["//visibility:public"], +) diff --git a/tools/googleservices/java/com/google/gms/googleservices/GenerateFirebaseXml.java b/third_party/googleservices/java/com/google/gms/googleservices/GenerateGoogleServicesXml.java similarity index 99% rename from tools/googleservices/java/com/google/gms/googleservices/GenerateFirebaseXml.java rename to third_party/googleservices/java/com/google/gms/googleservices/GenerateGoogleServicesXml.java index 168f1a7..afaf352 100644 --- a/tools/googleservices/java/com/google/gms/googleservices/GenerateFirebaseXml.java +++ b/third_party/googleservices/java/com/google/gms/googleservices/GenerateGoogleServicesXml.java @@ -39,7 +39,7 @@ * Command line: * packageName inputJsonFile outputXmlFile */ -public class GenerateFirebaseXml { +public class GenerateGoogleServicesXml { private static final String STATUS_DISABLED = "1"; private static final String STATUS_ENABLED = "2"; diff --git a/tools/googleservices/BUILD b/tools/googleservices/BUILD index 8345f3e..5a203b3 100644 --- a/tools/googleservices/BUILD +++ b/tools/googleservices/BUILD @@ -1,6 +1 @@ -java_binary( - name = "GenerateFirebaseXml", - srcs = ["java/com/google/gms/googleservices/GenerateFirebaseXml.java"], - deps = ["@com_google_code_gson_2_8_2//jar"], - visibility = ["//visibility:public"], -) +exports_files(["defs.bzl"]) diff --git a/tools/googleservices/defs.bzl b/tools/googleservices/defs.bzl index 3c7adce..c99fcca 100644 --- a/tools/googleservices/defs.bzl +++ b/tools/googleservices/defs.bzl @@ -26,8 +26,8 @@ def google_services_xml(package_name, google_services_json): name = name, srcs = [google_services_json], outs = outs, - tools = ["@rules_android//tools/googleservices:GenerateFirebaseXml"], - cmd = "$(location @rules_android//tools/googleservices:GenerateFirebaseXml) %s $< $@" % package_name, + tools = ["@tools_android//third_party/googleservices:GenerateGoogleServicesXml"], + cmd = "$(location @tools_android//third_party/googleservices:GenerateGoogleServicesXml) %s $< $@" % package_name, ) return outs