+2003-07-29 Lars Gullik Bjønnes <larsbj@gullik.net>
+
+ * configure.ac: compression support
+
2003-07-28 Lars Gullik Bjønnes <larsbj@gullik.net>
* configure.ac: check for zlib.
+2003-07-29 Lars Gullik Bjønnes <larsbj@gullik.net>
+
+ * lyxinclude.m4: use AC_HELP_STRING
+
2003-07-27 Lars Gullik Bjønnes <larsbj@gullik.net>
* configure.ac,configure.in,lyxinclude213.m4,relyx_configure.ac,relyx_configure.in: delete file
### We might want to get or shut warnings.
AC_ARG_ENABLE(warnings,
- [ --enable-warnings tell the compiler to display more warnings],,
+ AC_HELP_STRING([--enable-warnings],[tell the compiler to display more warnings]),,
[ if test $lyx_devel_version = yes -o $lyx_prerelease = yes && test $ac_cv_prog_gxx = yes ; then
enable_warnings=yes;
else
### We might want to disable debug
AC_ARG_ENABLE(debug,
- [ --enable-debug enable debug information],,
+ AC_HELP_STRING([--enable-debug],[enable debug information]),,
[ if test $lyx_devel_version = yes -o $lyx_prerelease = yes && test $ac_cv_prog_gxx = yes ; then
enable_debug=yes;
else
### set up optimization
AC_ARG_ENABLE(optimization,
- [ --enable-optimization[=value] enable compiler optimisation],,
+ AC_HELP_STRING([--enable-optimization[=value]],[enable compiler optimisation]),,
enable_optimization=yes;)
case $enable_optimization in
yes) lyx_opt=-O;;
### and now some special lyx flags.
AC_ARG_ENABLE(assertions,
- [ --enable-assertions add runtime sanity checks in the program],,
+ AC_HELP_STRING([--enable-assertions],[add runtime sanity checks in the program]),,
[if test $lyx_devel_version = yes -o $lyx_prerelease = yes ; then
enable_assertions=yes;
else
LYX_CHECK_DECL(istreambuf_iterator, iterator)
LYX_CHECK_DECL(mkstemp,[unistd.h stdlib.h])
-AC_CHECK_HEADERS(zlib.h)
-AC_CHECK_LIB(z, gzopen)
+AC_ARG_ENABLE(compression-support, AC_HELP_STRING([--enable-compression-support],[Support for compressed files.]),[
+ case "${enableval}" in
+ yes) use_compression=true ;;
+ no) use_compression=false ;;
+ *) AC_MSG_ERROR(bad value ${enableval} for --enable-compression-support) ;;
+ esac
+],[use_compression=true])
+if test $use_compression=true ; then
+ AC_CHECK_HEADERS(zlib.h, use_compression=true, use_compression=false)
+ AC_CHECK_LIB(z, gzopen,[use_compression=true;LIBS="$LIBS -lz"], use_compression=false)
+ if test $use_compression = true ; then
+ AC_DEFINE(USE_COMRESSION, 1, [Define as 1 if you want to supprot compressed files.])
+ lyx_flags="$lyx_flags compression"
+ fi
+fi
+AM_CONDITIONAL(USE_COMPRESSION, test x$use_compression = xtrue)
+AC_MSG_CHECKING([whether to support compressed files])
+AC_MSG_RESULT($use_compression)
+
dnl This is a slight hack: the tests generated by autoconf 2.52 do not
dnl work correctly because of some conflict with stdlib.h with g++ 2.96
// the first token _must_ be...
if (token != "\\lyxformat") {
+ lyxerr << "Token: " << token << endl;
+
Alert::error(_("Document format failure"),
_("The specified document is not a LyX document."));
return false;
return false;
}
command += " -t"
- +tostr(LYX_FORMAT) + ' '
+ + tostr(LYX_FORMAT) + ' '
+ QuoteName(filename);
lyxerr[Debug::INFO] << "Running '"
<< command << '\''
+2003-07-29 Lars Gullik Bjønnes <larsbj@gullik.net>
+
+ * Makefile.am: contidionalize USE_COMPRESSION
+
2003-07-28 Lars Gullik Bjønnes <larsbj@gullik.net>
* filetools.C (getExtFromContents): correct magic for gzip and
LYXSTRING = lyxstring.C lyxstring.h
endif
+if USE_COMPRESSION
+COMPRESSION = gzstream.C gzstream.C
+endif
+
BUILT_SOURCES = path_defines.C
libsupport_la_SOURCES = \
forkedcontr.C \
forkedcontr.h \
getcwd.C \
- gzstream.C \
- gzstream.h \
- kill.C \
+ $(COMPRESSION) kill.C \
limited_stack.h \
lstrings.C \
lstrings.h \
path.C \
path.h \
path_defines.C \
+ path_defines.h \
putenv.C \
rename.C \
rmdir.C \