Index: sys/conf/newvers.sh =================================================================== --- sys/conf/newvers.sh +++ sys/conf/newvers.sh @@ -51,6 +51,17 @@ ${SYSDIR}/sys/param.h) fi +REPRODUCIBLE= + +while getopts R opt; do +case "$opt" in +R) + REPRODUCIBLE=1 + ;; +esac +done +shift $(($OPTIND - 1)) + b=share/examples/etc/bsd-style-copyright if [ -r "${SYSDIR}/../COPYRIGHT" ]; then year=$(sed -Ee '/^Copyright .* The FreeBSD Project/!d;s/^.*1992-([0-9]*) .*$/\1/g' ${SYSDIR}/../COPYRIGHT) @@ -220,10 +231,16 @@ fi fi +if [ $REPRODUCIBLE ]; then + VERSTR="${VERSION} #${v}${svn}${git}${hg}${p4version}\\n" +else + VERSTR="${VERSION} #${v}${svn}${git}${hg}${p4version}: ${t}\\n ${u}@${h}:${d}\\n" +fi + cat << EOF > vers.c $COPYRIGHT #define SCCSSTR "@(#)${VERSION} #${v}${svn}${git}${hg}${p4version}: ${t}" -#define VERSTR "${VERSION} #${v}${svn}${git}${hg}${p4version}: ${t}\\n ${u}@${h}:${d}\\n" +#define VERSTR "${VERSTR}" #define RELSTR "${RELEASE}" char sccs[sizeof(SCCSSTR) > 128 ? sizeof(SCCSSTR) : 128] = SCCSSTR;