pjproject-bundled: Use AST_DEVMODE for conditional compilation.
authorCorey Farrell <git@cfware.com>
Fri, 16 Nov 2018 12:20:11 +0000 (07:20 -0500)
committerCorey Farrell <git@cfware.com>
Fri, 16 Nov 2018 13:26:32 +0000 (08:26 -0500)
We previously allowed resample and g711 codecs to be built when
TEST_FRAMEWORK was enabled.  This could cause errors if the testsuite
was run without this option enabled.  Switch the build system to allow
those codecs to be built when --enable-dev-mode is used.  This removes a
chance for strange testsuite errors from use of an inadequate pjsua
binary.

Change-Id: Iee8a3613cdb711fa7e7d217c5a775a575907ae22

configure
third-party/pjproject/Makefile
third-party/pjproject/Makefile.rules
third-party/pjproject/configure.m4

index 47cf7e7..ee3eb4b 100755 (executable)
--- a/configure
+++ b/configure
@@ -9411,7 +9411,7 @@ $as_echo "configuring" >&6; }
        fi
 
        export TAR PATCH SED NM EXTERNALS_CACHE_DIR AST_DOWNLOAD_CACHE DOWNLOAD_TO_STDOUT DOWNLOAD_TIMEOUT DOWNLOAD MD5 CAT CUT GREP
-       export NOISY_BUILD
+       export NOISY_BUILD AST_DEVMODE
        ${GNU_MAKE} --quiet --no-print-directory -C ${PJPROJECT_DIR} \
                PJPROJECT_CONFIGURE_OPTS="$PJPROJECT_CONFIGURE_OPTS" \
                EXTERNALS_CACHE_DIR="${EXTERNALS_CACHE_DIR:-${AST_DOWNLOAD_CACHE}}" \
index c761cb5..97835e4 100644 (file)
@@ -54,14 +54,12 @@ ifeq ($(SPECIAL_TARGETS),)
         include source/build.mak
         CF := $(filter-out -W%,$(CC_CFLAGS))
         CF := $(filter-out -I%,$(CF))
-        ifeq ($(findstring TEST_FRAMEWORK,$(MENUSELECT_CFLAGS)),TEST_FRAMEWORK)
+        ifeq ($(AST_DEVMODE),yes)
             apps := source/pjsip-apps/bin/pjsua-$(TARGET_NAME) source/pjsip-apps/bin/pjsystest-$(TARGET_NAME)
             TARGETS += $(apps)
             ifneq ($(PYTHONDEV_LIB),)
                 TARGETS += source/pjsip-apps/src/python/_pjsua.so
             endif
-        endif
-        ifeq ($(AST_DEVMODE),yes)
             CF += -DPJPROJECT_BUNDLED_ASSERTIONS=yes
         endif
         MALLOC_DEBUG_LIBS = source/pjsip-apps/lib/libasterisk_malloc_debug.a
index 6a48e86..e76a753 100644 (file)
@@ -39,7 +39,7 @@ PJPROJECT_CONFIG_OPTS = $(PJPROJECT_CONFIGURE_OPTS) --prefix=/opt/pjproject \
        --without-external-pa \
        --without-external-srtp
 
-ifeq ($(findstring TEST_FRAMEWORK,$(MENUSELECT_CFLAGS)),)
+ifneq ($(AST_DEVMODE),yes)
     PJPROJECT_CONFIG_OPTS += --disable-resample --disable-g711-codec
 endif
 
index 9e89098..d021152 100644 (file)
@@ -73,7 +73,7 @@ AC_DEFUN([_PJPROJECT_CONFIGURE],
        fi
 
        export TAR PATCH SED NM EXTERNALS_CACHE_DIR AST_DOWNLOAD_CACHE DOWNLOAD_TO_STDOUT DOWNLOAD_TIMEOUT DOWNLOAD MD5 CAT CUT GREP
-       export NOISY_BUILD
+       export NOISY_BUILD AST_DEVMODE
        ${GNU_MAKE} --quiet --no-print-directory -C ${PJPROJECT_DIR} \
                PJPROJECT_CONFIGURE_OPTS="$PJPROJECT_CONFIGURE_OPTS" \
                EXTERNALS_CACHE_DIR="${EXTERNALS_CACHE_DIR:-${AST_DOWNLOAD_CACHE}}" \