make mkver fetch the date information from src/usr.sbin/ntp/importdate
in order to achieve consistent version strings across all builds
This commit is contained in:
parent
cc7d901591
commit
fbcf7d7188
|
@ -1,6 +1,6 @@
|
|||
#! /bin/sh
|
||||
#
|
||||
# $NetBSD: ntp2netbsd,v 1.8 2008/07/16 11:11:37 perry Exp $
|
||||
# $NetBSD: ntp2netbsd,v 1.9 2008/07/16 20:53:56 kardel Exp $
|
||||
#
|
||||
# Copyright (c) 1998, 1999 The NetBSD Foundation, Inc.
|
||||
# All rights reserved.
|
||||
|
@ -42,11 +42,11 @@
|
|||
# $ cp config.h /usr/src/usr.sbin/ntp/include
|
||||
# - not really - we have some changed defaults and the vax port has no ieee.h support.
|
||||
# so do a careful diff and patch - Frank Kardel
|
||||
# $ cp scripts/mkver /usr/src/usr.sbin/ntp/scripts
|
||||
# Note you will have to edit mkver to remove date and
|
||||
# build number information.
|
||||
# Consult the old version on how this is done.
|
||||
# This should possibly be automated in the future.
|
||||
# $ echo cp scripts/mkver /usr/src/usr.sbin/ntp/scripts
|
||||
# merge possible changes to mkver
|
||||
# our version uses the import date in the file
|
||||
# /usr/src/usr.sbin/ntp/importdate for the date and buildnumber information
|
||||
# to achieve consistent version string over all builds
|
||||
# $ cd ..
|
||||
# $ rm -r src ntp-4.x.y
|
||||
# $ cd /usr/src/usr.sbin/ntp
|
||||
|
@ -56,7 +56,8 @@
|
|||
# esp. libntp and ntpd.
|
||||
# - check for and remove img tags in html docs.
|
||||
# - update distrib/sets if necessary.
|
||||
|
||||
# - update src/usr.sbin/ntp/importdate to match the date of this import
|
||||
#
|
||||
if [ $# -ne 2 ]; then echo "ntp2netbsd src dest"; exit 1; fi
|
||||
|
||||
r=$1
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
Sun Jun 24 16:55:11 GMT 2007 (import)
|
|
@ -17,6 +17,23 @@ case "-lcrypto" in
|
|||
*) ConfStr="${ConfStr}-?" ;;
|
||||
esac
|
||||
|
||||
ifile="`dirname $0`/../importdate"
|
||||
|
||||
if [ -f "$ifile" ]; then
|
||||
ConfStr="$ConfStr "`cat "$ifile"`
|
||||
else
|
||||
ConfStr="$ConfStr `LC_TIME=C TZ= date`"
|
||||
|
||||
if [ ! -f .version ]; then
|
||||
echo 0 > .version
|
||||
fi
|
||||
RUN="`cat .version`"
|
||||
RUN="`expr $RUN + 1`"
|
||||
echo $RUN > .version
|
||||
|
||||
ConfStr="$ConfStr (${RUN})"
|
||||
fi
|
||||
|
||||
echo "Version <${ConfStr}>";
|
||||
|
||||
rm -f version.c
|
||||
|
|
Loading…
Reference in New Issue