summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorTobias Klauser <tklauser@distanz.ch>2018-03-06 14:11:53 +0100
committerTobias Klauser <tklauser@distanz.ch>2018-03-06 14:15:57 +0100
commit44ceece354c50795ba04e450b9269e6e3f92dd34 (patch)
treeb42200519bd20266990ac0db97b780e7de974129 /Makefile
parentb90d055be5dd30212ebd0c0a810a7f020df70321 (diff)
geoip: store GeoIP files in $(PREFIX)/share by default
The /etc directory shouldn't contain non-human-readable files. netsniff-ng (when called with the '-U' option) currently installs the GeoIP database files to /etc/netsniff-ng by default. Change this to install them to $(PREFIX)/share/netsniff-ng instead, which is conformant to the FHS [1]. [1] https://wiki.debian.org/FilesystemHierarchyStandard Also create the respective directory in the 'make install' target. Fixes #187 Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile3
1 files changed, 3 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index aba2983..59d79ac 100644
--- a/Makefile
+++ b/Makefile
@@ -36,6 +36,7 @@ SBINDIR = $(PREFIX)/sbin
INCDIR = $(PREFIX)/include
ETCDIR ?= $(CONFIG_ETCDIR)
ETCDIRE = $(ETCDIR)/netsniff-ng
+DATDIR = $(PREFIX)/share/netsniff-ng
MAN8DIR = $(PREFIX)/share/man/man8
# Shut up make, helper warnings, parallel compilation!
@@ -102,6 +103,7 @@ CFLAGS_MIN += -D_FILE_OFFSET_BITS=64
CFLAGS_MIN += -DVERSION_STRING=\"$(VERSION_STRING)\"
CFLAGS_MIN += -DVERSION_LONG=\"$(VERSION_LONG)\"
CFLAGS_MIN += -DETCDIRE_STRING=\"$(ETCDIRE)\"
+CFLAGS_MIN += -DDATDIR_STRING=\"$(DATDIR)\"
WFLAGS_DEF = -Wall
@@ -170,6 +172,7 @@ mrproper: distclean
install: install_all
install_all: $(foreach tool,$(TOOLS),$(tool)_install)
+ $(Q)$(call INSTD,$(DATDIR))
install_allbutcurvetun: $(foreach tool,$(filter-out curvetun,$(TOOLS)),$(tool)_install)
install_allbutmausezahn: $(foreach tool,$(filter-out mausezahn,$(TOOLS)),$(tool)_install)
uninstall: $(foreach tool,$(TOOLS),$(tool)_uninstall)