2. The directory given by the NEVERBALL_DATA environment variable.
- 3. The directory given by the CONFIG_DATA macro defined in
- share/base_config.h
+ 3. The directory given by the CONFIG_DATA macro defined in
+ share/base_config.h (which corresponds to the DATADIR Makefile
+ variable).
-A normal Linux installation would probably copy the data directory to
-"/usr/local/share/games/neverball/" and change the CONFIG_DATA macro
-to match.
+A normal Linux installation would probably copy the data directory to
+"/usr/local/share/games/neverball/" and set DATADIR to match.
* DISTRIBUTION
# MINGW=1 also supported.
#------------------------------------------------------------------------------
+# Paths (packagers might want to set DATADIR and LOCALEDIR)
+
+USERDIR := .neverball
+DATADIR := ./data
+LOCALEDIR := ./locale
+
+ifdef MINGW
+ USERDIR := Neverball
+endif
+
+ifneq ($(BUILD),release)
+ USERDIR := $(USERDIR)-dev
+endif
+
+#------------------------------------------------------------------------------
# Optional flags (CFLAGS, CPPFLAGS, ...)
ifeq ($(DEBUG),1)
ALL_CPPFLAGS := $(SDL_CPPFLAGS) $(PNG_CPPFLAGS) -Ishare \
-DVERSION=\"$(VERSION)\"
+ALL_CPPFLAGS += \
+ -DCONFIG_USER=\"$(USERDIR)\" \
+ -DCONFIG_DATA=\"$(DATADIR)\" \
+ -DCONFIG_LOCALE=\"$(LOCALEDIR)\"
+
ifeq ($(ENABLE_NLS),0)
ALL_CPPFLAGS += -DENABLE_NLS=0
else
/* User config directory */
#ifndef CONFIG_USER
#ifdef _WIN32
-#define CONFIG_USER "Neverball-dev"
+#define CONFIG_USER "Neverball"
#else
-#define CONFIG_USER ".neverball-dev"
+#define CONFIG_USER ".neverball"
#endif
#endif