dnl Process this file with autoconf to produce a configure script.
-AC_INIT(acconfig.h)
-catdoc_version=0.94.3
+AC_INIT([catdoc],[0.95])
dnl Checks for programs.
AC_PROG_CC
case ${CC} in
WISH=$withval,[
AC_PATH_PROGS(WISH,wish wish8.1 wish8.2 wish8.3 wish8.4)
if test -n "$WISH"; then
-AC_CACHE_CHECK(checking if wish version is 8.1 or above ,GOOD_WISH,
+AC_CACHE_CHECK(checking if wish version is 8.1 or above ,[ac_cv_GOOD_WISH],
changequote(<<,>>)dnl
<<changequote(<<,>>)dnl>>
<<echo 'if {[info tclversion]>=7.6} {
puts -nonewline "no"
}
exit'>tmp$$.tcl
-GOOD_WISH=`$WISH tmp$$.tcl`
+ac_cv_GOOD_WISH=`$WISH tmp$$.tcl`
rm tmp$$.tcl >>
<<changequote([, ])dnl>>
changequote([, ])dnl
)
-if test "$GOOD_WISH" != yes; then
+if test "$ac_cv_GOOD_WISH" != yes; then
enable_wordview=no
fi
fi
dnl Checks for header files.
AC_HEADER_STDC
-AC_CHECK_HEADERS(unistd.h)
-
+AC_CHECK_HEADERS([unistd.h stdint.h])
if test -z "$enable_langinfo"; then
enable_langinfo=yes
fi
dnl Checks for library functions.
AC_FUNC_SETVBUF_REVERSED
-if test "$GCC" = "yes"; then
- CFLAGS="-g -O2 -Wall"
-fi
+#if test "$GCC" = "yes"; then
+# CFLAGS="-g -O2 -Wall"
+#fi
AC_DEFINE_UNQUOTED([SOURCE_CHARSET],"$sourcecharset",[Character encoding used by default for 8-bit source files])
AC_DEFINE_UNQUOTED([TARGET_CHARSET],"$targetcharset",[Output character encoding used by default, if impossible to determine encoding from locale])
AC_SUBST(manext)
AC_SUBST(charsetcheck)
AC_SUBST(installroot)
-AC_SUBST(catdoc_version)
+AC_SUBST(PACKAGE_VERSION)
AC_SUBST(CFLAGS)
-AC_SUBST(WORDS_BIGENDIAN DEFS)
+AC_SUBST(WORDS_BIGENDIAN)
AC_CONFIG_HEADER(src/config.h)
AC_OUTPUT(doc/Makefile charsets/Makefile src/Makefile Makefile doc/catdoc.1 doc/xls2csv.1 doc/wordview.1 doc/catppt.1)