<p>Joshua Colp <strong>submitted</strong> this change.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/17881">View Change</a></p><div style="white-space:pre-wrap">Approvals:
Joshua Colp: Looks good to me, but someone else must approve; Approved for Submit
George Joseph: Looks good to me, approved
</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">build: Fix issues building pjproject<br><br>The change to allow easier hacking on bundled pjproject created<br>a few issues:<br><br>* The new Makefile was trying to run the bundled make even if<br> PJPROJECT_BUNDLED=no. third-party/Makefile now checks for<br> PJPROJECT_BUNDLED and JANSSON_BUNDLED and skips them if they<br> are "no".<br><br>* When building with bundled, config_site.h was being copied<br> only if a full make or a "make main" was done. A "make res"<br> would fail all the pjsip modules because they couldn't find<br> config_site.h. The Makefile now copies config_site.h and<br> asterisk_malloc_debug.h into the pjproject source tree<br> when it's "configure" is performed. This is how it used<br> to be before the big change.<br><br>ASTERISK-29858<br><br>Change-Id: I9427264fa3cb8b3f59a95e5f9693eac236a6f76d<br>---<br>M third-party/Makefile<br>M third-party/pjproject/Makefile<br>2 files changed, 18 insertions(+), 3 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/third-party/Makefile b/third-party/Makefile</span><br><span>index e87e26f..532bf53 100644</span><br><span>--- a/third-party/Makefile</span><br><span>+++ b/third-party/Makefile</span><br><span>@@ -1,13 +1,26 @@</span><br><span> </span><br><span style="color: hsl(120, 100%, 40%);">+-include ../makeopts</span><br><span> include Makefile.rules</span><br><span> </span><br><span style="color: hsl(0, 100%, 40%);">-TP_SUBDIRS := pjproject jansson</span><br><span style="color: hsl(120, 100%, 40%);">+TP_SUBDIRS :=</span><br><span> # Sub directories that contain special install/uninstall targets must be explicitly listed</span><br><span> # to prevent accidentally running the package's default install target.</span><br><span style="color: hsl(0, 100%, 40%);">-TP_INSTALL_SUBDIRS := pjproject jansson</span><br><span style="color: hsl(120, 100%, 40%);">+TP_INSTALL_SUBDIRS :=</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+ifeq ($(PJPROJECT_BUNDLED),yes)</span><br><span style="color: hsl(120, 100%, 40%);">+TP_SUBDIRS += pjproject</span><br><span style="color: hsl(120, 100%, 40%);">+TP_INSTALL_SUBDIRS += pjproject</span><br><span style="color: hsl(120, 100%, 40%);">+endif</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+ifeq ($(JANSSON_BUNDLED),yes)</span><br><span style="color: hsl(120, 100%, 40%);">+TP_SUBDIRS += jansson</span><br><span style="color: hsl(120, 100%, 40%);">+TP_INSTALL_SUBDIRS += jansson</span><br><span style="color: hsl(120, 100%, 40%);">+endif</span><br><span> </span><br><span> .PHONY: all dist-clean distclean install clean moduleinfo makeopts uninstall $(TP_SUBDIRS)</span><br><span> </span><br><span style="color: hsl(120, 100%, 40%);">+ifneq ($(TP_SUBDIRS),)</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span> override MAKECMDGOALS?=all</span><br><span> </span><br><span> MAKECMDGOALS:=$(subst dist-clean,distclean,$(MAKECMDGOALS))</span><br><span>@@ -17,3 +30,5 @@</span><br><span> </span><br><span> $(TP_SUBDIRS):</span><br><span> +$(CMD_PREFIX) $(SUBMAKE) -C $@ $(MAKECMDGOALS)</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span style="color: hsl(120, 100%, 40%);">+endif</span><br><span>\ No newline at end of file</span><br><span>diff --git a/third-party/pjproject/Makefile b/third-party/pjproject/Makefile</span><br><span>index 612c116..28cb5db 100644</span><br><span>--- a/third-party/pjproject/Makefile</span><br><span>+++ b/third-party/pjproject/Makefile</span><br><span>@@ -126,7 +126,7 @@</span><br><span> $(ECHO_PREFIX) Rebuilding</span><br><span> $(CMD_PREFIX) $(MAKE) clean $(REALLY_QUIET)</span><br><span> </span><br><span style="color: hsl(0, 100%, 40%);">-source/build.mak: Makefile.rules source/user.mak $(if $(PJPROJECT_BUNDLED_OOT),,.rebuild_needed)</span><br><span style="color: hsl(120, 100%, 40%);">+source/build.mak: Makefile.rules source/user.mak $(if $(PJPROJECT_BUNDLED_OOT),,.rebuild_needed) $(subst patches,source/pjlib/include/pj,$(wildcard patches/*.h))</span><br><span> $(ECHO_PREFIX) Configuring with $(PJPROJECT_CONFIG_OPTS) </span><br><span> $(CMD_PREFIX) (cd source ; ./aconfigure $(QUIET_CONFIGURE) $(PJPROJECT_CONFIG_OPTS))</span><br><span> </span><br><span></span><br></pre><div style="white-space:pre-wrap"></div><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/17881">change 17881</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/c/asterisk/+/17881"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 19 </div>
<div style="display:none"> Gerrit-Change-Id: I9427264fa3cb8b3f59a95e5f9693eac236a6f76d </div>
<div style="display:none"> Gerrit-Change-Number: 17881 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </div>
<div style="display:none"> Gerrit-Owner: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Friendly Automation </div>
<div style="display:none"> Gerrit-Reviewer: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Joshua Colp <jcolp@sangoma.com> </div>
<div style="display:none"> Gerrit-MessageType: merged </div>