Date: Sun, 7 Mar 2010 10:08:00 +0000 (UTC) From: "David E. O'Brien" <obrien@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r204824 - head/sys/conf Message-ID: <201003071008.o27A80wC014578@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: obrien Date: Sun Mar 7 10:08:00 2010 New Revision: 204824 URL: http://svn.freebsd.org/changeset/base/204824 Log: Look for "compile" to decide if this is run as part of the kernel build. The assumption of "${ARCH}/compile/FOO" is much harder to change in our build (so assume one hasn't), then assuming every kernel is rooted at "sys/". Modified: head/sys/conf/newvers.sh Modified: head/sys/conf/newvers.sh ============================================================================== --- head/sys/conf/newvers.sh Sun Mar 7 09:52:35 2010 (r204823) +++ head/sys/conf/newvers.sh Sun Mar 7 10:08:00 2010 (r204824) @@ -88,15 +88,15 @@ v=`cat version` u=${USER:-root} d=`pwd` i=`${MAKE:-make} -V KERN_IDENT` case "$d" in -*/sys/*) +*/compile/*) SRCDIR=${d##*obj} if [ -n "$MACHINE" ]; then SRCDIR=${SRCDIR##/$MACHINE} fi - SRCDIR=${SRCDIR%%/sys/*} + SRCDIR=$(cd ${SRCDIR%%/compile/*}/.. && pwd) for dir in /bin /usr/bin /usr/local/bin; do - if [ -d "${SRCDIR}/sys/.svn" -a -x "${dir}/svnversion" ] ; then + if [ -d "${SRCDIR}/.svn" -a -x "${dir}/svnversion" ] ; then svnversion=${dir}/svnversion break fi @@ -107,7 +107,7 @@ case "$d" in done if [ -n "$svnversion" ] ; then - svn=" r`cd ${SRCDIR}/sys && $svnversion`" + svn=" r`cd ${SRCDIR} && $svnversion`" fi if [ -n "$git_cmd" ] ; then git=`$git_cmd rev-parse --verify --short HEAD 2>/dev/null`
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201003071008.o27A80wC014578>