diff options
author | Andrew Tridgell <tridge@samba.org> | 2005-07-12 12:12:03 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:20:13 -0500 |
commit | fc5a0c4c46ba5718ac0c6489aa733060be1fa9ef (patch) | |
tree | 73579ada7cb5495d6b2cfd02df14efa82bcf21a0 /source4 | |
parent | c9b0e86a436b5b169a4c33bd25eac379cb622b17 (diff) | |
download | samba-fc5a0c4c46ba5718ac0c6489aa733060be1fa9ef.tar.gz samba-fc5a0c4c46ba5718ac0c6489aa733060be1fa9ef.tar.bz2 samba-fc5a0c4c46ba5718ac0c6489aa733060be1fa9ef.zip |
r8374: avoid running flex and bison unless needed
this should stop the files changes in svn for other developers
(This used to be commit 18d3deb777bd6aa4dd102fa2a2838d0afc2bd74c)
Diffstat (limited to 'source4')
-rwxr-xr-x | source4/heimdal_build/build_external.sh | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/source4/heimdal_build/build_external.sh b/source4/heimdal_build/build_external.sh index 355facc6dd..5b512899cc 100755 --- a/source4/heimdal_build/build_external.sh +++ b/source4/heimdal_build/build_external.sh @@ -41,10 +41,15 @@ build_lex() { dir=`dirname $f` file=`basename $f` base=`basename $f .l` + if [ -r $dir/$base.c ]; then + if [ x`find $f -newer $dir/$base.c -print` != x$f ]; then + return; + fi + fi echo Building $f if cd $dir && $FLEX $file; then - sed '/^#/ s|$base.yy\.c|$base.c|' $base.yy.c > $base.c - rm -f $base.yy.c + sed '/^#/ s|$base.yy\.c|$base.c|' $base.yy.c > $base.c + rm -f $base.yy.c fi cd $TOP || exit 1 } @@ -54,6 +59,11 @@ build_bison() { dir=`dirname $f` file=`basename $f` base=`basename $f .y` + if [ -r $dir/$base.c ]; then + if [ x`find $f -newer $dir/$base.c -print` != x$f ]; then + return; + fi + fi echo Building $f if cd $dir && $BISON -y -d $file; then sed -e "/^#/!b" -e "s|y\.tab\.h|$base.h|" y.tab.h > $base.h |