Sync with the tizen 3.0
authorSung-jae Park <nicesj.park@samsung.com>
Tue, 5 Nov 2013 07:57:35 +0000 (16:57 +0900)
committerSung-jae Park <nicesj.park@samsung.com>
Tue, 5 Nov 2013 07:57:56 +0000 (16:57 +0900)
Change-Id: I3a934684888ae00e66b9d374940ef7eb267a3582

CMakeLists.txt
com-core.pc.in
packaging/libcom-core.changes [new file with mode: 0644]
packaging/libcom-core.manifest [moved from libcom-core.manifest with 100% similarity]
packaging/libcom-core.spec
src/com-core_packet-router.c
src/com-core_thread.c

index 02448be..5bca4fe 100644 (file)
@@ -4,7 +4,7 @@ PROJECT(com-core C)
 SET(PREFIX ${CMAKE_INSTALL_PREFIX})
 SET(EXEC_PREFIX "\${prefix}")
 SET(PROJECT_NAME "${PROJECT_NAME}")
-SET(LIBDIR "\${exec_prefix}/lib")
+SET(LIBDIR ${LIB_INSTALL_DIR})
 SET(INCLUDEDIR "\${prefix}/include/${PROJECT_NAME}")
 SET(VERSION_MAJOR 0)
 SET(VERSION "${VERSION_MAJOR}.0.1")
@@ -48,8 +48,8 @@ TARGET_LINK_LIBRARIES(${PROJECT_NAME} ${pkgs_LDFLAGS})
 CONFIGURE_FILE(${PROJECT_NAME}.pc.in ${PROJECT_NAME}.pc @ONLY)
 SET_DIRECTORY_PROPERTIES(PROPERTIES ADDITIONAL_MAKE_CLEAN_FILES "${PROJECT_NAME}.pc")
 
-INSTALL(TARGETS ${PROJECT_NAME} DESTINATION lib)
-INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}.pc DESTINATION lib/pkgconfig)
+INSTALL(TARGETS ${PROJECT_NAME} DESTINATION ${LIB_INSTALL_DIR})
+INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}.pc DESTINATION ${LIB_INSTALL_DIR}/pkgconfig)
 INSTALL(FILES ${CMAKE_SOURCE_DIR}/include/secure_socket.h DESTINATION include/${PROJECT_NAME})
 INSTALL(FILES ${CMAKE_SOURCE_DIR}/include/com-core.h DESTINATION include/${PROJECT_NAME})
 INSTALL(FILES ${CMAKE_SOURCE_DIR}/include/com-core_packet.h DESTINATION include/${PROJECT_NAME})
index e1f99da..2bd9228 100644 (file)
@@ -1,6 +1,6 @@
 prefix=@PREFIX@
 exec_prefix=@EXEC_PREFIX@
-libdir=@LIBDIR@
+libdir=@LIB_INSTALL_DIR@
 includedir=@INCLUDEDIR@
 
 Name: com-core
diff --git a/packaging/libcom-core.changes b/packaging/libcom-core.changes
new file mode 100644 (file)
index 0000000..47713d7
--- /dev/null
@@ -0,0 +1,9 @@
+* Thu Sep 05 2013 Rusty Lynch <rusty.lynch@intel.com> accepted/tizen/20130710.221527@99bbffd
+- Add systemd socket activation support for secure sockets
+
+* Thu Sep 05 2013 Rusty Lynch <rusty.lynch@intel.com> accepted/tizen/20130710.221527@99bbffd
+- Add systemd socket activation support for secure sockets
+
+* Wed May 29 2013 Xavier Roche <xavrock.os@gmail.com> accepted/tizen/20130520.100914@a1a091c
+- Fix x86_64 build-install compliance
+
index 2b71a7d..a097a5a 100644 (file)
@@ -2,26 +2,28 @@ Name: libcom-core
 Summary: Library for the light-weight IPC 
 Version: 0.5.3
 Release: 1
-Group: HomeTF/Framework
-License: Apache License
+Group: Base/IPC
+License: Apache-2.0
 Source0: %{name}-%{version}.tar.gz
+Source1001:    libcom-core.manifest
 BuildRequires: cmake, gettext-tools, coreutils
 BuildRequires: pkgconfig(dlog)
 BuildRequires: pkgconfig(glib-2.0)
 
 %description
-Light-weight IPC supporting library
+Light-weight IPC supporting library for Tizen
 
 %package devel
-Summary: Files for using API for light-weight IPC.
+Summary: Files for using API for light-weight IPC
 Group: Development/Libraries
 Requires: %{name} = %{version}-%{release}
 
 %description devel
-Light-weight IPC supporting library (dev)
+Light-weight IPC supporting library for Tizen (dev)
 
 %prep
 %setup -q
+cp %{SOURCE1001} .
 
 %build
 %if 0%{?tizen_build_binary_release_type_eng}
@@ -30,7 +32,7 @@ export CXXFLAGS="${CXXFLAGS} -DTIZEN_ENGINEER_MODE"
 export FFLAGS="${FFLAGS} -DTIZEN_ENGINEER_MODE"
 %endif
 
-cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%cmake .
 make %{?jobs:-j%jobs}
 
 %install
@@ -38,15 +40,18 @@ rm -rf %{buildroot}
 %make_install
 mkdir -p %{buildroot}/%{_datarootdir}/license
 
-%post
+%post -n libcom-core -p /sbin/ldconfig
+
+%postun -n libcom-core -p /sbin/ldconfig
 
 %files -n libcom-core
-%manifest libcom-core.manifest
+%manifest %{name}.manifest
 %defattr(-,root,root,-)
 %{_libdir}/*.so*
 %{_datarootdir}/license/*
 
 %files devel
+%manifest %{name}.manifest
 %defattr(-,root,root,-)
 %{_includedir}/com-core/com-core.h
 %{_includedir}/com-core/packet.h
index b3f7b1e..ce582f7 100644 (file)
@@ -585,7 +585,7 @@ static void *send_main(void *data)
                packet_destroy(packet);
        }
 
-       return (void *)ret;
+       return (void *)(unsigned long)ret;
 }
 
 /*!
@@ -1220,7 +1220,7 @@ static void *server_main(void *data)
        ctx.pid = (pid_t)-1;
 
        ret = router_common_main(router, client->handle, &ctx);
-       return (void *)ret;
+       return (void *)(unsigned long)ret;
 }
 
 /*!
@@ -1240,7 +1240,7 @@ static void *client_main(void *data)
        ctx.pid = (pid_t)-1;
 
        ret = router_common_main(router, router->handle, &ctx);
-       return (void *)ret;
+       return (void *)(unsigned long)ret;
 }
 
 /*!
index b6d65bc..6a574e1 100644 (file)
@@ -159,9 +159,9 @@ static inline void terminate_thread(struct tcb *tcb)
        status = pthread_join(tcb->thid, &res);
        if (status != 0) {
                ErrPrint("Join: %s\n", strerror(status));
-       }
-       else
+       } else {
                ErrPrint("Thread returns: %d\n", (int)res);
+       }
 
        dlist_foreach_safe(tcb->chunk_list, l, n, chunk) {
                /*!
@@ -402,7 +402,7 @@ static void *client_cb(void *data)
                ErrPrint("write: %s\n", strerror(errno));
        }
 
-       return (void *)ret;
+       return (void *)(unsigned long)ret;
 }
 
 /*!