summaryrefslogtreecommitdiff
path: root/riff
diff options
context:
space:
mode:
authorKalle Vahlman <kalle.vahlman@movial.com>2011-09-16 09:04:54 +0300
committerKalle Vahlman <kalle.vahlman@movial.com>2011-09-16 09:04:54 +0300
commitfac26f795cf96ec624a3a334ba9b78ea2d86811d (patch)
treefdf9282ea01c29b0198f7b355e0cd3d787fb5673 /riff
parented586c55775a214cbc9c746450643271d73efde0 (diff)
Propagate PREFIX to the code to find the default config file
Now that we can install into PREFIX, we need to reflect that in the location of the default config file.
Diffstat (limited to 'riff')
-rw-r--r--riff/main.h2
-rw-r--r--riff/riff.mk3
2 files changed, 3 insertions, 2 deletions
diff --git a/riff/main.h b/riff/main.h
index 7826eb4..916e523 100644
--- a/riff/main.h
+++ b/riff/main.h
@@ -31,7 +31,7 @@ enum ConnectionType {
Logger* logger_;
Config* config_;
-char configFile[PATH_LENGTH] = "/usr/share/riff/config";
+char configFile[PATH_LENGTH] = RIFF_CONFIG_PREFIX "/share/riff/config";
char flashimage[PATH_LENGTH] = "\0";
char address[PATH_LENGTH] = "0";
char length[PATH_LENGTH] = "0";
diff --git a/riff/riff.mk b/riff/riff.mk
index f083879..b81d343 100644
--- a/riff/riff.mk
+++ b/riff/riff.mk
@@ -1,7 +1,8 @@
# Makefile - riff
+PREFIX := /usr
CXX=g++
-CFLAGS=-I../os_wrappers -I../CDAL -D_FILE_OFFSET_BITS=64
+CFLAGS=-I../os_wrappers -I../CDAL -D_FILE_OFFSET_BITS=64 -DRIFF_CONFIG_PREFIX=\"$(PREFIX)\"
CXXFLAGS=$(CFLAGS)
LD=$(CXX) $(CXXFLAGS)
LDFLAGS=-L../CDAL