autogen.sh 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. #!/bin/sh
  2. # Run this to generate all the initial makefiles, etc.
  3. srcdir=`dirname $0`
  4. test -z "$srcdir" && srcdir=.
  5. ORIGDIR=`pwd`
  6. cd $srcdir
  7. PROJECT=libGtkEntryMask
  8. DIE=0
  9. have_libtool=false
  10. if libtoolize --version < /dev/null > /dev/null 2>&1 ; then
  11. libtool_version=`libtoolize --version | sed 's/^[^0-9]*\([0-9.][0-9.]*\).*/\1/'`
  12. case $libtool_version in
  13. 1.4*|1.5*)
  14. have_libtool=true
  15. ;;
  16. esac
  17. fi
  18. if $have_libtool ; then : ; else
  19. echo
  20. echo "You must have libtool 1.4 installed to compile $PROJECT."
  21. echo "Install the appropriate package for your distribution,"
  22. echo "or get the source tarball at http://ftp.gnu.org/gnu/libtool/"
  23. DIE=1
  24. fi
  25. (autoconf --version) < /dev/null > /dev/null 2>&1 || {
  26. echo
  27. echo "You must have autoconf installed to compile $PROJECT."
  28. echo "Install the appropriate package for your distribution,"
  29. echo "or get the source tarball at http://ftp.gnu.org/gnu/autoconf/"
  30. DIE=1
  31. }
  32. if automake-1.7 --version < /dev/null > /dev/null 2>&1 ; then
  33. AUTOMAKE=automake-1.7
  34. ACLOCAL=aclocal-1.7
  35. else
  36. echo
  37. echo "You must have automake 1.7.x installed to compile $PROJECT."
  38. echo "Install the appropriate package for your distribution,"
  39. echo "or get the source tarball at http://ftp.gnu.org/gnu/automake/"
  40. DIE=1
  41. fi
  42. if test "$DIE" -eq 1; then
  43. exit 1
  44. fi
  45. if test -z "$AUTOGEN_SUBDIR_MODE"; then
  46. if test -z "$*"; then
  47. echo "I am going to run ./configure with no arguments - if you wish "
  48. echo "to pass any to it, please specify them on the $0 command line."
  49. fi
  50. fi
  51. $ACLOCAL $ACLOCAL_FLAGS || exit 1
  52. libtoolize --force || exit 1
  53. $AUTOMAKE --add-missing || exit 1
  54. autoconf || exit 1
  55. cd $ORIGDIR
  56. if test -z "$AUTOGEN_SUBDIR_MODE"; then
  57. $srcdir/configure --enable-maintainer-mode "$@"
  58. echo
  59. echo "Now type 'make' to compile $PROJECT."
  60. fi