rathena/Makefile.in
gepard1984 22f0714c07 - Added libconfig (configuration file library: http://www.hyperrealm.com/libconfig/):
- Updated VS9/10 project files.
   - Updated `configure` & `Makefile`s.
 - New GM, Commands & Permissions system:
   - '''This is a backwards compatibility breaking update''', please read tid:58877
   - Replaced GM levels with Player Groups.
   - Commands permissions & other privileges now depend on group, not GM level.
 - `@help` command improvements: requires "commandname" param and shows more detailed info about commands.
 - Modified GM whisper system to deliver messages basing on permissions, not GM level.
 - Remote trade request is now possible only if player is allowed to use `@trade` command as well.
 - Added a proper permission to use `/changemaptype` command.
 - `clif_displaymessage` is now capable of displaying multiline messages.
 - All `ACMD_FUNC`s are static now, and the only way to invoke them is with `is_atcommand()`; all client commands (starting with `/`) are now translated into corresponding atcommands (with exception of `/kick` used on monster, as there is no atcommand to kill single monster).
 - Removed nonsense "bot check" triggering when player blocked (`/ex`) Server.
 - Merged `@monster`, `@monsterbig` and `@monstersmall`.
 - Improved flow of atcommand execution to avoid revealing info about online players or existing commands to non-privileged players.
 - Merged `atcommand` and `charcommand` script functions (`charcommand` is aliased to `atcommand`).
   - Fixed `atcommand` script function reading unknown memory area (possible access violation).

git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@15572 54d463be-8e91-2dee-dedb-b68131a5f0ec
2012-02-13 01:19:04 +00:00

151 lines
4.5 KiB
Makefile

@SET_MAKE@
HAVE_MYSQL=@HAVE_MYSQL@
ifeq ($(HAVE_MYSQL),yes)
ALL_DEPENDS=common_sql login_sql char_sql map_sql tools import
SQL_DEPENDS=common_sql login_sql char_sql map_sql import
COMMON_SQL_DEPENDS=mt19937ar libconfig
LOGIN_SQL_DEPENDS=mt19937ar libconfig common_sql
CHAR_SQL_DEPENDS=mt19937ar libconfig common_sql
MAP_SQL_DEPENDS=mt19937ar libconfig common_sql
CONVERTERS_DEPENDS=common_sql
else
ALL_DEPENDS=needs_mysql
SQL_DEPENDS=needs_mysql
COMMON_SQL_DEPENDS=needs_mysql
LOGIN_SQL_DEPENDS=needs_mysql
CHAR_SQL_DEPENDS=needs_mysql
MAP_SQL_DEPENDS=needs_mysql
endif
WITH_PLUGINS=@WITH_PLUGINS@
ifeq ($(WITH_PLUGINS),yes)
ALL_DEPENDS+=plugins
PLUGIN_DEPENDS=common_sql
else
PLUGIN_DEPENDS=no_plugins
endif
#####################################################################
.PHONY: sql \
common_sql \
mt19937ar \
login_sql \
char_sql \
map_sql \
tools plugins addons \
import \
clean help
all: $(ALL_DEPENDS)
sql: $(SQL_DEPENDS)
common_sql: $(COMMON_SQL_DEPENDS)
@$(MAKE) -C src/common sql
mt19937ar:
@$(MAKE) -C 3rdparty/mt19937ar
libconfig:
@$(MAKE) -C 3rdparty/libconfig
login_sql: $(LOGIN_SQL_DEPENDS)
@$(MAKE) -C src/login sql
char_sql: $(CHAR_SQL_DEPENDS)
@$(MAKE) -C src/char
map_sql: $(MAP_SQL_DEPENDS)
@$(MAKE) -C src/map sql
tools:
@$(MAKE) -C src/tool
plugins addons: $(PLUGIN_DEPENDS)
@$(MAKE) -C src/plugins
import:
# 1) create conf/import folder
# 2) add missing files
# 3) remove remaining .svn folder
@echo "building conf/import folder..."
@if test ! -d conf/import ; then mkdir conf/import ; fi
@for f in $$(ls conf/import-tmpl) ; do if test ! -e conf/import/$$f ; then cp conf/import-tmpl/$$f conf/import ; fi ; done
@rm -rf conf/import/.svn
clean:
@$(MAKE) -C src/common $@
@$(MAKE) -C 3rdparty/mt19937ar $@
@$(MAKE) -C 3rdparty/libconfig $@
@$(MAKE) -C src/login $@
@$(MAKE) -C src/char $@
@$(MAKE) -C src/map $@
@$(MAKE) -C src/plugins $@
@$(MAKE) -C src/tool $@
help:
@echo "most common targets are 'all' 'sql' 'conf' 'clean' 'help'"
@echo "possible targets are:"
@echo "'common_sql' - builds object files used in SQL servers"
@echo "'mt19937ar' - builds object file of Mersenne Twister MT19937"
@echo "'libconfig' - builds object files of libconfig
@echo "'login_sql' - builds login server (SQL version)"
@echo "'char_sql' - builds char server (SQL version)"
@echo "'map_sql' - builds map server (SQL version)"
@echo "'tools' - builds all the tools in src/tools"
@echo "'plugins' - builds all the plugins in src/plugins"
@echo "'addons'"
@echo "'import' - builds conf/import folder from the template conf/import-tmpl"
@echo "'all' - builds all the above targets"
@echo "'sql' - builds sql servers (targets 'common_sql' 'login_sql' 'char_sql'"
@echo " 'map_sql' and 'import')"
@echo "'clean' - cleans builds and objects"
@echo "'help' - outputs this message"
#####################################################################
needs_mysql:
@echo "MySQL not found or disabled by the configure script"
@exit 1
no_plugins:
@echo "Plugins disabled by the configure script"
@exit 1
#####################################################################
# TODO
install: conf/%.conf conf/%.txt
$(shell read -p "WARNING: This target does not work properly yet. Press Ctrl+C to cancel or Enter to continue.")
$(shell mkdir -p /opt/eathena/bin/)
$(shell mkdir -p /opt/eathena/etc/eathena/)
$(shell mkdir -p /opt/eathena/var/log/eathena/)
$(shell mv save /opt/eathena/etc/eathena/save)
$(shell mv db /opt/eathena/etc/eathena/db)
$(shell mv conf /opt/eathena/etc/eathena/conf)
$(shell mv npc /opt/eathena/etc/eathena/npc)
$(shell mv log/* /opt/eathena/var/log/eathena/)
$(shell cp *-server* /opt/eathena/bin/)
$(shell ln -s /opt/eathena/etc/eathena/save/ /opt/eathena/bin/)
$(shell ln -s /opt/eathena/etc/eathena/db/ /opt/eathena/bin/)
$(shell ln -s /opt/eathena/etc/eathena/conf/ /opt/eathena/bin/)
$(shell ln -s /opt/eathena/etc/eathena/npc/ /opt/eathena/bin/)
$(shell ln -s /opt/eathena/var/log/eathena/ /opt/eathena/bin/log)
bin-clean:
$(shell rm /opt/eathena/bin/login-server*)
$(shell rm /opt/eathena/bin/char-server*)
$(shell rm /opt/eathena/bin/map-server*)
uninstall:
$(shell read -p "WARNING: This target does not work properly yet. Press Ctrl+C to cancel or Enter to continue.")
bin-clean
$(shell rm /opt/eathena/bin/save)
$(shell rm /opt/eathena/bin/db)
$(shell rm /opt/eathena/bin/conf)
$(shell rm /opt/eathena/bin/npc)
$(shell rm /opt/eathena/bin/log)
$(shell rm -rf /opt/eathena/etc/eathena)
$(shell rm -rf /opt/eathena/var/log/eathena)