Index: device/vr/BUILD.gn |
diff --git a/device/vr/BUILD.gn b/device/vr/BUILD.gn |
index 5e321fd60d46f746322fbe6844ce7eb4754ebe3c..3d6a0e3f4792dc6e73c3b38e073bf7b497c2dba5 100644 |
--- a/device/vr/BUILD.gn |
+++ b/device/vr/BUILD.gn |
@@ -9,78 +9,85 @@ if (is_android) { |
import("//build/config/android/rules.gni") # For generate_jni(). |
} |
-if (current_cpu == "arm" || current_cpu == "arm64") { |
- component("vr") { |
- output_name = "device_vr" |
+component("vr") { |
+ output_name = "device_vr" |
- sources = [ |
- "vr_device.cc", |
- "vr_device.h", |
- "vr_device_manager.cc", |
- "vr_device_manager.h", |
- "vr_device_provider.h", |
- "vr_display_impl.cc", |
- "vr_display_impl.h", |
- "vr_service_impl.cc", |
- "vr_service_impl.h", |
- ] |
- |
- deps = [ |
- ":mojo_bindings", |
- "//base", |
- "//mojo/public/cpp/bindings", |
- "//ui/gfx", |
- ] |
+ sources = [ |
+ "vr_device.cc", |
+ "vr_device.h", |
+ "vr_device_manager.cc", |
+ "vr_device_manager.h", |
+ "vr_device_provider.h", |
+ "vr_display_impl.cc", |
+ "vr_display_impl.h", |
+ "vr_export.h", |
+ "vr_service_impl.cc", |
+ "vr_service_impl.h", |
+ ] |
- defines = [ "DEVICE_VR_IMPLEMENTATION" ] |
+ public_deps = [ |
+ ":mojo_bindings", |
+ "//base", |
+ "//mojo/public/cpp/bindings", |
+ "//ui/gfx", |
+ ] |
- if (is_android) { |
- sources += [ |
- "android/gvr/gvr_delegate.cc", |
- "android/gvr/gvr_delegate.h", |
- "android/gvr/gvr_device.cc", |
- "android/gvr/gvr_device.h", |
- "android/gvr/gvr_device_provider.cc", |
- "android/gvr/gvr_device_provider.h", |
- "android/gvr/gvr_gamepad_data_fetcher.cc", |
- "android/gvr/gvr_gamepad_data_fetcher.h", |
- ] |
+ defines = [ "DEVICE_VR_IMPLEMENTATION" ] |
+ if (is_android && (current_cpu == "arm" || current_cpu == "arm64")) { |
+ sources += [ |
+ "android/gvr/gvr_delegate.cc", |
+ "android/gvr/gvr_delegate.h", |
+ "android/gvr/gvr_device.cc", |
+ "android/gvr/gvr_device.h", |
+ "android/gvr/gvr_device_provider.cc", |
+ "android/gvr/gvr_device_provider.h", |
+ "android/gvr/gvr_gamepad_data_fetcher.cc", |
+ "android/gvr/gvr_gamepad_data_fetcher.h", |
+ ] |
- deps += [ |
- "//device/gamepad", |
- "//third_party/WebKit/public:blink_headers", |
- ] |
- ldflags = [ "-landroid" ] |
- libs = [ "//third_party/gvr-android-sdk/libgvr_shim_static_${current_cpu}.a" ] |
- configs += [ "//third_party/gvr-android-sdk:libgvr_config" ] |
- } |
+ public_deps += [ |
+ "//device/gamepad", |
+ "//third_party/WebKit/public:blink_headers", |
+ ] |
+ ldflags = [ "-landroid" ] |
+ libs = |
+ [ "//third_party/gvr-android-sdk/libgvr_shim_static_${current_cpu}.a" ] |
+ configs += [ "//third_party/gvr-android-sdk:libgvr_config" ] |
} |
+} |
- static_library("fakes") { |
- testonly = true |
+static_library("fakes") { |
+ testonly = true |
- sources = [ |
- "test/fake_vr_device.cc", |
- "test/fake_vr_device.h", |
- "test/fake_vr_device_provider.cc", |
- "test/fake_vr_device_provider.h", |
- "test/fake_vr_display_impl_client.cc", |
- "test/fake_vr_display_impl_client.h", |
- "test/fake_vr_service_client.cc", |
- "test/fake_vr_service_client.h", |
- ] |
+ sources = [ |
+ "test/fake_vr_device.cc", |
+ "test/fake_vr_device.h", |
+ "test/fake_vr_device_provider.cc", |
+ "test/fake_vr_device_provider.h", |
+ "test/fake_vr_display_impl_client.cc", |
+ "test/fake_vr_display_impl_client.h", |
+ "test/fake_vr_service_client.cc", |
+ "test/fake_vr_service_client.h", |
+ ] |
- public_deps = [ |
- ":mojo_bindings", |
- ":vr", |
- "//base", |
- "//mojo/public/cpp/bindings", |
- ] |
- } |
+ public_deps = [ |
+ ":mojo_bindings", |
+ ":vr", |
+ "//base", |
+ "//mojo/public/cpp/bindings", |
+ ] |
} |
mojom("mojo_bindings") { |
sources = [ |
"vr_service.mojom", |
] |
+ |
+ public_deps = [ |
+ "//mojo/common:common_custom_types", |
+ ] |
+ |
+ export_class_attribute = "DEVICE_VR_EXPORT" |
+ export_define = "DEVICE_VR_IMPLEMENTATION=1" |
+ export_header = "device/vr/vr_export.h" |
} |