Commit 79c58c14 authored by jehan's avatar jehan

fix cpim tester on android

parent 835d54ad
......@@ -402,7 +402,7 @@ if(ENABLE_STATIC)
)
endif()
if(ENABLE_SHARED)
set(LINPHONE_RESOURCES "${CMAKE_SOURCE_DIR}/share/cpim_grammar")
set(LINPHONE_RESOURCES "${CMAKE_CURRENT_SOURCE_DIR}/../share/cpim_grammar") #keep it relative to current dir to allow CMakeList inclusion
add_library(linphone SHARED ${LINPHONE_RESOURCES} ${LINPHONE_HEADER_FILES}
${LINPHONE_CXX_OBJECTS_PRIVATE_HEADER_FILES} ${LINPHONE_CXX_OBJECTS_SOURCE_FILES} ${LINPHONE_OBJC_SOURCE_FILES}
$<TARGET_OBJECTS:linphone-coreapi>
......
......@@ -20,7 +20,7 @@
#
############################################################################
set(OTHER_LIBS_FOR_TESTER ${BCTOOLBOX_LIBRARIES} ${ORTP_LIBRARIES} ${MEDIASTREAMER2_LIBRARIES} ${BELLESIP_LIBRARIES} ${XML2_LIBRARIES} ${XSD_LIBRARIES})
set(OTHER_LIBS_FOR_TESTER ${BCTOOLBOX_LIBRARIES} ${ORTP_LIBRARIES} ${MEDIASTREAMER2_LIBRARIES} ${BELLESIP_LIBRARIES} ${XML2_LIBRARIES} ${XSD_LIBRARIES} ${BELR_LIBRARIES})
if(INTL_FOUND)
list(APPEND OTHER_LIBS_FOR_TESTER ${INTL_LIBRARIES})
endif()
......
......@@ -23,7 +23,7 @@
#include "content/content-type.h"
#include "content/content.h"
#include "core/core.h"
#include "belr/grammarbuilder.h"
// TODO: Remove me later.
#include "private.h"
......@@ -151,6 +151,7 @@ static void parse_message_with_generic_header_parameters () {
}
static void build_message () {
Cpim::Message message;
// Set message headers.
......@@ -310,7 +311,12 @@ test_t cpim_tests[] = {
TEST_NO_TAG("CPIM chat message modifier with multipart body", cpim_chat_message_modifier_with_multipart_body)
};
static int suite_begin(void) {
//Supposed to be done by platform helper, but in this case, we don't have it"
belr::GrammarLoader::get().load(bc_tester_res("share/belr/grammars/cpim_grammars"));
return 0;
}
test_suite_t cpim_test_suite = {
"Cpim", NULL, NULL, liblinphone_tester_before_each, liblinphone_tester_after_each,
"Cpim", suite_begin, NULL, liblinphone_tester_before_each, liblinphone_tester_after_each,
sizeof(cpim_tests) / sizeof(cpim_tests[0]), cpim_tests
};
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment