From a3df4a66dd49c299adb75397a2302801eba7426d Mon Sep 17 00:00:00 2001 From: "jk7744.park" Date: Sun, 1 Feb 2015 13:50:02 +0900 Subject: [PATCH] tizen 2.3 release --- modules_wearable/.nofile => .nofile | 0 modules_wearable/CMakeLists.txt => CMakeLists.txt | 0 .../dukgenerator.pc.in => dukgenerator.pc.in | 0 {modules_wearable/inc => inc}/dukgen.h | 0 modules_mobile/CMakeLists.txt | 64 ---------------------- modules_mobile/dukgenerator.pc.in | 13 ----- modules_mobile/inc/dukgen.h | 35 ------------ modules_mobile/packaging/dukgenerator.spec | 49 ----------------- modules_mobile/src/dukgen.c | 45 --------------- modules_wearable/packaging/dukgenerator.spec | 54 ------------------ packaging/dukgenerator.spec | 64 +--------------------- {modules_wearable/src => src}/dukgen.c | 0 12 files changed, 1 insertion(+), 323 deletions(-) rename modules_wearable/.nofile => .nofile (100%) rename modules_wearable/CMakeLists.txt => CMakeLists.txt (100%) rename modules_wearable/dukgenerator.pc.in => dukgenerator.pc.in (100%) rename {modules_wearable/inc => inc}/dukgen.h (100%) delete mode 100644 modules_mobile/CMakeLists.txt delete mode 100755 modules_mobile/dukgenerator.pc.in delete mode 100644 modules_mobile/inc/dukgen.h delete mode 100644 modules_mobile/packaging/dukgenerator.spec delete mode 100755 modules_mobile/src/dukgen.c delete mode 100644 modules_wearable/packaging/dukgenerator.spec rename {modules_wearable/src => src}/dukgen.c (100%) diff --git a/modules_wearable/.nofile b/.nofile similarity index 100% rename from modules_wearable/.nofile rename to .nofile diff --git a/modules_wearable/CMakeLists.txt b/CMakeLists.txt similarity index 100% rename from modules_wearable/CMakeLists.txt rename to CMakeLists.txt diff --git a/modules_wearable/dukgenerator.pc.in b/dukgenerator.pc.in similarity index 100% rename from modules_wearable/dukgenerator.pc.in rename to dukgenerator.pc.in diff --git a/modules_wearable/inc/dukgen.h b/inc/dukgen.h similarity index 100% rename from modules_wearable/inc/dukgen.h rename to inc/dukgen.h diff --git a/modules_mobile/CMakeLists.txt b/modules_mobile/CMakeLists.txt deleted file mode 100644 index 2c2ad84..0000000 --- a/modules_mobile/CMakeLists.txt +++ /dev/null @@ -1,64 +0,0 @@ -CMAKE_MINIMUM_REQUIRED(VERSION 2.6) -PROJECT(dukgenerator C) - -SET(PREFIX ${CMAKE_INSTALL_PREFIX}) -SET(EXEC_PREFIX "\${prefix}") -SET(LIBDIR "\${prefix}/lib") -SET(INCLUDEDIR "\${prefix}/include") - -INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR}/inc) - -SET(pc_requires " cryptsvc ") - -INCLUDE(FindPkgConfig) -pkg_check_modules(pkgs REQUIRED ${pc_requires}) - -FOREACH(flag ${pkgs_CFLAGS}) - SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}") -ENDFOREACH(flag) - -SET(source_dir "./src") -SET(include_dir "./inc") - -SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} -fvisibility=hidden") -SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${EXTRA_CFLAGS}") -SET(EXTRA_CXXFLAGS "${EXTRA_CXXFLAGS} ${EXTRA_CFLAGS}") - -################################################################################################################## -SET(SRCS - ${source_dir}/dukgen.c -) - -SET(libcryptsvc_LDFLAGS " -module -avoid-version ${pkgs_LDFLAGS} ") -SET(libcryptsvc_CFLAGS " ${CFLAGS} -fvisibility=hidden -g -fPIC -I${CMAKE_CURRENT_SOURCE_DIR}/inc ") -SET(libcryptsvc_CPPFLAGS " -DPIC ") - -#ADD_LIBRARY(${PROJECT_NAME} SHARED ${SRCS}) -ADD_LIBRARY(${PROJECT_NAME} ${SRCS}) -TARGET_LINK_LIBRARIES(${PROJECT_NAME} ${pkgs_LDFLAGS}) -SET_TARGET_PROPERTIES( - ${PROJECT_NAME} - PROPERTIES - VERSION ${FULLVER} - SOVERSION ${MAJORVER} -) -################################################################################################################## - -FIND_PROGRAM(UNAME NAMES uname) -EXEC_PROGRAM("${UNAME}" ARGS "-m" OUTPUT_VARIABLE "ARCH") -IF("${ARCH}" STREQUAL "arm") - ADD_DEFINITIONS("-DTARGET") - MESSAGE("add -DTARGET") -ENDIF("${ARCH}" STREQUAL "arm") - -SET(PC_NAME ${PROJECT_NAME}) -SET(PC_DESCRIPTION ${DESCRIPTION}) -SET(PC_LDFLAGS -l${PROJECT_NAME}) -SET(PC_REQUIRED ${pc_requires}) -CONFIGURE_FILE(${PROJECT_NAME}.pc.in ${PROJECT_NAME}.pc @ONLY) - -INSTALL(FILES ${PROJECT_NAME}.pc DESTINATION lib/pkgconfig) -INSTALL(TARGETS ${PROJECT_NAME} DESTINATION lib) -INSTALL(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/inc/ DESTINATION /usr/include) - -ADD_DEFINITIONS(-D_bool_cryptsvc) diff --git a/modules_mobile/dukgenerator.pc.in b/modules_mobile/dukgenerator.pc.in deleted file mode 100755 index 2cd5754..0000000 --- a/modules_mobile/dukgenerator.pc.in +++ /dev/null @@ -1,13 +0,0 @@ -# Package Information for pkg-config - -prefix=@PREFIX@ -libdir=@PREFIX@/lib -includedir=@PREFIX@/include - -Name: @PC_NAME@ -Description: @DESCRIPTION@ -Version: @FULLVER@ -Requires: @PC_REQUIRED@ -Libs: -L${libdir} @PC_LDFLAGS@ -Cflags: -I${includedir} - diff --git a/modules_mobile/inc/dukgen.h b/modules_mobile/inc/dukgen.h deleted file mode 100644 index 1317176..0000000 --- a/modules_mobile/inc/dukgen.h +++ /dev/null @@ -1,35 +0,0 @@ -// -// Copyright (c) 2013 Samsung Electronics Co., Ltd. -// -// Licensed under the Apache License, Version 2.0 (the License); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// - -#ifndef _DUK_GENERATOR_H_ -#define _DUK_GENERATOR_H_ - -#ifdef __cplusplus -extern "C" -{ -#endif - -__attribute__((visibility("hidden"))) -char* GetDeviceUniqueKey(char* pAppId, int idLen, int keyLen); - -#ifdef __cplusplus -} -#endif - -#endif //_DUK_GENERATOR_H_ - - - diff --git a/modules_mobile/packaging/dukgenerator.spec b/modules_mobile/packaging/dukgenerator.spec deleted file mode 100644 index b5cab3d..0000000 --- a/modules_mobile/packaging/dukgenerator.spec +++ /dev/null @@ -1,49 +0,0 @@ -Name: dukgenerator -Summary: nothing -Version: 1.0.0 -Release: 7 -Group: security -License: Apache License, Version 2.0 -Source0: %{name}-%{version}.tar.gz -BuildRequires: cmake - -BuildRequires: pkgconfig(openssl) -BuildRequires: pkgconfig(cryptsvc) - -%description - -%package devel -Summary: nothing -Group: security -Requires: %{name} = %{version}-%{release} - -%description devel - -%prep -%setup -q - -%build -MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'` -cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DFULLVER=%{version} -DMAJORVER=${MAJORVER} -DDESCRIPTION=%{summary} -make %{?jobs:-j%jobs} - - -%install -rm -rf %{buildroot} -#%make_install -%{__make} DESTDIR=%{?buildroot:%{buildroot}} INSTALL_ROOT=%{?buildroot:%{buildroot}} install -rm -f %{?buildroot:%{buildroot}}%{_infodir}/dir -find %{?buildroot:%{buildroot}} -regex ".*\\.la$" | xargs rm -f -- - -mkdir -p %{buildroot}/usr/share/license -cp LICENSE.APLv2 %{buildroot}/usr/share/license/%{name} - - -%files -%{_libdir}/*.a -%{_datadir}/license/%{name} - - -%files devel -%{_includedir}/* -%{_libdir}/pkgconfig/dukgenerator.pc diff --git a/modules_mobile/src/dukgen.c b/modules_mobile/src/dukgen.c deleted file mode 100755 index 86a2e4d..0000000 --- a/modules_mobile/src/dukgen.c +++ /dev/null @@ -1,45 +0,0 @@ -// -// Copyright (c) 2013 Samsung Electronics Co., Ltd. -// -// Licensed under the Apache License, Version 2.0 (the License); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// -// - -#include -#include -#include -#include -#include -#include -#include - -char* GetDeviceUniqueKey(char* pAppId, int idLen, int keyLen) -{ - unsigned char* pUniqueKey = NULL; - char* pDuk = NULL; - bool result = true; - - pUniqueKey = (unsigned char*)calloc(keyLen,1); - result = SecFrameGeneratePlatformUniqueKey((unsigned int)keyLen , pUniqueKey); - if(result == false) - { - free(pUniqueKey); - return NULL; - } - - pDuk = (char*)calloc(keyLen, 1); - PKCS5_PBKDF2_HMAC_SHA1(pAppId, idLen, (unsigned char*)pUniqueKey, keyLen, 1, keyLen, (unsigned char*)pDuk); - free(pUniqueKey); - - return pDuk; -} diff --git a/modules_wearable/packaging/dukgenerator.spec b/modules_wearable/packaging/dukgenerator.spec deleted file mode 100644 index eee018c..0000000 --- a/modules_wearable/packaging/dukgenerator.spec +++ /dev/null @@ -1,54 +0,0 @@ -Name: dukgenerator -Summary: nothing -Version: 1.0.0 -Release: 7 -Group: security -License: Apache License, Version 2.0 -Source0: %{name}-%{version}.tar.gz -BuildRequires: cmake - -BuildRequires: pkgconfig(openssl) -BuildRequires: pkgconfig(cryptsvc) - -%description - -%package devel -Summary: nothing -Group: security -Requires: %{name} = %{version}-%{release} - -%description devel - -%prep -%setup -q - -%build -%if 0%{?tizen_build_binary_release_type_eng} -export CFLAGS="$CFLAGS -DTIZEN_ENGINEER_MODE" -export CXXFLAGS="$CXXFLAGS -DTIZEN_ENGINEER_MODE" -export FFLAGS="$FFLAGS -DTIZEN_ENGINEER_MODE" -%endif -MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'` -cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DFULLVER=%{version} -DMAJORVER=${MAJORVER} -DDESCRIPTION=%{summary} -make %{?jobs:-j%jobs} - - -%install -rm -rf %{buildroot} -#%make_install -%{__make} DESTDIR=%{?buildroot:%{buildroot}} INSTALL_ROOT=%{?buildroot:%{buildroot}} install -rm -f %{?buildroot:%{buildroot}}%{_infodir}/dir -find %{?buildroot:%{buildroot}} -regex ".*\\.la$" | xargs rm -f -- - -mkdir -p %{buildroot}/usr/share/license -cp LICENSE.APLv2 %{buildroot}/usr/share/license/%{name} - - -%files -%{_libdir}/*.a -%{_datadir}/license/%{name} - - -%files devel -%{_includedir}/* -%{_libdir}/pkgconfig/dukgenerator.pc diff --git a/packaging/dukgenerator.spec b/packaging/dukgenerator.spec index 81197ae..eee018c 100644 --- a/packaging/dukgenerator.spec +++ b/packaging/dukgenerator.spec @@ -1,13 +1,10 @@ Name: dukgenerator Summary: nothing -Version: 1.0.1 +Version: 1.0.0 Release: 7 Group: security License: Apache License, Version 2.0 Source0: %{name}-%{version}.tar.gz - -%if "%{_repository}" == "wearable" - BuildRequires: cmake BuildRequires: pkgconfig(openssl) @@ -26,11 +23,6 @@ Requires: %{name} = %{version}-%{release} %setup -q %build -echo "########################################" -echo "TIZEN_PROFILE_WEARABLE" -echo "########################################" -cp -R modules_wearable/* . - %if 0%{?tizen_build_binary_release_type_eng} export CFLAGS="$CFLAGS -DTIZEN_ENGINEER_MODE" export CXXFLAGS="$CXXFLAGS -DTIZEN_ENGINEER_MODE" @@ -60,57 +52,3 @@ cp LICENSE.APLv2 %{buildroot}/usr/share/license/%{name} %files devel %{_includedir}/* %{_libdir}/pkgconfig/dukgenerator.pc - - -%else - -BuildRequires: cmake - -BuildRequires: pkgconfig(openssl) -BuildRequires: pkgconfig(cryptsvc) - -%description - -%package devel -Summary: nothing -Group: security -Requires: %{name} = %{version}-%{release} - -%description devel - -%prep -%setup -q - -%build -echo "########################################" -echo "TIZEN_PROFILE_MOBILE" -echo "########################################" -cp -R modules_mobile/* . - -MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'` -cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DFULLVER=%{version} -DMAJORVER=${MAJORVER} -DDESCRIPTION=%{summary} -make %{?jobs:-j%jobs} - - -%install -rm -rf %{buildroot} -#%make_install -%{__make} DESTDIR=%{?buildroot:%{buildroot}} INSTALL_ROOT=%{?buildroot:%{buildroot}} install -rm -f %{?buildroot:%{buildroot}}%{_infodir}/dir -find %{?buildroot:%{buildroot}} -regex ".*\\.la$" | xargs rm -f -- - -mkdir -p %{buildroot}/usr/share/license -cp LICENSE.APLv2 %{buildroot}/usr/share/license/%{name} - - -%files -%{_libdir}/*.a -%{_datadir}/license/%{name} - - -%files devel -%{_includedir}/* -%{_libdir}/pkgconfig/dukgenerator.pc - - -%endif diff --git a/modules_wearable/src/dukgen.c b/src/dukgen.c similarity index 100% rename from modules_wearable/src/dukgen.c rename to src/dukgen.c -- 2.7.4