From fa5b233767ca9d4e012839c28eb13628d2ebba63 Mon Sep 17 00:00:00 2001 From: piaip Date: Sat, 10 Sep 2005 06:24:56 +0000 Subject: Automake is a hard work, still not working now. git-svn-id: http://opensvn.csie.org/pttbbs/branches/piaip.automake@3152 63ad8ddf-47c3-0310-b6dd-a9e9d9715204 --- mbbsd/Makefile | 63 ------------------------------------------------------ mbbsd/Makefile.am | 41 +++++++++++++++++++++++++++++++++++ mbbsd/Makefile.old | 63 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 104 insertions(+), 63 deletions(-) delete mode 100644 mbbsd/Makefile create mode 100644 mbbsd/Makefile.am create mode 100644 mbbsd/Makefile.old (limited to 'mbbsd') diff --git a/mbbsd/Makefile b/mbbsd/Makefile deleted file mode 100644 index a635cb48..00000000 --- a/mbbsd/Makefile +++ /dev/null @@ -1,63 +0,0 @@ -# $Id$ - -.include "../pttbbs.mk" - -.if defined(WITH_BLOG) -CFLAGS+= -DBLOG -LDFLAGS+= -L/usr/local/lib/mysql -lmysqlclient -.endif - - -PROG= mbbsd -OBJS= admin.o announce.o args.o assess.o bbs.o board.o cache.o cal.o card.o\ - chat.o chc.o chc_tab.o chicken.o convert.o crypt.o dark.o edit.o fav.o friend.o gamble.o\ - gomo.o guess.o indict.o io.o kaede.o lovepaper.o mail.o mbbsd.o menu.o\ - more.o name.o osdep.o othello.o read.o record.o register.o\ - screen.o stuff.o talk.o term.o topsong.o user.o brc.o vice.o vote.o\ - xyz.o voteboard.o syspost.o var.o passwd.o calendar.o go.o file.o \ - pmore.o chess.o - -.if defined(DIET) -OBJS+= random.o time.o -DIETCC= diet -Os -.endif -#CFLAGS+=-g -#CFLAGS+=-std=c99 - -# reduce .bss align overhead -.if !defined(DEBUG) -LDFLAGS+=-Wl,--sort-common -.endif - -.if defined(MERGEBBS) -CFLAGS+= -DMERGEBBS -OBJS+= merge.o -.endif - -.SUFFIXES: .c .o -.c.o: ../include/var.h - $(CCACHE) $(DIETCC) $(CC) $(CFLAGS) -c $*.c - -all: $(PROG) - -$(PROG): $(OBJS) - sh ../util/newvers.sh - $(DIETCC) $(CC) $(LDFLAGS) -o $(PROG) $(OBJS) $(LIBS) $(EXT_LIBS) vers.c - -../include/var.h: var.c - perl ../util/parsevar.pl < var.c > ../include/var.h - -test: $(PROG) - killall -9 testmbbsd || true - cp mbbsd testmbbsd - ./testmbbsd 9000 - rm -f testmbbsd - -install: $(PROG) - install -d $(BBSHOME)/bin/ - install -c -m 755 $(PROG) $(BBSHOME)/bin/ - mv -f $(BBSHOME)/bin/mbbsd $(BBSHOME)/bin/mbbsd.`date '+%m%d%H%M'` - ln -sv $(BBSHOME)/bin/mbbsd.`date '+%m%d%H%M'` $(BBSHOME)/bin/mbbsd - -clean: - rm -f $(OBJS) $(PROG) diff --git a/mbbsd/Makefile.am b/mbbsd/Makefile.am new file mode 100644 index 00000000..8d19b6ff --- /dev/null +++ b/mbbsd/Makefile.am @@ -0,0 +1,41 @@ +######################################################################## +# PTT BBS Automake +# Create: piaip, Sat Sep 10 10:36:56 CST 2005 +######################################################################## +# $Id$ + +bin_PROGRAMS=mbbsd + +mbbsd_SOURCES= \ + ../include/var.h \ + admin.c announce.c args.c assess.c bbs.c board.c brc.c cache.c \ + cal.c calendar.c card.c chat.c chc.c chc_tab.c chess.c chicken.c \ + convert.c crypt.c dark.c edit.c fav.c file.c friend.c gamble.c \ + go.c gomo.c guess.c indict.c io.c kaede.c lovepaper.c mail.c \ + mbbsd.c menu.c more.c name.c osdep.c othello.c passwd.c pmore.c \ + read.c record.c register.c screen.c stuff.c syspost.c talk.c \ + term.c topsong.c user.c var.c vice.c vote.c voteboard.c xyz.c + +../include/var.h: var.c + perl ../util/parsevar.pl < var.c > ../include/var.h + +## reduce .bss align overhead +#.if !defined(DEBUG) +#LDFLAGS+=-Wl,--sort-common +#.endif + +#$(PROG): $(OBJS) +# sh ../util/newvers.sh +# $(DIETCC) $(CC) $(LDFLAGS) -o $(PROG) $(OBJS) $(LIBS) $(EXT_LIBS) vers.c + +#test: $(PROG) +# killall -9 testmbbsd || true +# cp mbbsd testmbbsd +# ./testmbbsd 9000 +# rm -f testmbbsd +# +#install: $(PROG) +# install -d $(BBSHOME)/bin/ +# install -c -m 755 $(PROG) $(BBSHOME)/bin/ +# mv -f $(BBSHOME)/bin/mbbsd $(BBSHOME)/bin/mbbsd.`date '+%m%d%H%M'` +# ln -sv $(BBSHOME)/bin/mbbsd.`date '+%m%d%H%M'` $(BBSHOME)/bin/mbbsd diff --git a/mbbsd/Makefile.old b/mbbsd/Makefile.old new file mode 100644 index 00000000..a635cb48 --- /dev/null +++ b/mbbsd/Makefile.old @@ -0,0 +1,63 @@ +# $Id$ + +.include "../pttbbs.mk" + +.if defined(WITH_BLOG) +CFLAGS+= -DBLOG +LDFLAGS+= -L/usr/local/lib/mysql -lmysqlclient +.endif + + +PROG= mbbsd +OBJS= admin.o announce.o args.o assess.o bbs.o board.o cache.o cal.o card.o\ + chat.o chc.o chc_tab.o chicken.o convert.o crypt.o dark.o edit.o fav.o friend.o gamble.o\ + gomo.o guess.o indict.o io.o kaede.o lovepaper.o mail.o mbbsd.o menu.o\ + more.o name.o osdep.o othello.o read.o record.o register.o\ + screen.o stuff.o talk.o term.o topsong.o user.o brc.o vice.o vote.o\ + xyz.o voteboard.o syspost.o var.o passwd.o calendar.o go.o file.o \ + pmore.o chess.o + +.if defined(DIET) +OBJS+= random.o time.o +DIETCC= diet -Os +.endif +#CFLAGS+=-g +#CFLAGS+=-std=c99 + +# reduce .bss align overhead +.if !defined(DEBUG) +LDFLAGS+=-Wl,--sort-common +.endif + +.if defined(MERGEBBS) +CFLAGS+= -DMERGEBBS +OBJS+= merge.o +.endif + +.SUFFIXES: .c .o +.c.o: ../include/var.h + $(CCACHE) $(DIETCC) $(CC) $(CFLAGS) -c $*.c + +all: $(PROG) + +$(PROG): $(OBJS) + sh ../util/newvers.sh + $(DIETCC) $(CC) $(LDFLAGS) -o $(PROG) $(OBJS) $(LIBS) $(EXT_LIBS) vers.c + +../include/var.h: var.c + perl ../util/parsevar.pl < var.c > ../include/var.h + +test: $(PROG) + killall -9 testmbbsd || true + cp mbbsd testmbbsd + ./testmbbsd 9000 + rm -f testmbbsd + +install: $(PROG) + install -d $(BBSHOME)/bin/ + install -c -m 755 $(PROG) $(BBSHOME)/bin/ + mv -f $(BBSHOME)/bin/mbbsd $(BBSHOME)/bin/mbbsd.`date '+%m%d%H%M'` + ln -sv $(BBSHOME)/bin/mbbsd.`date '+%m%d%H%M'` $(BBSHOME)/bin/mbbsd + +clean: + rm -f $(OBJS) $(PROG) -- cgit v1.2.3