[Asterisk-code-review] Build System: Improve ccache matching for different menusele... (asterisk[master])

Corey Farrell asteriskteam at digium.com
Wed Aug 1 11:00:59 CDT 2018


Hello Jenkins2, 

I'd like you to reexamine a change. Please visit

    https://gerrit.asterisk.org/9806

to look at the new patch set (#2).

Change subject: Build System: Improve ccache matching for different menuselect options.
......................................................................

Build System: Improve ccache matching for different menuselect options.

Changing any Menuselect option in the `Compiler Flags` section causes a
full rebuild of the Asterisk source tree.  Every enabled option causes
a #define to be added to buildopts.h, thus breaking ccache caching for
every source file that includes "asterisk.h".  In most cases each option
only applies to one or two files.  Now we only define those options for
the specific sources which use them, this causes much better cache
matching when working with multiple builds.  For example testing code
with an without MALLOC_DEBUG will now use just over half the ccache
size, only main/astmm.o will have two builds cached instead of every
file.

Reorder main/Makefile so _ASTCFLAGS set on specific object files are all
together, sorted by filename.  Stop adding -DMALLOC_DEBUG to CFLAGS of
bundled pjproject, this define is no longer used by any header so only
serves to break cache.

The only code change is a slight adjustment to how main/astmm.c is
initialized.  Initialization functions always exist so main/asterisk.c
can call them unconditionally.  Additionally rename the astmm
initialization functions so they are not exported.

Change-Id: Ie2085237a964f6e1e6fff55ed046e2afff83c027
---
M Makefile.rules
M build_tools/make_buildopts_h
M channels/Makefile
M include/asterisk/_private.h
M include/asterisk/astmm.h
M main/Makefile
M main/asterisk.c
M main/astmm.c
M tests/Makefile
M third-party/pjproject/Makefile
M utils/Makefile
11 files changed, 75 insertions(+), 52 deletions(-)


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/06/9806/2
-- 
To view, visit https://gerrit.asterisk.org/9806
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ie2085237a964f6e1e6fff55ed046e2afff83c027
Gerrit-Change-Number: 9806
Gerrit-PatchSet: 2
Gerrit-Owner: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: Jenkins2
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20180801/8092ac2f/attachment.html>


More information about the asterisk-code-review mailing list