autogen.sh 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. #!/bin/sh
  2. # ***** W32 build script *******
  3. # Used to cross-compile for Windows.
  4. if test "$1" = "--build-w32"; then
  5. tmp=`dirname $0`
  6. tsdir=`cd "$tmp"; pwd`
  7. shift
  8. if [ ! -f $tsdir/config/config.guess ]; then
  9. echo "$tsdir/config/config.guess not found" >&2
  10. exit 1
  11. fi
  12. build=`$tsdir/config/config.guess`
  13. [ -z "$w32root" ] && w32root="$HOME/w32root"
  14. echo "Using $w32root as standard install directory" >&2
  15. if i586-mingw32msvc-gcc --version >/dev/null 2>&1 ; then
  16. host=i586-mingw32msvc
  17. crossbindir=/usr/$host/bin
  18. else
  19. echo "Debian's mingw32 cross-compiler packet is required" >&2
  20. exit 1
  21. fi
  22. if [ -f "$tsdir/config.log" ]; then
  23. if ! head $tsdir/config.log | grep "$host" >/dev/null; then
  24. echo "Pease run a 'make distclean' first" >&2
  25. exit 1
  26. fi
  27. fi
  28. ./configure --enable-maintainer-mode --prefix=${w32root} \
  29. --host=i586-mingw32msvc --build=${build} \
  30. --with-lib-prefix=${w32root} \
  31. --with-libiconv-prefix=${w32root} \
  32. --with-gpg-error-prefix=${w32root} \
  33. --with-gpgme-prefix=${w32root} \
  34. --with-config-dir="Claws-mail" \
  35. --disable-openssl --disable-dillo-viewer-plugin \
  36. --disable-nls --disable-libetpan --disable-aspell \
  37. --disable-trayicon-plugin --disable-spamassassin-plugin \
  38. PKG_CONFIG_LIBDIR="$w32root/lib/pkgconfig"
  39. rc=$?
  40. exit $rc
  41. fi
  42. # ***** end W32 build script *******
  43. aclocal -I m4 \
  44. && libtoolize --force --copy \
  45. && autoheader \
  46. && automake --add-missing --foreign --copy \
  47. && autoconf \
  48. && ./configure --enable-maintainer-mode $@