Update to use the correct logging library.
Test: mma compiles
Change-Id: Idb33dea5faaf1a5e54719c2a5a683d2d47e9b8e8
diff --git a/light/2.0/default/Light.cpp b/light/2.0/default/Light.cpp
index eb1f559..f52c6af 100644
--- a/light/2.0/default/Light.cpp
+++ b/light/2.0/default/Light.cpp
@@ -13,6 +13,10 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
+
+#define LOG_TAG "light"
+#include <android/log.h>
+
#include "Light.h"
namespace android {
diff --git a/light/2.0/vts/functional/Android.bp b/light/2.0/vts/functional/Android.bp
index c3475a6..b290b59 100644
--- a/light/2.0/vts/functional/Android.bp
+++ b/light/2.0/vts/functional/Android.bp
@@ -19,6 +19,7 @@
gtest: true,
srcs: ["light_hidl_hal_test.cpp"],
shared_libs: [
+ "libbase",
"liblog",
"libutils",
"android.hardware.light@2.0",
diff --git a/light/2.0/vts/functional/light_hidl_hal_test.cpp b/light/2.0/vts/functional/light_hidl_hal_test.cpp
index db67467..7c081e9 100644
--- a/light/2.0/vts/functional/light_hidl_hal_test.cpp
+++ b/light/2.0/vts/functional/light_hidl_hal_test.cpp
@@ -44,7 +44,7 @@
light = ILight::getService(LIGHT_SERVICE_NAME);
ASSERT_NE(light, nullptr);
- ALOGI("Test is remote: %d", light->isRemote());
+ LOG(INFO) << "Test is remote " << light->isRemote();
}
virtual void TearDown() override {}
@@ -98,6 +98,6 @@
::testing::AddGlobalTestEnvironment(new LightHidlEnvironment);
::testing::InitGoogleTest(&argc, argv);
int status = RUN_ALL_TESTS();
- ALOGI("Test result = %d", status);
+ LOG(INFO) << "Test result = " << status;
return status;
}