1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-24 11:29:10 +00:00
freebsd/contrib/amd/m4/update_build_version
2003-09-02 15:27:38 +00:00

23 lines
604 B
Bash
Executable File

#!/bin/sh
# Update the build version file for am-utils
# Erez Zadok <ezk@cs.columbia.edu>
#set -x
file="build_version.h"
vers=1
if test -f $file
then
egrep AMU_BUILD_VERSION $file | while read a b vers
do
vers=`expr $vers + 1`
echo '/* do not edit this file by hand */' > $file
echo '/* auto-generated by update_build_version script */' >> $file
echo '#define AMU_BUILD_VERSION '$vers >> $file
done
else
echo '/* do not edit this file by hand */' > $file
echo '/* auto-generated by update_build_version script */' >> $file
echo '#define AMU_BUILD_VERSION '$vers >> $file
fi