-FILES="./release Makefile.common ${avi2swf} Makefile lib/Makefile lib/action/Makefile src/Makefile ${pdf2swf_makefile} swfs/Makefile ${pythonrfxswf} ${lame_makefile}"
-
-dnl AC_OUTPUT(${FILES}) old autoconf
-AC_CONFIG_FILES([${FILES}])
-AC_OUTPUT
-
+AH_TOP([
+#ifndef __config_h__
+#define __config_h__
+])
+
+AH_BOTTOM([
+#ifdef HAVE_ZLIB_H
+#ifdef HAVE_LIBZ
+#define HAVE_ZLIB
+#endif
+#endif
+
+#ifdef HAVE_JPEGLIB_H
+#ifdef HAVE_LIBJPEG
+#define HAVE_JPEGLIB
+#endif
+#endif
+
+#ifdef HAVE_FT2BUILD_H
+#define HAVE_FREETYPE_H 1
+#endif
+
+#ifdef HAVE_GL_GL_H
+#ifdef HAVE_GL_GLUT_H
+#ifdef HAVE_OPENGL
+#define USE_OPENGL
+#endif
+#endif
+#endif
+
+#ifdef HAVE_POPPLER
+#define GString GooString
+#define GHash GooHash
+#endif
+
+#endif // __config_h__
+])
+
+if test -f "release.in"; then release_in="./release"; fi
+if test -f "Makefile.new.in"; then mk_in="./Makefile.new"; fi
+FILES="$release_in $mk_in Makefile.common ${avi2swf} Makefile lib/Makefile lib/action/Makefile src/Makefile ${pdf2swf_makefile} swfs/Makefile ${pythonrfxswf} ${lame_makefile} lib/art/Makefile lib/readers/Makefile"
+AC_OUTPUT(${FILES})
+
+dnl new autoconf
+dnl AC_CONFIG_FILES([${FILES}])
+dnl AC_OUTPUT
+
+#
+# On development trees, create snapshots of config.status
+#
+if test -f snapshot -a "x$CHECKMEM" = "x" -a "x$PROFILING" = "x";then
+ if test "x${MINGW}" = "xyes"; then
+ echo cp config.status config.status.win32
+ cp config.status config.status.win32
+ else
+ if test "x$DEBUG" '=' "x" -a "x$OPTIMIZE" '=' "x";then
+ echo cp config.status config.status.linux
+ cp config.status config.status.linux
+ fi
+ if test "x$DEBUG" '!=' "x" -a "x$OPTIMIZE" '=' "x";then
+ echo cp config.status config.status.debug
+ cp config.status config.status.debug
+ fi
+ if test "x$DEBUG" = "x" -a "x$OPTIMIZE" '!=' "x"; then
+ echo cp config.status config.status.optimize
+ cp config.status config.status.optimize
+ fi
+ fi
+fi