]> jfr.im git - irc/gameservirc.git/blobdiff - gameserv/Makefile.in
More exciting additions to FilePlayerDAO!
[irc/gameservirc.git] / gameserv / Makefile.in
index 43b88b5c41801aa6a37ffa05479ac6b815c490ed..95201789528909d7ce26d1bda38fa124f1e4324b 100644 (file)
@@ -12,68 +12,96 @@ libdir = $(prefix)/lib/gnudl
 mandir = $(prefix)/man/man1
 
 CC = @CXX@
-CPPFLAGS = -Wno-deprecated @CPPFLAGS@
+CPPFLAGS = -Wall @CPPFLAGS@
 CFLAGS = $(CPPFLAGS) @CFLAGS@
 LDFLAGS = @LDFLAGS@
 LIBS = @LIBS@
 INSTALL = @INSTALL@
 
-all:   tcpclient
+DRIVER = tcpclient.cpp
+CONSOLEDRIVER = devel.cpp
+
+TSRCS =        aClient.cpp \
+       boolean.cpp \
+       config.cpp \
+       c_forest.cpp \
+       do_admin.cpp \
+       do_attack.cpp \
+       do_bank.cpp \
+       do_check.cpp \
+       do_dragon.cpp \
+       do_equip.cpp \
+       do_fight.cpp \
+       do_heal.cpp \
+       do_help.cpp \
+       do_identify.cpp \
+       do_inventory.cpp \
+       do_list.cpp \
+       do_load.cpp \
+       do_logout.cpp \
+       do_master.cpp \
+       do_raw.cpp \
+       do_refresh.cpp \
+       do_register.cpp \
+       do_reset.cpp \
+       do_run.cpp \
+       do_save.cpp \
+       do_set.cpp \
+       do_shutdown.cpp \
+       do_stats.cpp \
+       do_store.cpp \
+       do_tavern.cpp \
+       do_use.cpp \
+       find.cpp \
+       gameserv.cpp \
+       hash.cpp \
+       item.cpp \
+       level.cpp \
+       loadsave.cpp \
+       log.cpp \
+       messages.cpp \
+       misc.cpp \
+       news.cpp \
+       pouch.cpp \
+       player.cpp \
+       script.cpp \
+       sockhelp.cpp \
+       strings.cpp \
+       toplist.cpp
+
+CONSOLESRCS = $(TSRCS) $(CONSOLEDRIVER)
+SRCS = $(TSRCS) $(DRIVER)
+ALLSRCS = $(TSRCS) $(DRIVER) $(CONSOLEDRIVER)
+
+OBJS = ${SRCS:.cpp=.o}
+CONSOLEOBJS = $(CONSOLESRCS:.cpp=.o)
+
+all:   gameserv
 
 clean:
        /bin/rm -f *.o
 
 distclean: clean
-       /bin/rm -f Makefile config.h config.status config.cache config.log gameserv
+       /bin/rm -f Makefile config.h config.status config.cache config.log \
+       options.h gameserv .config .gstimestamp
 
-tcpclient:     aClient.o config.o c_forest.o gameserv.o player.o sockhelp.o tcpclient.o
-       $(CC) -o gameserv aClient.o config.o c_forest.o gameserv.o player.o sockhelp.o\
-       tcpclient.o $(LIBS)
+gameserv: $(OBJS)
+       $(CC) -o $@ $(OBJS) $(LIBS)
 
-tcpclient.o:   tcpclient.cpp aClient.h player.h  extern.h  list.h listnode.h  sockhelp.h
-       $(CC) $(CFLAGS) -c tcpclient.cpp
+.cpp.o:
+       $(CC) $(CFLAGS) -c $<
 
-tcpserver.o:   tcpserver.cpp sockhelp.cpp
-       $(CC) $(CFLAGS) -c tcpserver.cpp
+depend:
+       $(CC) -MM $(CFLAGS) $(ALLSRCS) > .depend
 
-sockhelp.o:    sockhelp.cpp aClient.h player.h extern.h  list.h listnode.h  sockhelp.h
-       $(CC) $(CFLAGS) -c sockhelp.cpp
+configscript: configscript.o
+       $(CC) -o .config configscript.o
 
-aClient.o:     aClient.cpp aClient.h player.h extern.h  list.h listnode.h sockhelp.h
-       $(CC) $(CFLAGS) -c aClient.cpp
+console: $(CONSOLEOBJS)
+       $(CC) -o $@ $(CONSOLEOBJS) $(LIBS)
 
-gameserv.o:    gameserv.cpp aClient.h player.h extern.h list.h\
-               listnode.h sockhelp.h
-       $(CC) $(CFLAGS) -c gameserv.cpp
-
-c_forest.o:    c_forest.cpp aClient.h player.h extern.h list.h\
-               listnode.h sockhelp.h
-       $(CC) $(CFLAGS) -c c_forest.cpp
-
-player.o:      player.cpp aClient.h player.h extern.h list.h listnode.h sockhelp.h
-       $(CC) $(CFLAGS) -c player.cpp
-
-config.o:      config.cpp extern.h
-       $(CC) $(CFLAGS) -c config.cpp
-
-${srcdir}/configure: configure.in
-       cd ${srcdir} && autoconf
-
-# autoheader might not change config.h.in, so touch a stamp file
-${srcdir}/config.h.in: stamp-h.in
-
-${srcdir}/stamp-h.in: configure.in
-               cd ${srcdir} && autoheader
-               echo timestamp > ${srcdir}/stamp-h.in
-
-config.h: stamp-h
-
-stamp-h: config.h.in config.status
-       ./config.status
-
-Makefile: Makefile.in config.status
-       ./config.status
-
-config.status: configure
-       ./config.status --recheck
+# Catch any changes in the Makefile, everything depends on it.
+$(OBJS): Makefile
+$(CONSOLEOBJS): Makefile
 
+include .depend