diff --git a/Makefile.am b/Makefile.am
index 36bb2f3..c8cf5ff 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -34,20 +34,12 @@ dist_man1_MANS = doc/lsyncd.1
EXTRA_DIST = doc/lsyncd.1.txt doc/lsyncd.1.xml inotify.c fsevents.c bin2carray.lua \
default.lua default-rsync.lua default-rsyncssh.lua default-direct.lua
-doc/lsyncd.1: doc/lsyncd.1.xml
- xsltproc -o $@ -nonet /etc/asciidoc/docbook-xsl/manpage.xsl $<
-
-doc/lsyncd.1.xml: doc/lsyncd.1.txt
- asciidoc -o $@ -b docbook -d manpage $<
+doc/lsyncd.1: doc/lsyncd.1.txt
+ a2x --format=manpage $<
CLEANFILES = runner.out defaults.out runner.c defaults.c
-if RUNNER
-# installs the runner script
-runnerdir = $(RUNNER_DIR)
-runner_DATA = lsyncd.lua
-else
-# or compiles it into the binary
+# compiles the runner and the defaults into the binary
lsyncd_LDADD += runner.o defaults.o
runner.o: runner.c
@@ -65,5 +57,3 @@ runner.out: lsyncd.lua
defaults.out: default.lua default-rsync.lua default-rsyncssh.lua default-direct.lua
luac -o $@ $^
-endif
-
diff --git a/configure.ac b/configure.ac
index e818a10..a58625e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,7 @@
# -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.
#AC_PREREQ(2.60)
-AC_INIT(lsyncd, 2.0.6, axkibe@gmail.com)
+AC_INIT(lsyncd, 2.0.7, axkibe@gmail.com)
AC_CONFIG_SRCDIR([lsyncd.c])
AC_CONFIG_HEADER([config.h])
AM_INIT_AUTOMAKE(AC_PACKAGE_NAME, AC_PACKAGE_VERSION)
@@ -24,21 +24,6 @@ PKG_CHECK_MODULES([LUA], [lua >= 5.1.3])
# Checks for header files.
AC_CHECK_HEADERS([sys/inotify.h])
-###
-# --with-runner option
-AC_ARG_WITH([runner],
-[ --with-runner=
Specify directory where lsyncds part written in Lua will be placed.
- If missing it will be compiled into the binary])
-if test "x${with_runner}" != x; then
- AC_DEFINE_UNQUOTED(LSYNCD_DEFAULT_RUNNER_FILE, "${with_runner}/lsyncd.lua", "descr")
- AC_SUBST(RUNNER_DIR, "${with_runner}")
-fi
-AM_CONDITIONAL([RUNNER], [test x${with_runner} != x])
-
-## NOTE:
-## With this release Lsyncd can yet only do with inotify.
-## enabling fsevents and disabling inotify is thus commented out.
-
###
# --without-inotify option
AC_ARG_WITH([inotify],
@@ -53,7 +38,7 @@ fi
AM_CONDITIONAL([INOTIFY], [test x${with_inotify} != xno])
###
-# --with-fsevents
+# --with-fsevents
# disabled per default, experimental, works only with OS X 10.5/10.6
AC_ARG_WITH([fsevents],
[ --with-fsevents Uses MacOS (10.5) /dev/fsevents. EXPERIMENTAL!
@@ -62,7 +47,7 @@ if test "x${with_fsevents}" == xyes; then
echo "compiling with fsevents. WARNING experimental!"
AC_DEFINE(LSYNCD_WITH_FSEVENTS,,"descr")
fi
-AM_CONDITIONAL([FSEVENTS],
+AM_CONDITIONAL([FSEVENTS],
[test x${with_fsevents} != x -a xno${with_fsevents} != xno])
# Checks for typedefs, structures, and compiler characteristics.
diff --git a/lsyncd.c b/lsyncd.c
index 6e6e4af..fbb5d33 100644
--- a/lsyncd.c
+++ b/lsyncd.c
@@ -47,10 +47,8 @@
/**
* The Lua part of lsyncd if compiled into the binary.
*/
-#ifndef LSYNCD_DEFAULT_RUNNER_FILE
- extern const char runner_out[];
- extern size_t runner_size;
-#endif
+extern const char runner_out[];
+extern size_t runner_size;
extern const char defaults_out[];
extern size_t defaults_size;
@@ -1729,21 +1727,13 @@ main1(int argc, char *argv[])
if (argp < argc && !strcmp(argv[argp], "--runner")) {
if (argp + 1 >= argc) {
logstring("Error", "Lsyncd Lua-runner file missing after --runner.");
-#ifdef LSYNCD_DEFAULT_RUNNER_FILE
- printlogf(L, "Error",
- "Using '%s' as default location for runner.", LSYNCD_DEFAULT_RUNNER_FILE);
-#else
logstring("Error", "Using a statically included runner as default.");
-#endif
exit(-1); //ERRNO
}
lsyncd_runner_file = argv[argp + 1];
argp += 2;
- } else {
-#ifdef LSYNCD_DEFAULT_RUNNER_FILE
- lsyncd_runner_file = LSYNCD_DEFAULT_RUNNER_FILE;
-#endif
}
+
if (lsyncd_runner_file) {
// checks if the runner file exists
struct stat st;
@@ -1761,17 +1751,11 @@ main1(int argc, char *argv[])
exit(-1); // ERRNO
}
} else {
-#ifndef LSYNCD_DEFAULT_RUNNER_FILE
// loads the runner from binary
if (luaL_loadbuffer(L, runner_out, runner_size, "runner")) {
printlogf(L, "Error", "loading precompiled runner: %s", lua_tostring(L, -1));
exit(-1); // ERRNO
}
-#else
- // safeguard for what never ever should happen.
- logstring("Error", "Internal fail: lsyncd_runner is NULL with non-static runner");
- exit(-1); // ERRNO
-#endif
}
{
diff --git a/lsyncd.lua b/lsyncd.lua
index d4b409c..2370845 100644
--- a/lsyncd.lua
+++ b/lsyncd.lua
@@ -22,7 +22,7 @@ if lsyncd_version then
lsyncd.log('Error', 'You cannot use the lsyncd runner as configuration file!')
lsyncd.terminate(-1) -- ERRNO
end
-lsyncd_version = '2.0.6'
+lsyncd_version = '2.0.7'
-----
-- Hides the core interface from user scripts