2000-03-25 15:38:54 -07:00
|
|
|
## ___________ _________ _____ __
|
|
|
|
## \_ _____/______ ____ ____ \_ ___ \____________ _/ ____\/ |_
|
|
|
|
## | __) \_ __ \_/ __ \_/ __ \/ \ \/\_ __ \__ \\ __\\ __\
|
|
|
|
## | \ | | \/\ ___/\ ___/\ \____| | \// __ \| | | |
|
|
|
|
## \___ / |__| \___ >\___ >\______ /|__| (____ /__| |__|
|
|
|
|
## \/ \/ \/ \/ \/
|
|
|
|
## ______________________ ______________________
|
|
|
|
## T H E W A R B E G I N S
|
|
|
|
## FreeCraft - A free fantasy real time strategy game engine
|
|
|
|
##
|
|
|
|
## Makefile - The make file.
|
|
|
|
##
|
2001-01-16 15:32:22 -07:00
|
|
|
## (c) Copyright 1998-2001 by Lutz Sammer
|
2000-03-25 15:38:54 -07:00
|
|
|
##
|
2001-05-30 08:47:11 -06:00
|
|
|
## FreeCraft is free software; you can redistribute it and/or modify
|
|
|
|
## it under the terms of the GNU General Public License as published
|
|
|
|
## by the Free Software Foundation; either version 2 of the License,
|
|
|
|
## or (at your option) any later version.
|
|
|
|
##
|
|
|
|
## FreeCraft is distributed in the hope that it will be useful,
|
|
|
|
## but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
## GNU General Public License for more details.
|
|
|
|
##
|
2000-03-25 15:38:54 -07:00
|
|
|
## $Id$
|
|
|
|
##
|
|
|
|
|
|
|
|
TOPDIR= .
|
|
|
|
|
|
|
|
include $(TOPDIR)/Rules.make
|
|
|
|
|
|
|
|
MAKE= make TOPDIR=`pwd`
|
|
|
|
MODULES= src tools
|
|
|
|
|
2000-04-03 17:29:06 -06:00
|
|
|
all: src freecraft$(EXE) tools
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
help:
|
|
|
|
@-echo "make cycle clean,depend,tags,all"
|
|
|
|
@-echo "make install install all files"
|
|
|
|
@-echo "make uninstall uninstall all files"
|
|
|
|
@-echo "make run create and run"
|
|
|
|
@-echo "make runp create and run with profiler"
|
|
|
|
@-echo "make clean cleanup keep only executables"
|
|
|
|
@-echo "make clobber clean all files"
|
|
|
|
@-echo "make distclean clean all files"
|
|
|
|
@-echo "make ci check in RS"
|
|
|
|
@-echo "make doc make source documention with doxygen"
|
|
|
|
@-echo "make doc++ make source documention with doc++"
|
|
|
|
@-echo "make lockver NAME="version" label current version with symbolic name"
|
|
|
|
@-echo "make tags create ctags"
|
|
|
|
@-echo "make depend create dependencies"
|
|
|
|
@-echo "make dist create distribution"
|
|
|
|
@-echo "make small-dist create small distribution"
|
|
|
|
@-echo "make buildit create data files from original data"
|
|
|
|
@-echo "make buildclean cleanup build data files"
|
|
|
|
@-echo "make win32new start new win32"
|
|
|
|
@-echo "make win32 build the win32 version"
|
|
|
|
@-echo "make win32distclean clean all files of win32"
|
|
|
|
@-echo "make release release it"
|
|
|
|
|
|
|
|
cycle::
|
|
|
|
@$(MAKE) clean
|
|
|
|
@$(MAKE) depend
|
|
|
|
@$(MAKE) tags
|
|
|
|
@$(MAKE) all
|
|
|
|
|
|
|
|
run::
|
2000-04-03 17:29:06 -06:00
|
|
|
@$(MAKE) && ./freecraft
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
runp::
|
2000-04-03 17:29:06 -06:00
|
|
|
@$(MAKE) && ./freecraft && if [ -e gmon.sum ]; then \
|
|
|
|
gprof -s freecraft gmon.out gmon.sum; \
|
2000-03-25 15:38:54 -07:00
|
|
|
else mv gmon.out gmon.sum; fi
|
|
|
|
|
|
|
|
doc::
|
2001-03-13 09:44:22 -07:00
|
|
|
doxygen contrib/doxygen-freecraft.cfg
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
doc++::
|
|
|
|
@$(MAKE) -C src doc
|
|
|
|
@if [ ! -d srcdoc ]; then mkdir srcdoc; fi
|
|
|
|
@$(DOCPP) -v -H -A -a -b -c -j -d srcdoc `find . -name "*.doc" -print`
|
|
|
|
|
|
|
|
src::
|
|
|
|
@$(MAKE) -C src all
|
|
|
|
|
|
|
|
etlib/hash.o: etlib/hash.c
|
|
|
|
etlib/getopt.o: etlib/getopt.c
|
|
|
|
etlib/prgname.o: etlib/prgname.c
|
|
|
|
|
|
|
|
# UNIX-TARGET
|
2001-03-13 09:44:22 -07:00
|
|
|
freecraft: src etlib/hash.o src/libclone.a
|
2000-08-13 08:51:22 -06:00
|
|
|
$(CC) -o freecraft src/libclone.a $(CLONELIBS) -I. $(CFLAGS)
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
# WIN32-TARGET
|
2000-06-26 16:44:13 -06:00
|
|
|
freecraft.exe: src etlib/prgname.o etlib/getopt.o etlib/hash.o \
|
2001-03-13 09:44:22 -07:00
|
|
|
src/freecraftrc.o src/libclone.a
|
2000-06-26 16:44:13 -06:00
|
|
|
$(CC) -o freecraft$(EXE) src/main.c src/libclone.a src/freecraftrc.o \
|
|
|
|
-lSDLmain $(CLONELIBS) -I. $(CFLAGS)
|
2000-03-25 15:38:54 -07:00
|
|
|
|
2000-06-26 16:44:13 -06:00
|
|
|
src/freecraftrc.o: src/freecraft.rc
|
|
|
|
windres --include-dir contrib -osrc/freecraftrc.o src/freecraft.rc
|
|
|
|
|
2001-03-13 09:44:22 -07:00
|
|
|
# -L. -lefence
|
|
|
|
# -Lccmalloc-0.2.3/src -lccmalloc -ldl
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
tools::
|
|
|
|
@$(MAKE) -C tools all
|
|
|
|
|
|
|
|
clean::
|
|
|
|
@set -e; for i in $(MODULES) ; do $(MAKE) -C $$i clean ; done
|
2001-04-16 12:32:02 -06:00
|
|
|
$(RM) core gmon.out cscope.out *.doc etlib/*.o .#*
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
clobber: clean
|
|
|
|
@set -e; for i in $(MODULES) ; do $(MAKE) -C $$i clobber ; done
|
2001-04-18 08:33:24 -06:00
|
|
|
$(RM) freecraft$(EXE) gmon.sum *~
|
2000-03-25 15:38:54 -07:00
|
|
|
$(RM) -r srcdoc/*
|
|
|
|
@$(MAKE) -C tools clobber
|
|
|
|
|
|
|
|
distclean: clobber
|
|
|
|
@echo
|
|
|
|
|
|
|
|
ci::
|
|
|
|
@set -e; for i in $(MODULES) ; do $(MAKE) -C $$i ci ; done
|
|
|
|
ci -l Makefile Common.mk Rules.make .indent.pro \
|
2001-03-13 09:44:22 -07:00
|
|
|
contrib/doxygen-freecraft.cfg \
|
2000-03-25 15:38:54 -07:00
|
|
|
$(CCLS) $(DOCS)
|
|
|
|
|
|
|
|
lockver::
|
|
|
|
@set -e; for i in $(MODULES) ; do $(MAKE) -C $$i lockver ; done
|
|
|
|
$(LOCKVER) Makefile Common.mk Rules.make .indent.pro \
|
2001-03-13 09:44:22 -07:00
|
|
|
contrib/doxygen-freecraft.cfg \
|
2000-03-25 15:38:54 -07:00
|
|
|
$(CCLS) $(DOCS)
|
|
|
|
|
|
|
|
tags::
|
|
|
|
@$(MAKE) -C src tags
|
|
|
|
|
|
|
|
depend::
|
|
|
|
@$(MAKE) -C src depend
|
|
|
|
|
|
|
|
##############################################################################
|
|
|
|
# Distributions
|
|
|
|
##############################################################################
|
|
|
|
|
2000-08-13 08:51:22 -06:00
|
|
|
DOCS = README README.BeOS doc/readme.html doc/install.html \
|
2001-03-30 07:08:15 -07:00
|
|
|
doc/freecraft.html doc/datadir.html \
|
2000-04-03 17:29:06 -06:00
|
|
|
doc/faq.html doc/ChangeLog.html doc/todo.html doc/freecraft.lsm \
|
2001-05-30 08:47:11 -06:00
|
|
|
doc/development.html doc/gpl.txt doc/gpl.html doc/SIOD.txt \
|
|
|
|
doc/ccl/ccl.html doc/ccl/tileset.html \
|
2001-03-23 10:28:03 -07:00
|
|
|
doc/ccl/icon.html doc/ccl/unittype.html doc/graphic/*.html \
|
|
|
|
doc/graphic/*.png
|
2000-03-25 15:38:54 -07:00
|
|
|
|
2000-06-26 16:44:13 -06:00
|
|
|
PICS = contrib/freecraft.png contrib/freecraft.ico
|
2000-03-25 15:38:54 -07:00
|
|
|
|
2001-04-14 09:07:52 -06:00
|
|
|
CCLS = data/ccl/units.ccl data/ccl/human/units.ccl data/ccl/orc/units.ccl \
|
2001-06-16 16:55:49 -06:00
|
|
|
data/ccl/constructions.ccl data/ccl/human/constructions.ccl \
|
|
|
|
data/ccl/orc/constructions.ccl \
|
2001-04-14 09:07:52 -06:00
|
|
|
data/ccl/missiles.ccl data/ccl/icons.ccl \
|
2001-06-16 16:55:49 -06:00
|
|
|
data/ccl/sound.ccl data/ccl/freecraft.ccl \
|
2001-03-27 12:31:23 -07:00
|
|
|
data/ccl/ui.ccl data/ccl/human/ui.ccl data/ccl/orc/ui.ccl \
|
2001-06-16 16:55:49 -06:00
|
|
|
data/ccl/upgrade.ccl data/ccl/human/upgrade.ccl \
|
|
|
|
data/ccl/orc/upgrade.ccl \
|
2001-03-25 08:35:26 -07:00
|
|
|
data/ccl/buttons.ccl data/ccl/human/buttons.ccl \
|
2001-06-16 16:55:49 -06:00
|
|
|
data/ccl/orc/buttons.ccl \
|
|
|
|
data/ccl/fonts.ccl data/ccl/ai.ccl \
|
2001-06-22 21:04:37 -06:00
|
|
|
data/ccl/tilesets.ccl data/ccl/tilesets/summer.ccl \
|
|
|
|
data/ccl/tilesets/winter.ccl \
|
|
|
|
data/ccl/tilesets/wasteland.ccl data/ccl/tilesets/swamp.ccl \
|
2001-06-16 16:55:49 -06:00
|
|
|
data/ccl/anim.ccl data/ccl/wc2.ccl data/default.cm
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
CONTRIB = contrib/cross.png contrib/health.png contrib/mana.png \
|
2001-06-25 08:17:18 -06:00
|
|
|
contrib/health2.png contrib/mana2.png \
|
2000-03-26 08:25:42 -07:00
|
|
|
contrib/ore,stone,coal.png contrib/food.png contrib/score.png
|
2000-03-25 15:38:54 -07:00
|
|
|
|
2001-03-13 09:44:22 -07:00
|
|
|
MISC = Makefile Common.mk Rules.make.orig FreeCraft-beos.proj setup \
|
|
|
|
contrib/doxygen-freecraft.cfg contrib/doxygen-header.html \
|
2000-03-25 15:38:54 -07:00
|
|
|
.indent.pro make/common.scc make/rules.scc make/makefile.scc \
|
2001-06-10 11:04:23 -06:00
|
|
|
make/README tools/udta.c tools/ugrd.c $(CONTRIB) \
|
2000-06-26 16:44:13 -06:00
|
|
|
etlib/hash.c etlib/getopt.c etlib/prgname.c etlib/prgname.h
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
mydate = $(shell date +%y%m%d)
|
2000-04-03 17:29:06 -06:00
|
|
|
distdir = freecraft-$(mydate)
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
dist::
|
|
|
|
$(RM) $(DISTLIST)
|
|
|
|
@set -e; for i in $(MODULES); do $(MAKE) -C $$i distlist ; done
|
|
|
|
echo >>$(DISTLIST)
|
|
|
|
echo $(PICS) >>$(DISTLIST)
|
|
|
|
echo $(MISC) >>$(DISTLIST)
|
|
|
|
echo $(CCLS) >>$(DISTLIST)
|
|
|
|
echo $(DOCS) >>$(DISTLIST)
|
|
|
|
rm -rf $(distdir)
|
|
|
|
mkdir $(distdir)
|
|
|
|
chmod 777 $(distdir)
|
2001-03-13 09:44:22 -07:00
|
|
|
for i in `cat $(DISTLIST)`; do echo $$i; done | cpio -pdml --quiet $(distdir)
|
2001-06-25 08:17:18 -06:00
|
|
|
chown -R johns:freecraft $(distdir)
|
2001-06-16 16:55:49 -06:00
|
|
|
chmod -R a+rX $(distdir)
|
2000-03-25 15:38:54 -07:00
|
|
|
tar chzf $(distdir).tar.gz $(distdir)
|
2001-01-16 15:32:22 -07:00
|
|
|
tar cjhf $(distdir).tar.bz2 $(distdir)
|
|
|
|
echo "(c) 2001 by the FreeCraft Project http://FreeCraft.Org" | \
|
2000-06-26 16:44:13 -06:00
|
|
|
zip -zq9r $(distdir).zip $(distdir)
|
2000-03-25 15:38:54 -07:00
|
|
|
$(RM) $(DISTLIST)
|
|
|
|
$(RM) -r $(distdir)
|
|
|
|
du -h $(distdir).tar.gz $(distdir).tar.bz2 $(distdir).zip
|
|
|
|
|
|
|
|
small-dist::
|
|
|
|
@$(RM) $(DISTLIST)
|
|
|
|
$(MAKE) -C src distlist
|
|
|
|
$(MAKE) -C tools distlist
|
|
|
|
echo $(MISC) >>$(DISTLIST)
|
|
|
|
echo $(CCLS) >>$(DISTLIST)
|
|
|
|
echo $(DOCS) >>$(DISTLIST)
|
|
|
|
rm -rf $(distdir)
|
|
|
|
mkdir $(distdir)
|
|
|
|
chmod 777 $(distdir)
|
2001-03-13 09:44:22 -07:00
|
|
|
for i in `cat $(DISTLIST)`; do echo $$i; done | cpio -pdml --quiet $(distdir)
|
2001-06-25 08:17:18 -06:00
|
|
|
chown -R johns:freecraft $(distdir)
|
2001-06-16 16:55:49 -06:00
|
|
|
chmod -R a+rX $(distdir)
|
2000-03-25 15:38:54 -07:00
|
|
|
tar chzf $(distdir)-small.tar.gz $(distdir)
|
2001-01-16 15:32:22 -07:00
|
|
|
tar cjhf $(distdir)-small.tar.bz2 $(distdir)
|
|
|
|
echo "(c) 2001 by the FreeCraft Project http://FreeCraft.Org" | \
|
2000-06-26 16:44:13 -06:00
|
|
|
zip -zq9r $(distdir)-small.zip $(distdir)
|
2000-03-25 15:38:54 -07:00
|
|
|
$(RM) $(DISTLIST)
|
|
|
|
$(RM) -r $(distdir)
|
|
|
|
du -h $(distdir)-small.tar.gz $(distdir)-small.tar.bz2 $(distdir)-small.zip
|
|
|
|
|
|
|
|
bin-dist:: all
|
|
|
|
$(RM) $(DISTLIST)
|
|
|
|
echo $(PICS) >>$(DISTLIST)
|
|
|
|
echo $(CONTRIB) >>$(DISTLIST)
|
|
|
|
echo $(CCLS) >>$(DISTLIST)
|
|
|
|
echo $(DOCS) >>$(DISTLIST)
|
2000-04-03 17:29:06 -06:00
|
|
|
echo freecraft$(EXE) >>$(DISTLIST)
|
2000-03-25 15:38:54 -07:00
|
|
|
echo tools/wartool$(EXE) >>$(DISTLIST)
|
|
|
|
echo tools/build.sh >>$(DISTLIST)
|
|
|
|
rm -rf $(distdir)
|
|
|
|
mkdir $(distdir)
|
|
|
|
chmod 777 $(distdir)
|
2001-03-13 09:44:22 -07:00
|
|
|
for i in `cat $(DISTLIST)`; do echo $$i; done | cpio -pdml --quiet $(distdir)
|
2001-06-25 08:17:18 -06:00
|
|
|
chown -R johns:freecraft $(distdir)
|
2001-06-16 16:55:49 -06:00
|
|
|
chmod -R a+rX $(distdir)
|
2000-04-03 17:29:06 -06:00
|
|
|
strip -s -R .comment $(distdir)/freecraft$(EXE)
|
2000-03-25 15:38:54 -07:00
|
|
|
strip -s -R .comment $(distdir)/tools/wartool$(EXE)
|
2000-04-03 17:29:06 -06:00
|
|
|
tar chzf freecraft-$(mydate)-bin.tar.gz $(distdir)
|
2001-01-16 15:32:22 -07:00
|
|
|
tar cjhf freecraft-$(mydate)-bin.tar.bz2 $(distdir)
|
2000-03-25 15:38:54 -07:00
|
|
|
$(RM) $(DISTLIST)
|
|
|
|
$(RM) -r $(distdir)
|
|
|
|
|
2000-07-12 17:19:13 -06:00
|
|
|
#----------------------------------------------------------------------------
|
|
|
|
|
2000-03-25 15:38:54 -07:00
|
|
|
win32-bin-dist2:: win32
|
|
|
|
@$(RM) $(DISTLIST)
|
|
|
|
@echo $(PICS) >>$(DISTLIST)
|
|
|
|
@echo $(CONTRIB) >>$(DISTLIST)
|
|
|
|
@echo $(CCLS) >>$(DISTLIST)
|
|
|
|
@echo $(DOCS) >>$(DISTLIST)
|
2001-05-30 08:47:11 -06:00
|
|
|
@echo SDL.dll doc/README-SDL.txt doc/ZIP-LICENSE >>$(DISTLIST)
|
2000-04-03 17:29:06 -06:00
|
|
|
@echo freecraft$(EXE) >>$(DISTLIST)
|
2000-03-25 15:38:54 -07:00
|
|
|
@echo tools/wartool$(EXE) >>$(DISTLIST)
|
|
|
|
@echo tools/build.bat >>$(DISTLIST)
|
|
|
|
@rm -rf $(distdir)
|
|
|
|
@mkdir $(distdir)
|
|
|
|
@chmod 777 $(distdir)
|
2001-03-13 09:44:22 -07:00
|
|
|
@for i in `cat $(DISTLIST)`; do echo $$i; done | cpio -pdml --quiet $(distdir)
|
2000-06-26 16:44:13 -06:00
|
|
|
@cp tools/build.bat $(distdir)
|
2001-06-25 08:17:18 -06:00
|
|
|
chown -R johns:freecraft $(distdir)
|
2001-06-16 16:55:49 -06:00
|
|
|
@chmod -R a+rX $(distdir)
|
2000-04-03 17:29:06 -06:00
|
|
|
@strip -s -R .comment $(distdir)/freecraft$(EXE)
|
2000-03-25 15:38:54 -07:00
|
|
|
@strip -s -R .comment $(distdir)/tools/wartool$(EXE)
|
2001-01-16 15:32:22 -07:00
|
|
|
@echo "(c) 2001 by the FreeCraft Project http://FreeCraft.Org" | \
|
2000-06-26 16:44:13 -06:00
|
|
|
zip -zq9r freecraft-$(mydate)-win32bin.zip $(distdir)
|
2000-03-25 15:38:54 -07:00
|
|
|
@$(RM) $(DISTLIST)
|
|
|
|
@$(RM) -r $(distdir)
|
2000-04-03 17:29:06 -06:00
|
|
|
du -h freecraft-$(mydate)-win32bin.zip
|
2000-03-25 15:38:54 -07:00
|
|
|
|
2000-06-26 16:44:13 -06:00
|
|
|
win32-bin-dist: win32
|
2000-08-13 08:51:22 -06:00
|
|
|
@export PATH=/usr/local/cross-tools/i386-mingw32msvc/bin:$$PATH; \
|
2000-06-26 16:44:13 -06:00
|
|
|
$(MAKE) $(WIN32) win32-bin-dist2
|
|
|
|
|
|
|
|
win32-exe-dist: win32-bin-dist
|
|
|
|
cat tools/SFXWiz32-gcc.exe freecraft-$(mydate)-win32bin.zip \
|
|
|
|
> freecraft-$(mydate)-win32bin.exe
|
2000-03-25 15:38:54 -07:00
|
|
|
|
2000-07-12 17:19:13 -06:00
|
|
|
#----------------------------------------------------------------------------
|
|
|
|
|
2000-08-13 08:51:22 -06:00
|
|
|
MYDATE = $(shell date +%y%m%d)
|
|
|
|
PCRAFT= freecraft-$(MYDATE).tar.bz2
|
|
|
|
LCRAFT= freecraft-$(MYDATE)-bin.tar.bz2
|
|
|
|
WCRAFT= freecraft-$(MYDATE)-win32bin.zip
|
2001-04-14 09:07:52 -06:00
|
|
|
FCRAFT= ../fcraft-0.15.tar.gz
|
2001-03-08 16:45:30 -07:00
|
|
|
SCRAFT= ../scraft-0.02.tar.bz2
|
2000-07-12 17:19:13 -06:00
|
|
|
|
|
|
|
linux-complete:
|
|
|
|
tar xzf $(FCRAFT)
|
2000-08-13 08:51:22 -06:00
|
|
|
rm -rf fcraft/freecraft fcraft/data/cvs_ccl
|
2001-01-16 15:32:22 -07:00
|
|
|
tar xjf $(SCRAFT)
|
|
|
|
tar xjf $(PCRAFT)
|
|
|
|
tar xjf $(LCRAFT)
|
2000-08-13 08:51:22 -06:00
|
|
|
mkdir freecraft-complete
|
|
|
|
cp -a freecraft-$(MYDATE)/* freecraft-complete
|
2001-06-16 16:55:49 -06:00
|
|
|
mv freecraft-complete/data freecraft-complete/data.wc2
|
2000-08-13 08:51:22 -06:00
|
|
|
cp -a fcraft/* freecraft-complete
|
|
|
|
cp -a fclone/* freecraft-complete
|
|
|
|
rm -rf freecraft-$(MYDATE)
|
2000-07-12 17:19:13 -06:00
|
|
|
rm -rf fcraft
|
|
|
|
rm -rf fclone
|
2001-05-02 16:43:35 -06:00
|
|
|
chmod 777 freecraft-complete
|
2001-06-25 08:17:18 -06:00
|
|
|
chown -R johns:freecraft $(distdir)
|
2001-05-02 16:43:35 -06:00
|
|
|
chmod -R a+rX freecraft-complete
|
2001-02-19 09:56:17 -07:00
|
|
|
-tar czhf freecraft-$(MYDATE)-complete-linux.tar.gz freecraft-complete
|
|
|
|
-tar cjhf freecraft-$(MYDATE)-complete-linux.tar.bz2 freecraft-complete
|
2000-08-13 08:51:22 -06:00
|
|
|
rm -rf freecraft-complete
|
2000-07-12 17:19:13 -06:00
|
|
|
|
|
|
|
win32-complete:
|
|
|
|
tar xzf $(FCRAFT)
|
2000-08-13 08:51:22 -06:00
|
|
|
rm -rf fcraft/freecraft fcraft/data/cvs_ccl
|
2001-01-16 15:32:22 -07:00
|
|
|
tar xjf $(SCRAFT)
|
|
|
|
tar xjf $(PCRAFT)
|
2000-07-12 17:19:13 -06:00
|
|
|
unzip -oq $(WCRAFT)
|
2000-08-13 08:51:22 -06:00
|
|
|
mkdir freecraft-complete
|
|
|
|
cp -a freecraft-$(MYDATE)/* freecraft-complete
|
2001-06-16 16:55:49 -06:00
|
|
|
mv freecraft-complete/data freecraft-complete/data.wc2
|
2000-08-13 08:51:22 -06:00
|
|
|
cp -a fcraft/* freecraft-complete
|
|
|
|
cp -a fclone/* freecraft-complete
|
|
|
|
rm -rf freecraft-$(MYDATE)
|
2000-07-12 17:19:13 -06:00
|
|
|
rm -rf fcraft
|
|
|
|
rm -rf fclone
|
2001-05-02 16:43:35 -06:00
|
|
|
chmod 777 freecraft-complete
|
2001-06-25 08:17:18 -06:00
|
|
|
chown -R johns:freecraft $(distdir)
|
2001-05-02 16:43:35 -06:00
|
|
|
chmod -R a+rX freecraft-complete
|
2001-01-16 15:32:22 -07:00
|
|
|
echo "(c) 2001 by the FreeCraft Project http://FreeCraft.Org" | \
|
2000-08-13 08:51:22 -06:00
|
|
|
zip -zq9r freecraft-$(MYDATE)-complete-win32.zip freecraft-complete
|
|
|
|
cat tools/SFXWiz32-gcc.exe freecraft-$(MYDATE)-complete-win32.zip \
|
|
|
|
> freecraft-$(MYDATE)-complete-win32.exe
|
|
|
|
rm -rf freecraft-complete
|
|
|
|
|
|
|
|
complete: linux-complete win32-complete
|
2000-07-12 17:19:13 -06:00
|
|
|
|
|
|
|
#----------------------------------------------------------------------------
|
2000-04-03 17:29:06 -06:00
|
|
|
difffile= freecraft-`date +%y%m%d`.diff
|
2001-03-13 09:44:22 -07:00
|
|
|
diff:
|
2000-03-25 15:38:54 -07:00
|
|
|
@$(RM) $(difffile)
|
|
|
|
@$(RM) $(DISTLIST)
|
|
|
|
$(MAKE) -C src distlist
|
|
|
|
$(MAKE) -C tools distlist
|
|
|
|
echo $(MISC) >>$(DISTLIST)
|
|
|
|
echo $(CCLS) >>$(DISTLIST)
|
|
|
|
echo $(DOCS) >>$(DISTLIST)
|
|
|
|
rcsdiff -u `cat $(DISTLIST)` > $(difffile)
|
|
|
|
|
|
|
|
buildit: tools
|
|
|
|
. tools/build.sh
|
|
|
|
|
|
|
|
buildclean:
|
2000-04-03 17:29:06 -06:00
|
|
|
rm -rf data/*.rgb data/*.gimp data/puds data/sound data/graphic \
|
|
|
|
data/interface data/campaigns data/text data/health.png data/mana.png \
|
2000-04-15 19:34:54 -06:00
|
|
|
data/default.pud.gz data/freecraft.png
|
2000-06-10 09:36:28 -06:00
|
|
|
rm -rf data/graphics data/sounds data/texts
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
release:
|
2000-06-26 16:44:13 -06:00
|
|
|
$(MAKE) distclean
|
|
|
|
$(MAKE) depend
|
|
|
|
$(MAKE) bin-dist "ZDEFS=-DUSE_ZLIB -DUSE_BZ2LIB" "ZLIBS=-lz -lbz2"
|
|
|
|
$(MAKE) win32new
|
|
|
|
$(MAKE) win32-bin-dist
|
2000-07-12 17:19:13 -06:00
|
|
|
$(MAKE) win32-exe-dist
|
2000-06-26 16:44:13 -06:00
|
|
|
$(MAKE) win32distclean
|
2000-07-12 17:19:13 -06:00
|
|
|
$(MAKE) dist
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
##############################################################################
|
|
|
|
# WIN32 Crosscompiler Build
|
|
|
|
##############################################################################
|
|
|
|
|
2001-04-30 04:57:50 -06:00
|
|
|
#-lws2_32 -Wl,--stack,63550000 -Wl,--stack,16777216
|
2000-03-25 15:38:54 -07:00
|
|
|
WIN32= \
|
|
|
|
EXE='.exe' \
|
2001-04-30 04:57:50 -06:00
|
|
|
ZDEFS='-DUSE_ZLIB' \
|
|
|
|
ZLIBS='-lz' \
|
2000-03-25 15:38:54 -07:00
|
|
|
VIDEO='-DUSE_WIN32 $(SDL)' \
|
2001-06-16 16:55:49 -06:00
|
|
|
VIDEOLIB='-L/usr/local/cross-tools/i386-mingw32msvc/lib $(SDLLIB) -lwsock32 -lws2_32'
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
win32new:
|
2000-06-26 16:44:13 -06:00
|
|
|
@$(MAKE) distclean
|
2000-08-13 08:51:22 -06:00
|
|
|
export PATH=/usr/local/cross-tools/i386-mingw32msvc/bin:$$PATH; \
|
2000-06-26 16:44:13 -06:00
|
|
|
$(MAKE) $(WIN32) depend
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
win32_2:
|
2000-06-26 16:44:13 -06:00
|
|
|
$(MAKE) $(WIN32) all
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
win32:
|
2000-08-13 08:51:22 -06:00
|
|
|
export PATH=/usr/local/cross-tools/i386-mingw32msvc/bin:$$PATH; \
|
2000-06-26 16:44:13 -06:00
|
|
|
$(MAKE) win32_2
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
win32distclean:
|
2000-08-13 08:51:22 -06:00
|
|
|
export PATH=/usr/local/cross-tools/i386-mingw32msvc/bin:$$PATH; \
|
2000-06-26 16:44:13 -06:00
|
|
|
$(MAKE) $(WIN32) distclean
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
##############################################################################
|
2001-03-13 09:44:22 -07:00
|
|
|
# INSTALL/UNINSTALL
|
2000-03-25 15:38:54 -07:00
|
|
|
##############################################################################
|
|
|
|
|
|
|
|
install: all
|
2000-04-03 17:29:06 -06:00
|
|
|
install -m 755 freecraft $(DESTDIR)/usr/games/freecraft
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
install-tools: all
|
2000-04-03 17:29:06 -06:00
|
|
|
install -m 755 tools/wartool $(DESTDIR)/usr/lib/freecraft/tools/
|
|
|
|
install -m 755 tools/build.sh $(DESTDIR)/usr/lib/freecraft/tools/
|
2000-03-25 15:38:54 -07:00
|
|
|
|
|
|
|
uninstall:
|
|
|
|
@echo "under construction: make it by hand :)"
|