Author: gjb
Date: Tue Apr  1 17:57:45 2014
New Revision: 264014
URL: http://svnweb.freebsd.org/changeset/base/264014

Log:
  MFC r250143, r257079, r258086, r262670:
  
  r250143 (benno):
    Optimize SUBDIR_OVERRIDE such that SUBDIR isn't automatically
    defined if SUBDIR_OVERRIDE is defined.
  
  r257079:
    Fix build host pollution by avoiding calling 'uname -srp' to
    determine values for 'VERSION'.
  
  r262670 (marcel):
    Use ${MAKE} so that we always use the same version/implementation
    of make.
  
  r258086 (cperciva):
    Strip the -pN patch level from the VERSION string which gets
    encoded into CTF data.  Otherwise FreeBSD Update builds think every
    kernel file has changed every time there's a security advisory,
    since the FreeBSD Update build code isn't smart enough to look inside
    CTF data to ignore those changes.
  
  Tested on:    stable/9@r263881
  Sponsored by: The FreeBSD Foundation

Modified:
  stable/9/Makefile.inc1   (contents, props changed)

Modified: stable/9/Makefile.inc1
==============================================================================
--- stable/9/Makefile.inc1      Tue Apr  1 17:35:31 2014        (r264013)
+++ stable/9/Makefile.inc1      Tue Apr  1 17:57:45 2014        (r264014)
@@ -62,6 +62,10 @@ TARGET_ARCH=${TARGET}
 # use that new version.  And the new (dynamically-linked) /bin/sh
 # will expect to find appropriate libraries in /lib and /libexec.
 #
+SRCDIR?=       ${.CURDIR}
+.if defined(SUBDIR_OVERRIDE)
+SUBDIR=        ${SUBDIR_OVERRIDE}
+.else
 SUBDIR=        share/info lib libexec
 SUBDIR+=bin
 .if ${MK_GAMES} != "no"
@@ -100,9 +104,6 @@ SUBDIR+=etc
 SUBDIR+= ${_DIR}
 .endif
 .endfor
-
-.if defined(SUBDIR_OVERRIDE)
-SUBDIR=                ${SUBDIR_OVERRIDE}
 .endif
 
 .if defined(NOCLEAN)
@@ -130,8 +131,11 @@ OSRELDATE= 0
 .endif
 
 .if !defined(VERSION)
-VERSION!=      uname -srp
-VERSION+=      ${OSRELDATE}
+REVISION!=     ${MAKE} -C ${SRCDIR}/release -V REVISION
+BRANCH!=       ${MAKE} -C ${SRCDIR}/release -V BRANCH
+SRCRELDATE!=   awk '/^\#define[[:space:]]*__FreeBSD_version/ { print $$3 }' \
+               ${SRCDIR}/sys/sys/param.h
+VERSION=       FreeBSD ${REVISION}-${BRANCH:C/-p[0-9]+$//} ${TARGET_ARCH} 
${SRCRELDATE}
 .endif
 
 KNOWN_ARCHES?= amd64 arm armeb/arm i386 i386/pc98 ia64 mipsel/mips mipseb/mips 
mips64el/mips mips64eb/mips mipsn32el/mips mipsn32eb/mips powerpc 
powerpc64/powerpc sparc64
_______________________________________________
svn-src-stable-9@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-stable-9
To unsubscribe, send any mail to "svn-src-stable-9-unsubscr...@freebsd.org"

Reply via email to