Add an autogen.sh
[claws-mail-maildir-plugin.git] / autogen.sh
diff --git a/autogen.sh b/autogen.sh
new file mode 100755 (executable)
index 0000000..8e76802
--- /dev/null
@@ -0,0 +1,27 @@
+#!/bin/sh
+# Copyright 1999-2014 the Claws Mail team.
+# This file is part of Claws Mail package, and distributed under the
+# terms of the General Public License version 3 (or later).
+# See COPYING file for license details.
+
+case `uname` in
+       Darwin*)
+               if [ "`glibtoolize --version`" = "" ]; then
+                       echo MacOS requires glibtool from either Macport or brew
+                       exit 1
+               fi
+               LIBTOOL="glibtoolize --force --copy"
+               ;;
+       *)
+               LIBTOOL="libtoolize --force --copy"
+               ;;
+esac
+
+aclocal -I m4 \
+  && ${LIBTOOL} \
+  && autoheader \
+  && automake --add-missing --foreign --copy \
+  && autoconf 
+if test -z "$NOCONFIGURE"; then
+exec ./configure --enable-maintainer-mode $@
+fi