some header changes to work with older systems. expose readdir to user scripts. write examples into doc dir

This commit is contained in:
Axel Kittenberger 2011-07-19 13:29:19 +00:00
parent a71edbbd29
commit 4c56100dd0
4 changed files with 7 additions and 1 deletions

View File

@ -11,7 +11,7 @@ endif
#endif
lsyncd_LDADD = $(LUA_LIBS)
exampledir = $(datarootdir)/doc/@PACKAGE@
exampledir = $(docdir)/
dist_example_DATA = \
examples/lbash.lua \
examples/lecho.lua \

View File

@ -30,6 +30,7 @@
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <strings.h>
#include <syslog.h>
#include <math.h>
#include <time.h>

View File

@ -11,6 +11,10 @@
#ifndef LSYNCD_H
#define LSYNCD_H
/* some older machines need this to see pselect */
#define _BSD_SOURCE 1
#define _XOPEN_SOURCE 600
/* includes needed for headerfile */
#include "config.h"

View File

@ -38,6 +38,7 @@ _l = nil
log = lsyncd.log
terminate = lsyncd.terminate
now = lsyncd.now
readdir = lsyncd.readdir
-- just to safe from userscripts changing this.
local log = log
local terminate = terminate