Fix build error.
authorINSUN PYO <insun.pyo@samsung.com>
Mon, 3 Feb 2020 00:03:18 +0000 (09:03 +0900)
committerINSUN PYO <insun.pyo@samsung.com>
Mon, 3 Feb 2020 00:04:35 +0000 (09:04 +0900)
A macro ARRAY_SIZE is defined in libdevice-node, and libdevice-node removes it."

Change-Id: Id763d7f4008a0ce774f2ba263c8ba8817731e735

hw/external_connection/external_connection.c

index f1106ac..f317b52 100644 (file)
 #include <hw/shared.h>
 #include "../dbus.h"
 
+#ifndef ARRAY_SIZE
+#define ARRAY_SIZE(name) (sizeof(name)/sizeof(name[0]))
+#endif
+
 #define EXTCON_BUS      "org.tizen.system.deviced"
 #define EXTCON_OBJECT   "/Org/Tizen/System/DeviceD/ExtCon"
 #define EXTCON_IFACE    EXTCON_BUS".ExtCon"