git: make(1): Create two more custom variables to speed up dports

John Marino marino at crater.dragonflybsd.org
Fri Nov 27 17:51:36 PST 2015


commit a4cce4724800c9180e886281d6ba9952f7690528
Author: John Marino <draco at marino.st>
Date:   Sat Nov 28 02:39:15 2015 +0100

    make(1): Create two more custom variables to speed up dports
    
    I've added two new static values to bmake:
    
    .MAKE.DF.OSREL
    This will currently return "4.5"
    
    .MAKE.DF.VERSION
    This will currently return "400500".  It matches what was in place on
    /usr/src/sys/sys/param.h during the last buildworld.
    
    Every dport runs piped shell commands to get these values. After iterating
    through the entire ports tree several times, I noticed a large presence
    of awk in process list.  After modifying bmake and then modifying dports
    locally, the iteration runs 15% faster.  There are other optimizations
    that can be done, but that's out of scope of this commit.

Summary of changes:
 contrib/bmake/bmake.1  | 9 +++++++++
 contrib/bmake/main.c   | 2 ++
 usr.bin/bmake/Makefile | 8 ++++++++
 3 files changed, 19 insertions(+)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/a4cce4724800c9180e886281d6ba9952f7690528


-- 
DragonFly BSD source repository



More information about the Commits mailing list