Make sure the Modules/ directory is created before writing Modules/Setup.
diff --git a/configure.in b/configure.in
index 43462fb..15e9a3a 100644
--- a/configure.in
+++ b/configure.in
@@ -1300,6 +1300,9 @@
 
 AC_MSG_CHECKING(for Modules/Setup)
 if test ! -f Modules/Setup ; then
+    if test ! -d Modules ; then
+        mkdir Modules
+    fi
     cp "$srcdir/Modules/Setup.dist" Modules/Setup
     AC_MSG_RESULT(creating)
 else