summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormatthijs <matthijs@openttd.org>2006-01-28 10:16:15 +0000
committermatthijs <matthijs@openttd.org>2006-01-28 10:16:15 +0000
commit5e2c06752f1d8728c809d7f088cf53f9efe67847 (patch)
treed3cdb2deaaa1140174062781347188aedf1b3916
parent7428b4503f75d7e81a1046bd15f33d4b5c24bc78 (diff)
downloadopenttd-5e2c06752f1d8728c809d7f088cf53f9efe67847.tar.xz
(svn r3456) - Feature: [Makefile] Icons can now be installed in a seperate directory.
-rw-r--r--Makefile8
-rw-r--r--makefiledir/Makefile.config_writer1
2 files changed, 7 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 16c053484..a9ce9f36c 100644
--- a/Makefile
+++ b/Makefile
@@ -83,6 +83,8 @@
# share/games/openttd. (Will be prefixed with $PREFIX) Note that scenarios
# are only put here if USE_HOMEDIR is true, otherwise they are placed in
# PERSONAL_DIR/scenario
+# ICON_DIR: The location of the openttd icon. (Will be prefixed with
+# $PREFIX).
# PERSONAL_DIR: The directory where openttd.cfg and the save folder will be
# stored. You cannot use ~ here, define USE_HOMEDIR for that.
# USE_HOMEDIR: If this variable is set, PERSONAL_DIR will be prefixed with
@@ -570,10 +572,12 @@ ifdef INSTALL
# the prefix is not prepended in the makefile config
BINARY_DIR_PREFIXED:=$(PREFIX)/$(BINARY_DIR)
DATA_DIR_PREFIXED:=$(PREFIX)/$(DATA_DIR)
+ICON_DIR_PREFIXED:=$(PREFIX)/$(ICON_DIR)
# We use _INSTALL vars here, these vars are the locations where the files will
# be installed
DATA_DIR_INSTALL=$(DEST_DIR)/$(DATA_DIR_PREFIXED)
BINARY_DIR_INSTALL=$(DEST_DIR)/$(BINARY_DIR_PREFIXED)
+ICON_DIR_INSTALL=$(DEST_DIR)/$(ICON_DIR_PREFIXED)
# Let the code know where to find stuff
ifdef DATA_DIR_PREFIXED
CDEFS += -DGAME_DATA_DIR=\"$(DATA_DIR_PREFIXED)/\"
@@ -922,8 +926,8 @@ endif
install -m 644 lang/*.lng $(DATA_DIR_INSTALL)/lang
install -m 644 data/*.grf $(DATA_DIR_INSTALL)/data
install -m 644 data/opntitle.dat $(DATA_DIR_INSTALL)/data
- install -m 644 media/openttd.64.png $(DATA_DIR_INSTALL)
- install -m 644 media/openttd.32.xpm $(DATA_DIR_INSTALL)
+ install -m 644 media/openttd.64.png $(ICON_DIR_INSTALL)
+ install -m 644 media/openttd.32.xpm $(ICON_DIR_INSTALL)
ifndef USE_HOMEDIR
cp scenario/* $(PERSONAL_DIR)/scenario/
else
diff --git a/makefiledir/Makefile.config_writer b/makefiledir/Makefile.config_writer
index 7d5430326..8b0d2da4d 100644
--- a/makefiledir/Makefile.config_writer
+++ b/makefiledir/Makefile.config_writer
@@ -42,6 +42,7 @@ $(MAKE_CONFIG):
$(call CONFIG_LINE,PREFIX:=$(PREFIX))
$(call CONFIG_LINE,BINARY_DIR:=$(BINARY_DIR))
$(call CONFIG_LINE,DATA_DIR:=$(DATA_DIR))
+ $(call CONFIG_LINE,ICON_DIR:=$(ICON_DIR))
$(call CONFIG_LINE,USE_HOMEDIR:=$(USE_HOMEDIR))
$(call CONFIG_LINE,PERSONAL_DIR:=$(PERSONAL_DIR))
$(call CONFIG_LINE,SECOND_DATA_PATH:=$(SECOND_DATA_PATH))