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

Side by Side Diff: device/generic_sensor/BUILD.gn

Issue 2370343002: [sensors] Ambient light sensor implementation for ChromeOS and Linux. (Closed)
Patch Set: ctor and dtor for deleter Created 4 years, 2 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 unified diff | Download patch
OLDNEW
1 # Copyright 2016 The Chromium Authors. All rights reserved. 1 # Copyright 2016 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import("//build/config/features.gni") 5 import("//build/config/features.gni")
6 6
7 if (is_android) { 7 if (is_android) {
8 import("//build/config/android/rules.gni") # For generate_jni(). 8 import("//build/config/android/rules.gni") # For generate_jni().
9 } 9 }
10 10
(...skipping 21 matching lines...) Expand all
32 32
33 if (is_android) { 33 if (is_android) {
34 sources += [ 34 sources += [
35 "android/sensors_jni_registrar.cc", 35 "android/sensors_jni_registrar.cc",
36 "android/sensors_jni_registrar.h", 36 "android/sensors_jni_registrar.h",
37 ] 37 ]
38 sources -= [ "platform_sensor_provider_default.cc" ] 38 sources -= [ "platform_sensor_provider_default.cc" ]
39 39
40 deps += [ ":jni_headers" ] 40 deps += [ ":jni_headers" ]
41 } 41 }
42
43 if (is_chromeos || is_linux) {
44 sources += [
45 "ambient_light_reader_iio.cc",
46 "ambient_light_reader_iio.h",
47 "platform_sensor_ambient_light_iio.cc",
48 "platform_sensor_ambient_light_iio.h",
49 "platform_sensor_provider_iio.cc",
50 "polling_platform_sensor.cc",
51 "polling_platform_sensor.h",
52 ]
53
54 sources -= [ "platform_sensor_provider_default.cc" ]
55 }
42 } 56 }
43 57
44 if (is_android) { 58 if (is_android) {
45 device_sensors_jni_sources = [ 59 device_sensors_jni_sources = [
46 "android/java/src/org/chromium/device/sensors/PlatformSensor.java", 60 "android/java/src/org/chromium/device/sensors/PlatformSensor.java",
47 "android/java/src/org/chromium/device/sensors/PlatformSensorProvider.java", 61 "android/java/src/org/chromium/device/sensors/PlatformSensorProvider.java",
48 ] 62 ]
49 63
50 generate_jni("jni_headers") { 64 generate_jni("jni_headers") {
51 sources = device_sensors_jni_sources 65 sources = device_sensors_jni_sources
52 jni_package = "device" 66 jni_package = "device"
53 } 67 }
54 68
55 android_library("java") { 69 android_library("java") {
56 java_files = device_sensors_jni_sources 70 java_files = device_sensors_jni_sources
57 71
58 deps = [ 72 deps = [
59 "//base:base_java", 73 "//base:base_java",
60 "//device/generic_sensor/public/interfaces:interfaces_java", 74 "//device/generic_sensor/public/interfaces:interfaces_java",
61 ] 75 ]
62 } 76 }
63 } 77 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698