diff options
-rw-r--r-- | Makefile.bundle.in | 24 | ||||
-rw-r--r-- | Makefile.in | 1 | ||||
-rw-r--r-- | config.lib | 8 |
3 files changed, 23 insertions, 10 deletions
diff --git a/Makefile.bundle.in b/Makefile.bundle.in index f5ac2c5fa..f685c342c 100644 --- a/Makefile.bundle.in +++ b/Makefile.bundle.in @@ -141,37 +141,41 @@ install: bundle $(Q)install -d "$(INSTALL_DATA_DIR)/data" $(Q)install -d "$(INSTALL_DATA_DIR)/lang" $(Q)install -d "$(INSTALL_DOC_DIR)" - $(Q)install -m 755 "$(BUNDLE_DIR)/$(TTD)" "$(INSTALL_BINARY_DIR)" +ifeq ($(TTD), openttd.exe) + $(Q)install -m 755 "$(BUNDLE_DIR)/$(TTD)" "$(INSTALL_BINARY_DIR)/${BINARY_NAME}.exe" +else + $(Q)install -m 755 "$(BUNDLE_DIR)/$(TTD)" "$(INSTALL_BINARY_DIR)/${BINARY_NAME}" +endif $(Q)install -m 644 "$(BUNDLE_DIR)/lang/"* "$(INSTALL_DATA_DIR)/lang" $(Q)install -m 644 "$(BUNDLE_DIR)/data/"* "$(INSTALL_DATA_DIR)/data" $(Q)install -m 644 "$(BUNDLE_DIR)/docs/"* "$(INSTALL_DOC_DIR)" $(Q)install -m 644 "$(BUNDLE_DIR)/"*.txt "$(INSTALL_DOC_DIR)" $(Q)install -m 644 "$(BUNDLE_DIR)/COPYING" "$(INSTALL_DOC_DIR)" - $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.32.xpm" "$(INSTALL_ICON_DIR)" + $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.32.xpm" "$(INSTALL_ICON_DIR)/${BINARY_NAME}.32.xpm" ifdef ICON_THEME_DIR $(Q)install -d "$(INSTALL_ICON_THEME_DIR)" $(Q)install -d "$(INSTALL_ICON_THEME_DIR)/16x16/apps" - $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.16.png" "$(INSTALL_ICON_THEME_DIR)/16x16/apps" + $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.16.png" "$(INSTALL_ICON_THEME_DIR)/16x16/apps/${BINARY_NAME}.png" $(Q)install -d "$(INSTALL_ICON_THEME_DIR)/32x32/apps" - $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.32.png" "$(INSTALL_ICON_THEME_DIR)/32x32/apps" + $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.32.png" "$(INSTALL_ICON_THEME_DIR)/32x32/apps/${BINARY_NAME}.png" $(Q)install -d "$(INSTALL_ICON_THEME_DIR)/48x48/apps" - $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.48.png" "$(INSTALL_ICON_THEME_DIR)/48x48/apps" + $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.48.png" "$(INSTALL_ICON_THEME_DIR)/48x48/apps/${BINARY_NAME}.png" $(Q)install -d "$(INSTALL_ICON_THEME_DIR)/64x64/apps" - $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.64.png" "$(INSTALL_ICON_THEME_DIR)/64x64/apps" + $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.64.png" "$(INSTALL_ICON_THEME_DIR)/64x64/apps/${BINARY_NAME}.png" $(Q)install -d "$(INSTALL_ICON_THEME_DIR)/128x128/apps" - $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.128.png" "$(INSTALL_ICON_THEME_DIR)/128x128/apps" + $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.128.png" "$(INSTALL_ICON_THEME_DIR)/128x128/apps/${BINARY_NAME}.png" $(Q)install -d "$(INSTALL_ICON_THEME_DIR)/256x256/apps" - $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.256.png" "$(INSTALL_ICON_THEME_DIR)/256x256/apps" + $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.256.png" "$(INSTALL_ICON_THEME_DIR)/256x256/apps/${BINARY_NAME}.png" else $(Q)install -m 644 "$(BUNDLE_DIR)/media/"*.png "$(INSTALL_ICON_DIR)" endif ifdef MAN_DIR $(Q)install -d "$(INSTALL_MAN_DIR)" - $(Q)install -m 644 "$(BUNDLE_DIR)/man/openttd.6.gz" "$(INSTALL_MAN_DIR)" + $(Q)install -m 644 "$(BUNDLE_DIR)/man/openttd.6.gz" "$(INSTALL_MAN_DIR)/${BINARY_NAME}.6.gz" endif ifdef MENU_DIR $(Q)install -d "$(INSTALL_MENU_DIR)" - $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.desktop" "$(INSTALL_MENU_DIR)" + $(Q)install -m 644 "$(BUNDLE_DIR)/media/openttd.desktop" "$(INSTALL_MENU_DIR)/${BINARY_NAME}.desktop" endif $(Q)cp -R "$(BUNDLE_DIR)/scenario" "$(INSTALL_DATA_DIR)" endif # OSXAPP diff --git a/Makefile.in b/Makefile.in index d23a12ea5..9d004997a 100644 --- a/Makefile.in +++ b/Makefile.in @@ -28,6 +28,7 @@ INSTALL_ICON_DIR = "$(INSTALL_DIR)/"!!ICON_DIR!! INSTALL_ICON_THEME_DIR = "$(INSTALL_DIR)/$(ICON_THEME_DIR)" INSTALL_DATA_DIR = "$(INSTALL_DIR)/"!!DATA_DIR!! INSTALL_DOC_DIR = "$(INSTALL_DIR)/"!!DOC_DIR!! +BINARY_NAME = !!BINARY_NAME!! TTD = !!TTD!! TTDS = $(SRC_DIRS:%=%/$(TTD)) OS = !!OS!! diff --git a/config.lib b/config.lib index c60de2432..78d7301de 100644 --- a/config.lib +++ b/config.lib @@ -37,6 +37,7 @@ set_default() { man_dir="1" menu_dir="1" menu_group="Game;" + binary_name="openttd" enable_debug="0" enable_desync_debug="0" enable_profiling="0" @@ -100,6 +101,7 @@ set_default() { shared_dir install_dir menu_group + binary_name enable_debug enable_desync_debug enable_profiling @@ -213,6 +215,9 @@ detect_params() { --menu-dir=*) menu_dir="$optarg";; --without-menu-entry) menu_dir="";; + --binary-name) prevp_p="binary_name";; + --binary-name=*) binary_name="$optarg";; + --man-dir) prevp_p="man_dir";; --man-dir=*) man_dir="$optarg";; @@ -2311,6 +2316,7 @@ make_sed() { s~!!PERSONAL_DIR!!~$personal_dir~g; s~!!SHARED_DIR!!~$shared_dir~g; s~!!INSTALL_DIR!!~$install_dir~g; + s~!!BINARY_NAME!!~$binary_name~g; s~!!STRGEN!!~$STRGEN~g; s~!!ENDIAN_CHECK!!~$ENDIAN_CHECK~g; s~!!ENDIAN_FORCE!!~$endian~g; @@ -2521,6 +2527,8 @@ showhelp() { echo " [os-dependent default]" echo " --install-dir=dir specifies the root to install to." echo " Useful to install into jails [/]" + echo " --binary-name the name used for the binary, icons," + echo " desktop file, etc. when installing [openttd]" echo "" echo "Features and packages:" echo " --enable-debug[=LVL] enable debug-mode (LVL=[0123], 0 is release)" |