From 95626c3cd91c3b6b53d0f36e57044cbf662f3ed4 Mon Sep 17 00:00:00 2001 From: Baptiste DURAND Date: Tue, 28 May 2013 16:17:49 +0200 Subject: Fix x86_64 build-install Compliance -> Fix hardcoded path -> MmsPluginStorage.cpp: change variable type from unsinged int to size_t to avoid: cannot convert 'unsigned int*' to 'size_t* {aka long unsigned int*}' for argument '2' to 'char* _MsgMmsSerializeMessageData(const MMS_MESSAGE_DATA_S*, size_t*)' --- CMakeLists.txt | 2 +- config/plugin.cfg | 7 ------- config/plugin.cfg.in | 7 +++++++ packaging/msg-service.spec | 2 +- plugin/mms_plugin/MmsPluginStorage.cpp | 6 +++--- 5 files changed, 12 insertions(+), 12 deletions(-) delete mode 100755 config/plugin.cfg create mode 100755 config/plugin.cfg.in diff --git a/CMakeLists.txt b/CMakeLists.txt index c0c09a8..239d555 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -43,7 +43,7 @@ INSTALL(FILES ${MAPI-HEADERS} DESTINATION include/msg-service) ########################################################## # Install etc Files ########################################################## - +CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/config/plugin.cfg.in ${CMAKE_CURRENT_SOURCE_DIR}/config/plugin.cfg @ONLY) INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/config/plugin.cfg DESTINATION /usr/share/msg-service) SET(RINGTONE-FILES diff --git a/config/plugin.cfg b/config/plugin.cfg deleted file mode 100755 index 498d80d..0000000 --- a/config/plugin.cfg +++ /dev/null @@ -1,7 +0,0 @@ -[sms-plugin] -type=sms -path=/usr/lib/libmsg_sms_plugin.so - -[mms-plugin] -type=mms -path=/usr/lib/libmsg_mms_plugin.so diff --git a/config/plugin.cfg.in b/config/plugin.cfg.in new file mode 100755 index 0000000..725d2b8 --- /dev/null +++ b/config/plugin.cfg.in @@ -0,0 +1,7 @@ +[sms-plugin] +type=sms +path=@LIB_INSTALL_DIR@/libmsg_sms_plugin.so + +[mms-plugin] +type=mms +path=@LIB_INSTALL_DIR@/libmsg_mms_plugin.so diff --git a/packaging/msg-service.spec b/packaging/msg-service.spec index 68f4a91..2ba2bb5 100755 --- a/packaging/msg-service.spec +++ b/packaging/msg-service.spec @@ -355,7 +355,7 @@ chmod 660 /opt/usr/dbspace/.msg_service.db-journal mkdir -p /opt/usr/data/msg-service chgrp db_msg_service /opt/usr/data/msg-service -if [ -f /usr/lib/rpm-plugins/msm.so ] +if [ -f %{_libdir}/rpm-plugins/msm.so ] then chsmack -a 'msg-service::db' /opt/usr/dbspace/.msg_service.db* chsmack -a "_" -e "_" /etc/rc.d/init.d/msg-server diff --git a/plugin/mms_plugin/MmsPluginStorage.cpp b/plugin/mms_plugin/MmsPluginStorage.cpp index d99d4df..91950ca 100755 --- a/plugin/mms_plugin/MmsPluginStorage.cpp +++ b/plugin/mms_plugin/MmsPluginStorage.cpp @@ -478,7 +478,7 @@ msg_error_t MmsPluginStorage::plgGetMmsMessage(MSG_MESSAGE_INFO_S *pMsg, MSG_SEN MMS_MESSAGE_DATA_S tempMmsMsg = {0,}; MMS_MESSAGE_DATA_S *pMmsMsg = &tempMmsMsg; int partCnt = 0; - unsigned int nSize = 0; + size_t nSize = 0; MsgType partHeader; MmsAttrib pMmsAttrib; @@ -1425,8 +1425,8 @@ msg_error_t MmsPluginStorage::plgGetMmsMessage(MSG_MESSAGE_INFO_S *pMsg, MSG_SEN msg_error_t err = MSG_SUCCESS; MMS_MESSAGE_DATA_S tempMmsMsgData = {0,}; MMS_MESSAGE_DATA_S *pMmsMsg = &tempMmsMsgData; - - unsigned int nSize = 0; + + size_t nSize = 0; bool bMultipartRelated = false; bzero(pMmsMsg, sizeof(MMS_MESSAGE_DATA_S)); -- cgit v1.2.3