2009-03-30 17:10:22 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
2012-04-10 20:14:48 +02:00
|
|
|
revision=`$1/support/getver.sh`
|
2009-03-30 17:10:22 +00:00
|
|
|
|
2012-04-10 20:14:48 +02:00
|
|
|
NEW_REVISION="#define BUILD_VERSION \"$revision\""
|
|
|
|
OLD_REVISION=`cat $2 2> /dev/null`
|
2009-03-30 17:10:22 +00:00
|
|
|
|
2012-04-10 20:14:48 +02:00
|
|
|
# Update version.h only on revision changes to avoid spurious rebuilds
|
|
|
|
if test "$NEW_REVISION" != "$OLD_REVISION"; then
|
|
|
|
echo "$NEW_REVISION" > "$2"
|
2009-05-29 21:45:15 +00:00
|
|
|
fi
|