--- scripts/xdt-autogen.in.orig	2009-02-25 07:32:08.000000000 +0100
+++ scripts/xdt-autogen.in	2014-08-02 00:12:04.000000000 +0200
@@ -135,6 +135,15 @@ if test x"$1" = x"clean"; then
   exit 0
 fi
 
+# MacPorts: default to prefix
+test -z "${XDT_PROG_AUTOCONF}" && XDT_PROG_AUTOCONF=@@PREFIX@@/bin/autoconf
+test -z "${XDT_PROG_INTLTOOLIZE}" && XDT_PROG_INTLTOOLIZE=@@PREFIX@@/bin/intltoolize
+test -z "${XDT_PROG_LIBTOOLIZE}" && XDT_PROG_LIBTOOLIZE=@@PREFIX@@/bin/glibtoolize
+test -z "${XDT_PROG_GLIB_GETTEXTIZE}" && XDT_PROG_GLIB_GETTEXTIZE=@@PREFIX@@/bin/glib-gettextize
+test -z "${XDT_PROG_GTKDOCIZE}" && XDT_PROG_GTKDOCIZE=@@PREFIX@@/bin/gtkdocize
+test -z "${XDT_PROG_ACLOCAL}" && XDT_PROG_ACLOCAL=@@PREFIX@@/bin/aclocal
+test -z "${XDT_PROG_AUTOHEADER}" && XDT_PROG_AUTOHEADER=@@PREFIX@@/bin/autoheader
+test -z "${XDT_PROG_AUTOMAKE}" && XDT_PROG_AUTOMAKE=@@PREFIX@@/bin/automake
 
 ##
 ## Check for autoconf, first trying autoconf-2.59, then autoconf-2.58, then
