mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-05-03 20:46:28 +00:00
autotools: use bctoolbox-tester instead of cunit
This commit is contained in:
parent
bc057a4bf9
commit
c33219b33b
3 changed files with 13 additions and 38 deletions
|
|
@ -244,7 +244,7 @@ pkg: $(MACAPPNAME)
|
|||
cp ${srcdir}/pixmaps/linphone.png ./packaging
|
||||
pkgbuild --install-location /Applications --scripts ${srcdir}/build/macos/pkg-scripts --component $(MACAPPNAME) ./packaging/linphone.pkg
|
||||
productbuild --resources . --distribution ${srcdir}/build/macos/pkg-distribution.xml --package-path ./packaging $(MACAPPPKG)
|
||||
|
||||
|
||||
signed-pkg: pkg
|
||||
mv $(MACAPPPKG) $(MACAPPPKG).tmp
|
||||
productsign --sign "$(BUNDLE_SIGNING_ID)" $(MACAPPPKG).tmp $(MACAPPPKG)
|
||||
|
|
@ -259,7 +259,7 @@ clean-local:
|
|||
discovery:
|
||||
touch specs.c
|
||||
$(CC) --include $(top_builddir)/config.h \
|
||||
$(TUNNEL_CFLAGS) $(CFLAGS) $(MEDIASTREAMER2_CFLAGS) $(ORTP_CFLAGS) $(SIPSTACK_CFLAGS) $(CUNIT_CFLAGS) -E -P -v -dD specs.c
|
||||
$(TUNNEL_CFLAGS) $(CFLAGS) $(MEDIASTREAMER2_CFLAGS) $(ORTP_CFLAGS) $(SIPSTACK_CFLAGS) $(BCTOOLBOXTESTER_CFLAGS) -E -P -v -dD specs.c
|
||||
|
||||
.PHONY: $(MACAPPNAME) pkg
|
||||
|
||||
|
|
|
|||
33
configure.ac
33
configure.ac
|
|
@ -1000,36 +1000,11 @@ AC_ARG_ENABLE(tests,
|
|||
)
|
||||
AM_CONDITIONAL(ENABLE_TESTS, test x$tests_enabled = xyes)
|
||||
|
||||
PKG_CHECK_MODULES(CUNIT, cunit, [found_cunit=yes],[found_cunit=no])
|
||||
PKG_CHECK_MODULES(BCTOOLBOXTESTER, bctoolbox-tester, [found_pkg_config_bctoolboxtester=yes],[found_pkg_config_bctoolboxtester=no])
|
||||
|
||||
if test "$found_cunit" = "no" ; then
|
||||
AC_CHECK_HEADERS(CUnit/CUnit.h,
|
||||
[
|
||||
AC_CHECK_LIB(cunit,CU_add_suite,[
|
||||
found_cunit=yes
|
||||
CUNIT_LIBS+=" -lcunit"
|
||||
])
|
||||
|
||||
])
|
||||
fi
|
||||
|
||||
case "$target_os" in
|
||||
*darwin*)
|
||||
#hack for macport
|
||||
CUNIT_LIBS+=" -lncurses"
|
||||
;;
|
||||
esac
|
||||
AM_CONDITIONAL([BUILD_CUNIT_TESTS], [test x$found_cunit = xyes && test x$tests_enabled != xfalse])
|
||||
if test "$found_cunit" = "no" ; then
|
||||
AC_MSG_WARN([Could not find cunit framework, tests are not compiled.])
|
||||
else
|
||||
AC_CHECK_LIB(cunit,CU_get_suite,[
|
||||
AC_DEFINE(HAVE_CU_GET_SUITE,1,[defined when CU_get_suite is available])
|
||||
],[foo=bar],[$CUNIT_LIBS])
|
||||
|
||||
AC_CHECK_LIB(cunit,CU_curses_run_tests,[
|
||||
AC_DEFINE(HAVE_CU_CURSES,1,[defined when CU_curses_run_tests is available])
|
||||
],[foo=bar],[$CUNIT_LIBS])
|
||||
AM_CONDITIONAL([ENABLE_TESTS], [test x$found_pkg_config_bctoolboxtester = xyes && test x$tests_enabled != xfalse])
|
||||
if test "$found_pkg_config_bctoolboxtester" = "no" ; then
|
||||
AC_MSG_WARN([Could not find bctoolbox-tester wrapper, tests are not compiled.])
|
||||
fi
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -83,7 +83,7 @@ EXTRA_DIST = tester_hosts\
|
|||
|
||||
|
||||
|
||||
if BUILD_CUNIT_TESTS
|
||||
if ENABLE_TESTS
|
||||
|
||||
sounddir = $(datadir)/liblinphone_tester/sounds
|
||||
sound_DATA = $(TESTER_SOUNDS)
|
||||
|
|
@ -131,12 +131,12 @@ liblinphonetester_la_SOURCES = \
|
|||
tunnel_tester.c \
|
||||
tester.c \
|
||||
upnp_tester.c \
|
||||
video_tester.c
|
||||
video_tester.c
|
||||
|
||||
liblinphonetester_ladir = $(includedir)/linphone
|
||||
|
||||
liblinphonetester_la_LDFLAGS= -no-undefined
|
||||
liblinphonetester_la_LIBADD= ../coreapi/liblinphone.la $(CUNIT_LIBS)
|
||||
liblinphonetester_la_LIBADD= ../coreapi/liblinphone.la $(BCTOOLBOXTESTER_LIBS)
|
||||
|
||||
liblinphone_tester_bindir = $(bindir)/liblinphone_tester
|
||||
liblinphone_testerdir = $(datadir)/liblinphone_tester
|
||||
|
|
@ -146,7 +146,7 @@ dist_liblinphone_tester_DATA = tester_hosts messages.db
|
|||
|
||||
AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)/coreapi -I$(top_srcdir)/tester/common
|
||||
AM_CFLAGS = -DBC_CONFIG_FILE=\"config.h\" $(STRICT_OPTIONS) $(STRICT_OPTIONS_CC) \
|
||||
-DIN_LINPHONE $(ORTP_CFLAGS) $(MEDIASTREAMER_CFLAGS) $(CUNIT_CFLAGS) \
|
||||
-DIN_LINPHONE $(ORTP_CFLAGS) $(MEDIASTREAMER_CFLAGS) $(BCTOOLBOXTESTER_CFLAGS) \
|
||||
$(BELLESIP_CFLAGS) $(LIBXML2_CFLAGS) $(SQLITE3_CFLAGS)
|
||||
|
||||
if BUILD_GTK_UI
|
||||
|
|
@ -173,9 +173,9 @@ endif
|
|||
test: liblinphone_tester
|
||||
./liblinphone_tester --config $(abs_srcdir) $(TEST_OPTIONS)
|
||||
|
||||
else !BUILD_CUNIT_TESTS
|
||||
else !ENABLE_TESTS
|
||||
|
||||
test:
|
||||
@echo "CUnit must be installed to be able to run the tests!"
|
||||
@echo "bctoolbox-tester must be installed to be able to run the tests!"
|
||||
|
||||
endif !BUILD_CUNIT_TESTS
|
||||
endif !ENABLE_TESTS
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue