autogen.sh 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. #!/bin/sh
  2. # Run this to set up the build system: configure, makefiles, etc.
  3. # (based on the version in enlightenment's cvs)
  4. package="vorbis"
  5. olddir=`pwd`
  6. srcdir=`dirname $0`
  7. test -z "$srcdir" && srcdir=.
  8. cd "$srcdir"
  9. DIE=0
  10. echo "checking for autoconf... "
  11. (autoconf --version) < /dev/null > /dev/null 2>&1 || {
  12. echo
  13. echo "You must have autoconf installed to compile $package."
  14. echo "Download the appropriate package for your distribution,"
  15. echo "or get the source tarball at ftp://ftp.gnu.org/pub/gnu/"
  16. DIE=1
  17. }
  18. echo "checking for automake... "
  19. (automake --version) < /dev/null > /dev/null 2>&1 || {
  20. echo
  21. echo "You must have automake installed to compile $package."
  22. echo "Download the appropriate package for your system,"
  23. echo "or get the source from one of the GNU ftp sites"
  24. echo "listed in http://www.gnu.org/order/ftp.html"
  25. DIE=1
  26. }
  27. echo -n "checking for libtool... "
  28. for LIBTOOLIZE in libtoolize glibtoolize nope; do
  29. (which $LIBTOOLIZE) > /dev/null 2>&1 && break
  30. done
  31. if test x$LIBTOOLIZE = xnope; then
  32. echo "nope."
  33. LIBTOOLIZE=libtoolize
  34. else
  35. echo $LIBTOOLIZE
  36. fi
  37. ($LIBTOOLIZE --version) < /dev/null > /dev/null 2>&1 || {
  38. echo
  39. echo "You must have libtool installed to compile $package."
  40. echo "Download the appropriate package for your system,"
  41. echo "or get the source from one of the GNU ftp sites"
  42. echo "listed in http://www.gnu.org/order/ftp.html"
  43. DIE=1
  44. }
  45. if test "$DIE" -eq 1; then
  46. exit 1
  47. fi
  48. if test -z "$*"; then
  49. echo "I am going to run ./configure with no arguments - if you wish "
  50. echo "to pass any to it, please specify them on the $0 command line."
  51. fi
  52. echo "Generating configuration files for $package, please wait...."
  53. echo " aclocal $ACLOCAL_FLAGS"
  54. aclocal $ACLOCAL_FLAGS || exit 1
  55. echo " autoheader"
  56. autoheader || exit 1
  57. echo " $LIBTOOLIZE --automake"
  58. $LIBTOOLIZE --automake || exit 1
  59. echo " automake --add-missing $AUTOMAKE_FLAGS"
  60. automake --add-missing $AUTOMAKE_FLAGS || exit 1
  61. echo " autoconf"
  62. autoconf || exit 1
  63. cd $olddir
  64. $srcdir/configure "$@" && echo