remove dependency with ocramdon.h for base stack. 83/15683/5
authorjihwan.seo <jihwan.seo@samsung.com>
Thu, 15 Dec 2016 07:33:53 +0000 (16:33 +0900)
committerAshok Babu Channa <ashok.channa@samsung.com>
Thu, 22 Dec 2016 09:53:41 +0000 (09:53 +0000)
Change-Id: Iefaf746059acae16af190564cbd9bcf67cdd277f
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/15683
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
resource/csdk/connectivity/api/cacommon.h
resource/csdk/stack/include/octypes.h
service/easy-setup/mediator/richsdk/android/EasySetupCore/src/main/jni/Android.mk
service/notification/android/notification-service/src/main/jni/Android.mk
service/resource-container/android/resource-container/src/main/jni/Android.mk
service/resource-encapsulation/android/service/src/main/jni/Android.mk
tools/tizen/iotivity.spec

index 4da153e..629e660 100755 (executable)
@@ -47,8 +47,6 @@
 #include <mswsock.h>
 #endif
 
-#include "ocrandom.h"
-
 #ifdef __cplusplus
 extern "C"
 {
@@ -113,7 +111,12 @@ extern "C"
 /**
  *Maximum length of the remoteEndpoint identity.
  */
-#define CA_MAX_ENDPOINT_IDENTITY_LEN  UUID_STRING_SIZE
+#define CA_MAX_ENDPOINT_IDENTITY_LEN  CA_MAX_IDENTITY_SIZE
+
+/**
+ * Max identity size.
+ */
+#define CA_MAX_IDENTITY_SIZE (37)
 
 /**
  * option types - the highest option number 63.
@@ -287,7 +290,7 @@ typedef struct
     uint16_t                port;       // for IP
     char                    addr[MAX_ADDR_STR_SIZE_CA]; // address for all
     uint32_t                ifindex;    // usually zero for default interface
-    char                    deviceId[UUID_STRING_SIZE]; // device ID of remote device
+    char                    deviceId[CA_MAX_IDENTITY_SIZE]; // device ID of remote device
 #if defined (ROUTING_GATEWAY) || defined (ROUTING_EP)
     char                    routeData[MAX_ADDR_STR_SIZE_CA]; /**< GatewayId:ClientId of
                                                                     destination. **/
index d7a5695..b99bbdc 100755 (executable)
@@ -43,7 +43,7 @@ extern "C" {
 #define WITH_PRESENCE
 
 #include "ocpresence.h"
-#include "ocrandom.h"
+
 //-----------------------------------------------------------------------------
 // Defines
 //-----------------------------------------------------------------------------
@@ -332,6 +332,9 @@ extern "C" {
 /** Blocks of MAC address */
 #define MAC_ADDR_BLOCKS (6)
 
+/** Max identity size. */
+#define MAX_IDENTITY_SIZE (37)
+
 /** Universal unique identity size. */
 #define UUID_IDENTITY_SIZE (128/8)
 
@@ -676,7 +679,7 @@ typedef struct
     uint16_t id_length;
 
     /** Array of end point identity.*/
-    unsigned char id[UUID_STRING_SIZE];
+    unsigned char id[MAX_IDENTITY_SIZE];
 } OCIdentity;
 
 /**
@@ -713,7 +716,7 @@ typedef struct
     char                    routeData[MAX_ADDR_STR_SIZE];
 
     /** destination DeviceID.*/
-    char                    deviceId[UUID_STRING_SIZE];
+    char                    deviceId[MAX_IDENTITY_SIZE];
 
 } OCDevAddr;
 
index 8ee1ba8..46f6f50 100755 (executable)
@@ -75,7 +75,6 @@ LOCAL_C_INCLUDES := $(LOCAL_PATH) \
                                        $(LOCAL_PATH)/../../../../../../../../../resource/c_common \
                                        $(LOCAL_PATH)/../../../../../../../../../resource/oc_logger/include \
                                        $(LOCAL_PATH)/../../../../../../../../../resource/c_common/oic_malloc/include \
-                                       $(LOCAL_PATH)/../../../../../../../../../resource/c_common/ocrandom/include \
                                        $(LOCAL_PATH)/../../../../../../../../../resource/csdk/connectivity/api \
                                        $(LOCAL_PATH)/../../../../../../../../../resource/csdk/stack/include \
                                        $(LOCAL_PATH)/../../../../../../../../../resource/csdk/logger/include \
index 6e6a41b..515878d 100755 (executable)
@@ -41,7 +41,6 @@ LOCAL_C_INCLUDES := $(OIC_SRC_DIR)/resource/csdk/stack/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/csdk/logger/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/c_common
-LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/c_common/ocrandom/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/c_common/oic_string/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/oc_logger/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/extlibs/boost/boost_1_58_0
@@ -92,7 +91,6 @@ LOCAL_C_INCLUDES := $(OIC_SRC_DIR)/resource/csdk/stack/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/csdk/logger/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/c_common
-LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/c_common/ocrandom/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/c_common/oic_string/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/oc_logger/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/extlibs/boost/boost_1_58_0
index 734b04a..d5620f6 100644 (file)
@@ -37,7 +37,6 @@ LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/csdk/stack/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/csdk/logger/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/oc_logger/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/c_common
-LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/c_common/ocrandom/include
 
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/extlibs/
 
index b6ac280..9ab9118 100644 (file)
@@ -25,7 +25,6 @@ LOCAL_MODULE := rcs_jni
 LOCAL_C_INCLUDES := $(LOCAL_PATH)/util
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/c_common
-LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/c_common/ocrandom/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/resource/csdk/stack/include
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/extlibs/boost/boost_1_58_0
 LOCAL_C_INCLUDES += $(OIC_SRC_DIR)/service/resource-encapsulation/include
index b7338c9..d7d9a25 100644 (file)
@@ -264,7 +264,6 @@ cp ./resource/csdk/security/provisioning/sample/oic_svr_db_server_randompin.dat
 %endif
 
 cp resource/c_common/*.h %{buildroot}%{_includedir}
-cp resource/c_common/ocrandom/include/*.h %{buildroot}%{_includedir}
 cp resource/csdk/stack/include/*.h %{buildroot}%{_includedir}
 cp resource/csdk/logger/include/*.h %{buildroot}%{_includedir}