Merge changes I627eb724,I55d5865b
authorJames Zern <jzern@google.com>
Thu, 6 Mar 2014 22:18:16 +0000 (14:18 -0800)
committerGerrit Code Review <gerrit@gerrit.golo.chromium.org>
Thu, 6 Mar 2014 22:18:16 +0000 (14:18 -0800)
* changes:
  configure: add a test for configured source dir
  Makefile: add distclean target

1  2 
configure

diff --cc configure
+++ b/configure
@@@ -160,12 -160,18 +160,20 @@@ for t in ${all_targets}; d
      [ -f ${source_path}/${t}.mk ] && enable_feature ${t}
  done
  
 -if ! perl --version >/dev/null; then
 -    die "Perl is required to build"
 -fi
 +for util in make perl; do
 +    if ! ${util} --version >/dev/null; then
 +        die "${util} is required to build."
 +    fi
 +done
  
+ if [ "`cd ${source_path} && pwd`" != "`pwd`" ]; then
+   # test to see if source_path already configured
+   if [ -f ${source_path}/vpx_config.h ]; then
+     die "source directory already configured; run 'make distclean' there first"
+   fi
+ fi
  # check installed doxygen version
  doxy_version=$(doxygen --version 2>/dev/null)
  doxy_major=${doxy_version%%.*}