autogen.sh 1007 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. #!/bin/sh
  2. # Run this script to generate the configure script and other files that will
  3. # be included in the distribution. These files are not checked in because they
  4. # are automatically generated.
  5. set -e
  6. if [ ! -z "$@" ]; then
  7. for argument in "$@"; do
  8. case $argument in
  9. # make curl silent
  10. "-s")
  11. curlopts="-s"
  12. ;;
  13. esac
  14. done
  15. fi
  16. # Check that we're being run from the right directory.
  17. if test ! -f src/google/protobuf/stubs/common.h; then
  18. cat >&2 << __EOF__
  19. Could not find source code. Make sure you are running this script from the
  20. root of the distribution tree.
  21. __EOF__
  22. exit 1
  23. fi
  24. set -ex
  25. # The absence of a m4 directory in googletest causes autoreconf to fail when
  26. # building under the CentOS docker image. It's a warning in regular build on
  27. # Ubuntu/gLinux as well.
  28. mkdir -p third_party/googletest/m4
  29. # TODO(kenton): Remove the ",no-obsolete" part and fix the resulting warnings.
  30. autoreconf -f -i -Wall,no-obsolete
  31. rm -rf autom4te.cache config.h.in~
  32. exit 0