Skip to content

Commit

Permalink
honor prefix for conf/sqlite/yamlfile
Browse files Browse the repository at this point in the history
  • Loading branch information
nrh committed Nov 20, 2011
1 parent 882e26b commit dcc100b
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion libcrange/source/functions/Makefile.am
@@ -1,4 +1,4 @@
AM_CFLAGS = -g -pg -Wall -DLIBCRANGE_FUNCDIR=\"$(pkglibdir)\" -I../src @PCRE_CFLAGS@ @APR_CFLAGS@
AM_CFLAGS = -g -pg -Wall -DLIBCRANGE_FUNCDIR=\"$(pkglibdir)\" -DLIBCRANGE_CONF=\"$(sysconfdir)/range.conf\" -DDEFAULT_SQLITE_DB=\"$(localstatedir)/range.sqlite\" -DLIBCRANGE_YAML_DIR=\"$(sysconfdir)/range/\" -I../src @PCRE_CFLAGS@ @APR_CFLAGS@
AM_LDFLAGS = -module -L../src -lcrange -lyaml -lsqlite3 @PCRE_LIBS@ @APR_LIBS@

pkglib_LTLIBRARIES = yst-ip-list.la ip.la nodescf.la yamlfile.la sqlite.la
Expand Down
2 changes: 1 addition & 1 deletion libcrange/source/functions/yamlfile.c
Expand Up @@ -65,7 +65,7 @@ the key will be composed of all elements set-added together.
#include "libcrange.h"
#include "range.h"

static const char* yaml_path = "/etc/range";
static const char* yaml_path = LIBCRANGE_YAML_DIR;

/* List of functions that are provided by this module */
const char** functions_provided(libcrange* lr)
Expand Down
2 changes: 1 addition & 1 deletion libcrange/source/src/Makefile.am
Expand Up @@ -15,7 +15,7 @@ libcrange_la_SOURCES = range_parser.y range_scanner.l \
libcrange.c ast.c range_compress.c \
range.c

libcrange_la_CFLAGS = -Wall -DLIBCRANGE_FUNCDIR=\"$(pkglibdir)\" @PERL_CFLAGS@ @PCRE_CFLAGS@ @APR_CFLAGS@
libcrange_la_CFLAGS = -Wall -DLIBCRANGE_FUNCDIR=\"$(pkglibdir)\" -DLIBCRANGE_CONF=\"$(sysconfdir)/range.conf\" -DDEFAULT_SQLITE_DB=\"$(localstatedir)/range.sqlite\" -DLIBCRANGE_YAML_DIR=\"$(sysconfdir)/range/\" @PERL_CFLAGS@ @PCRE_CFLAGS@ @APR_CFLAGS@
libcrange_la_LDFLAGS = @PERL_LIBS@ @PCRE_LIBS@ @APR_LIBS@

range_scanner.h:
Expand Down
4 changes: 2 additions & 2 deletions libcrange/source/src/libcrange.h
Expand Up @@ -15,8 +15,8 @@ extern "C"

#define LIBCRANGE_VERSION "1.0"

#define LIBCRANGE_CONF "/etc/libcrange.conf"
#define DEFAULT_SQLITE_DB "/etc/range.sqlite"
//#define LIBCRANGE_CONF "/usr/local/etc/libcrange.conf"
//#define DEFAULT_SQLITE_DB "/usr/local/var/libcrange/range.sqlite"
//#define LIBCRANGE_FUNCDIR "/usr/lib/libcrange"

struct libcrange;
Expand Down

0 comments on commit dcc100b

Please sign in to comment.