diff options
Diffstat (limited to 'src/login')
-rw-r--r-- | src/login/Makefile.in | 38 |
1 files changed, 21 insertions, 17 deletions
diff --git a/src/login/Makefile.in b/src/login/Makefile.in index a97d17f68..fa5f92105 100644 --- a/src/login/Makefile.in +++ b/src/login/Makefile.in @@ -1,26 +1,29 @@ -COMMON_H = $(shell ls ../common/*.h) -CONFIG_H = $(shell ls ../config/*.h ../config/*/*.h) +CONFIG_D = ../config +CONFIG_H = $(wildcard $(CONFIG_D)/*.h) $(wildcard $(CONFIG_D)/*/*.h) -MT19937AR_D = ../../3rdparty/mt19937ar -MT19937AR_OBJ = $(MT19937AR_D)/mt19937ar.o -MT19937AR_H = $(MT19937AR_D)/mt19937ar.h -MT19937AR_INCLUDE = -I$(MT19937AR_D) +COMMON_D = ../common +COMMON_H = $(wildcard $(COMMON_D)/*.h) LIBCONFIG_D = ../../3rdparty/libconfig LIBCONFIG_OBJ = $(addprefix $(LIBCONFIG_D)/, libconfig.o grammar.o scanctx.o \ - scanner.o strbuf.o) + scanner.o strbuf.o) LIBCONFIG_H = $(addprefix $(LIBCONFIG_D)/, libconfig.h grammar.h parsectx.h \ - scanctx.h scanner.h strbuf.h wincompat.h) + scanctx.h scanner.h strbuf.h wincompat.h) LIBCONFIG_INCLUDE = -I$(LIBCONFIG_D) -LOGIN_OBJ = $(addprefix obj_sql/, account_sql.o ipban_sql.o login.o \ - loginlog_sql.o) +MT19937AR_D = ../../3rdparty/mt19937ar +MT19937AR_OBJ = $(MT19937AR_D)/mt19937ar.o +MT19937AR_H = $(MT19937AR_D)/mt19937ar.h +MT19937AR_INCLUDE = -I$(MT19937AR_D) + +LOGIN_C = account_sql.c ipban_sql.c login.c loginlog_sql.c +LOGIN_OBJ = $(addprefix obj_sql/, $(patsubst %.c,%.o,$(LOGIN_C))) LOGIN_H = login.h account.h ipban.h loginlog.h HAVE_MYSQL=@HAVE_MYSQL@ ifeq ($(HAVE_MYSQL),yes) - LOGIN_SERVER_SQL_DEPENDS=$(LOGIN_OBJ) ../common/obj_sql/common_sql.a ../common/obj_all/common.a $(MT19937AR_OBJ) $(LIBCONFIG_OBJ) + LOGIN_SERVER_SQL_DEPENDS=$(LOGIN_OBJ) $(COMMON_D)/obj_sql/common_sql.a $(COMMON_D)/obj_all/common.a $(MT19937AR_OBJ) $(LIBCONFIG_OBJ) else LOGIN_SERVER_SQL_DEPENDS=needs_mysql endif @@ -75,22 +78,23 @@ login-server: ../../login-server@EXEEXT@ ../../login-server@EXEEXT@: $(LOGIN_SERVER_SQL_DEPENDS) Makefile @echo " LD $(notdir $@)" - @$(CC) @LDFLAGS@ -o ../../login-server@EXEEXT@ $(LOGIN_OBJ) ../common/obj_sql/common_sql.a ../common/obj_all/common.a $(MT19937AR_OBJ) $(LIBCONFIG_OBJ) @LIBS@ @MYSQL_LIBS@ + @$(CC) @LDFLAGS@ -o ../../login-server@EXEEXT@ $(LOGIN_OBJ) $(COMMON_D)/obj_sql/common_sql.a \ + $(COMMON_D)/obj_all/common.a $(MT19937AR_OBJ) $(LIBCONFIG_OBJ) @LIBS@ @MYSQL_LIBS@ # login object files obj_sql/%.o: %.c $(LOGIN_H) $(COMMON_H) $(CONFIG_H) $(MT19937AR_H) $(LIBCONFIG_H) | obj_sql @echo " CC $<" - @$(CC) @CFLAGS@ $(MT19937AR_INCLUDE) $(LIBCONFIG_INCLUDE) -DWITH_SQL @MYSQL_CFLAGS@ @CPPFLAGS@ -c $(OUTPUT_OPTION) $< + @$(CC) @CFLAGS@ $(MT19937AR_INCLUDE) $(LIBCONFIG_INCLUDE) @MYSQL_CFLAGS@ @CPPFLAGS@ -c $(OUTPUT_OPTION) $< # missing object files -../common/obj_all/common.a: +$(COMMON_D)/obj_all/common.a: @echo " MAKE $@" - @$(MAKE) -C ../common sql + @$(MAKE) -C $(COMMON_D) sql -../common/obj_sql/common_sql.a: +$(COMMON_D)/obj_sql/common_sql.a: @echo " MAKE $@" - @$(MAKE) -C ../common sql + @$(MAKE) -C $(COMMON_D) sql $(MT19937AR_OBJ): @echo " MAKE $@" |