Replace the build process. The new one requires GNU Make, Autoconf
and Autoconf macros that come with Automake. It supports multiple separate builds of the same source tree, and updates dependencies automatically. Targets info, html, install, install-html, uninstall and dist are not yet implemented. System configuration is now automatic. Previously, you had to choose one of several canned system configurations, defined in Make.sysdefs. Currently, system configuration always uses UCONTEXT for LWP, and chooses LWP only if its requirements are met. Feature configuration changed: instead of editing build.conf (further processed by doconfig), you pass arguments to configure. Note that build.conf settings that can be overridden in econfig have no configure equivalent; just edit econfig instead. Because generated headers complicate makefiles, fold gamesdef.h into its users: path.c and ipglob.c become path.c.in and ipglob.c.in, constants.c, vers.c, options.h simply hardcode defaults (most of them are run-time configurable). Call the client empire instead of emp_client. This matches what the old standalone build did.
This commit is contained in:
parent
cdfb94dc1f
commit
a98626df2d
67 changed files with 5052 additions and 2642 deletions
11
.cvsignore
11
.cvsignore
|
@ -1,5 +1,16 @@
|
||||||
|
GNUmakefile
|
||||||
|
aclocal.m4
|
||||||
|
autom4te.cache
|
||||||
bin
|
bin
|
||||||
|
config.h
|
||||||
|
config.h.in
|
||||||
|
config.log
|
||||||
|
config.status
|
||||||
|
configure
|
||||||
data
|
data
|
||||||
info.html
|
info.html
|
||||||
info.nr
|
info.nr
|
||||||
lib
|
lib
|
||||||
|
sources.mk
|
||||||
|
stamp-h
|
||||||
|
stamp-h.in
|
||||||
|
|
90
GNUmakefile.in
Normal file
90
GNUmakefile.in
Normal file
|
@ -0,0 +1,90 @@
|
||||||
|
#
|
||||||
|
# Empire - A multi-player, client/server Internet based war game.
|
||||||
|
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
||||||
|
# Ken Stevens, Steve McClure
|
||||||
|
#
|
||||||
|
# This program 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.
|
||||||
|
#
|
||||||
|
# This program 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.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License
|
||||||
|
# along with this program; if not, write to the Free Software
|
||||||
|
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
|
#
|
||||||
|
# ---
|
||||||
|
#
|
||||||
|
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
||||||
|
# related information and legal notices. It is expected that any future
|
||||||
|
# projects/authors will amend these files as needed.
|
||||||
|
#
|
||||||
|
# ---
|
||||||
|
#
|
||||||
|
# @configure_input@
|
||||||
|
# GNUmakefile.in: Makefile template for configure
|
||||||
|
#
|
||||||
|
# Known contributors to this file:
|
||||||
|
# Markus Armbruster, 2005
|
||||||
|
#
|
||||||
|
|
||||||
|
# The real meat is in Make.mk, which see.
|
||||||
|
|
||||||
|
CC := @CC@
|
||||||
|
have_gcc := @GCC@
|
||||||
|
CFLAGS := @CFLAGS@
|
||||||
|
CPPFLAGS := @CPPFLAGS@ @DEFS@
|
||||||
|
LDFLAGS := @LDFLAGS@
|
||||||
|
LIBOBJS := @LIBOBJS@
|
||||||
|
LDLIBS := @LIBS@
|
||||||
|
empthread := @empthread@
|
||||||
|
ifeq ($(empthread),POSIX)
|
||||||
|
CC := @PTHREAD_CC@
|
||||||
|
CFLAGS := $(CFLAGS) @PTHREAD_CFLAGS@ -D_EMPTH_POSIX=1
|
||||||
|
LDFLAGS := $(LDFLAGS) @PTHREAD_CFLAGS@
|
||||||
|
LDLIBS := @PTHREAD_LIBS@ $(LDLIBS)
|
||||||
|
endif
|
||||||
|
ifeq ($(empthread),LWP)
|
||||||
|
# TODO use config.h
|
||||||
|
CPPFLAGS += -DUCONTEXT
|
||||||
|
endif
|
||||||
|
termlibs := @termlibs@
|
||||||
|
CCDEPMODE := @CCDEPMODE@
|
||||||
|
@am__fastdepCC_TRUE@how_to_dep := fast
|
||||||
|
@am__fastdepCC_FALSE@@AMDEP_TRUE@how_to_dep := depcomp
|
||||||
|
|
||||||
|
AWK := @AWK@
|
||||||
|
INSTALL := @INSTALL@
|
||||||
|
INSTALL_DATA := @INSTALL_DATA@
|
||||||
|
INSTALL_PROGRAM := @INSTALL_PROGRAM@
|
||||||
|
# TODO autoconf NROFF
|
||||||
|
NROFF := groff -Tascii -P-c -U
|
||||||
|
RANLIB := @RANLIB@
|
||||||
|
|
||||||
|
prefix := @prefix@
|
||||||
|
exec_prefix := @exec_prefix@
|
||||||
|
bindir := @bindir@
|
||||||
|
datadir := @datadir@
|
||||||
|
localstatedir := @localstatedir@
|
||||||
|
mandir := @mandir@
|
||||||
|
sysconfdir := @sysconfdir@
|
||||||
|
|
||||||
|
srcdir := @srcdir@
|
||||||
|
VPATH := @srcdir@
|
||||||
|
|
||||||
|
cvs_controlled := @cvs_controlled@
|
||||||
|
|
||||||
|
# Recursively expanded so that $@ and $< work.
|
||||||
|
subst.in = sed \
|
||||||
|
-e 's?@configure_input\@?$(notdir $@). Generated from $(notdir $<) by GNUmakefile.?g' \
|
||||||
|
-e 's?@econfig\@?$(sysconfdir)/empire/econfig?g' \
|
||||||
|
-e 's?@edatadir\@?$(localstatedir)/empire?g' \
|
||||||
|
-e 's?@einfodir\@?$(datadir)/empire/info.nr?g' \
|
||||||
|
-e 's/@EMPIREHOST\@/@EMPIREHOST@/g' \
|
||||||
|
-e 's/@EMPIREPORT\@/@EMPIREPORT@/g'
|
||||||
|
|
||||||
|
include $(srcdir)/Make.mk
|
236
INSTALL
Normal file
236
INSTALL
Normal file
|
@ -0,0 +1,236 @@
|
||||||
|
Installation Instructions
|
||||||
|
*************************
|
||||||
|
|
||||||
|
Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005 Free
|
||||||
|
Software Foundation, Inc.
|
||||||
|
|
||||||
|
This file is free documentation; the Free Software Foundation gives
|
||||||
|
unlimited permission to copy, distribute and modify it.
|
||||||
|
|
||||||
|
Basic Installation
|
||||||
|
==================
|
||||||
|
|
||||||
|
These are generic installation instructions.
|
||||||
|
|
||||||
|
The `configure' shell script attempts to guess correct values for
|
||||||
|
various system-dependent variables used during compilation. It uses
|
||||||
|
those values to create a `Makefile' in each directory of the package.
|
||||||
|
It may also create one or more `.h' files containing system-dependent
|
||||||
|
definitions. Finally, it creates a shell script `config.status' that
|
||||||
|
you can run in the future to recreate the current configuration, and a
|
||||||
|
file `config.log' containing compiler output (useful mainly for
|
||||||
|
debugging `configure').
|
||||||
|
|
||||||
|
It can also use an optional file (typically called `config.cache'
|
||||||
|
and enabled with `--cache-file=config.cache' or simply `-C') that saves
|
||||||
|
the results of its tests to speed up reconfiguring. (Caching is
|
||||||
|
disabled by default to prevent problems with accidental use of stale
|
||||||
|
cache files.)
|
||||||
|
|
||||||
|
If you need to do unusual things to compile the package, please try
|
||||||
|
to figure out how `configure' could check whether to do them, and mail
|
||||||
|
diffs or instructions to the address given in the `README' so they can
|
||||||
|
be considered for the next release. If you are using the cache, and at
|
||||||
|
some point `config.cache' contains results you don't want to keep, you
|
||||||
|
may remove or edit it.
|
||||||
|
|
||||||
|
The file `configure.ac' (or `configure.in') is used to create
|
||||||
|
`configure' by a program called `autoconf'. You only need
|
||||||
|
`configure.ac' if you want to change it or regenerate `configure' using
|
||||||
|
a newer version of `autoconf'.
|
||||||
|
|
||||||
|
The simplest way to compile this package is:
|
||||||
|
|
||||||
|
1. `cd' to the directory containing the package's source code and type
|
||||||
|
`./configure' to configure the package for your system. If you're
|
||||||
|
using `csh' on an old version of System V, you might need to type
|
||||||
|
`sh ./configure' instead to prevent `csh' from trying to execute
|
||||||
|
`configure' itself.
|
||||||
|
|
||||||
|
Running `configure' takes awhile. While running, it prints some
|
||||||
|
messages telling which features it is checking for.
|
||||||
|
|
||||||
|
2. Type `make' to compile the package.
|
||||||
|
|
||||||
|
3. Optionally, type `make check' to run any self-tests that come with
|
||||||
|
the package.
|
||||||
|
|
||||||
|
4. Type `make install' to install the programs and any data files and
|
||||||
|
documentation.
|
||||||
|
|
||||||
|
5. You can remove the program binaries and object files from the
|
||||||
|
source code directory by typing `make clean'. To also remove the
|
||||||
|
files that `configure' created (so you can compile the package for
|
||||||
|
a different kind of computer), type `make distclean'. There is
|
||||||
|
also a `make maintainer-clean' target, but that is intended mainly
|
||||||
|
for the package's developers. If you use it, you may have to get
|
||||||
|
all sorts of other programs in order to regenerate files that came
|
||||||
|
with the distribution.
|
||||||
|
|
||||||
|
Compilers and Options
|
||||||
|
=====================
|
||||||
|
|
||||||
|
Some systems require unusual options for compilation or linking that the
|
||||||
|
`configure' script does not know about. Run `./configure --help' for
|
||||||
|
details on some of the pertinent environment variables.
|
||||||
|
|
||||||
|
You can give `configure' initial values for configuration parameters
|
||||||
|
by setting variables in the command line or in the environment. Here
|
||||||
|
is an example:
|
||||||
|
|
||||||
|
./configure CC=c89 CFLAGS=-O2 LIBS=-lposix
|
||||||
|
|
||||||
|
*Note Defining Variables::, for more details.
|
||||||
|
|
||||||
|
Compiling For Multiple Architectures
|
||||||
|
====================================
|
||||||
|
|
||||||
|
You can compile the package for more than one kind of computer at the
|
||||||
|
same time, by placing the object files for each architecture in their
|
||||||
|
own directory. To do this, you must use a version of `make' that
|
||||||
|
supports the `VPATH' variable, such as GNU `make'. `cd' to the
|
||||||
|
directory where you want the object files and executables to go and run
|
||||||
|
the `configure' script. `configure' automatically checks for the
|
||||||
|
source code in the directory that `configure' is in and in `..'.
|
||||||
|
|
||||||
|
If you have to use a `make' that does not support the `VPATH'
|
||||||
|
variable, you have to compile the package for one architecture at a
|
||||||
|
time in the source code directory. After you have installed the
|
||||||
|
package for one architecture, use `make distclean' before reconfiguring
|
||||||
|
for another architecture.
|
||||||
|
|
||||||
|
Installation Names
|
||||||
|
==================
|
||||||
|
|
||||||
|
By default, `make install' will install the package's files in
|
||||||
|
`/usr/local/bin', `/usr/local/man', etc. You can specify an
|
||||||
|
installation prefix other than `/usr/local' by giving `configure' the
|
||||||
|
option `--prefix=PREFIX'.
|
||||||
|
|
||||||
|
You can specify separate installation prefixes for
|
||||||
|
architecture-specific files and architecture-independent files. If you
|
||||||
|
give `configure' the option `--exec-prefix=PREFIX', the package will
|
||||||
|
use PREFIX as the prefix for installing programs and libraries.
|
||||||
|
Documentation and other data files will still use the regular prefix.
|
||||||
|
|
||||||
|
In addition, if you use an unusual directory layout you can give
|
||||||
|
options like `--bindir=DIR' to specify different values for particular
|
||||||
|
kinds of files. Run `configure --help' for a list of the directories
|
||||||
|
you can set and what kinds of files go in them.
|
||||||
|
|
||||||
|
If the package supports it, you can cause programs to be installed
|
||||||
|
with an extra prefix or suffix on their names by giving `configure' the
|
||||||
|
option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
|
||||||
|
|
||||||
|
Optional Features
|
||||||
|
=================
|
||||||
|
|
||||||
|
Some packages pay attention to `--enable-FEATURE' options to
|
||||||
|
`configure', where FEATURE indicates an optional part of the package.
|
||||||
|
They may also pay attention to `--with-PACKAGE' options, where PACKAGE
|
||||||
|
is something like `gnu-as' or `x' (for the X Window System). The
|
||||||
|
`README' should mention any `--enable-' and `--with-' options that the
|
||||||
|
package recognizes.
|
||||||
|
|
||||||
|
For packages that use the X Window System, `configure' can usually
|
||||||
|
find the X include and library files automatically, but if it doesn't,
|
||||||
|
you can use the `configure' options `--x-includes=DIR' and
|
||||||
|
`--x-libraries=DIR' to specify their locations.
|
||||||
|
|
||||||
|
Specifying the System Type
|
||||||
|
==========================
|
||||||
|
|
||||||
|
There may be some features `configure' cannot figure out automatically,
|
||||||
|
but needs to determine by the type of machine the package will run on.
|
||||||
|
Usually, assuming the package is built to be run on the _same_
|
||||||
|
architectures, `configure' can figure that out, but if it prints a
|
||||||
|
message saying it cannot guess the machine type, give it the
|
||||||
|
`--build=TYPE' option. TYPE can either be a short name for the system
|
||||||
|
type, such as `sun4', or a canonical name which has the form:
|
||||||
|
|
||||||
|
CPU-COMPANY-SYSTEM
|
||||||
|
|
||||||
|
where SYSTEM can have one of these forms:
|
||||||
|
|
||||||
|
OS KERNEL-OS
|
||||||
|
|
||||||
|
See the file `config.sub' for the possible values of each field. If
|
||||||
|
`config.sub' isn't included in this package, then this package doesn't
|
||||||
|
need to know the machine type.
|
||||||
|
|
||||||
|
If you are _building_ compiler tools for cross-compiling, you should
|
||||||
|
use the `--target=TYPE' option to select the type of system they will
|
||||||
|
produce code for.
|
||||||
|
|
||||||
|
If you want to _use_ a cross compiler, that generates code for a
|
||||||
|
platform different from the build platform, you should specify the
|
||||||
|
"host" platform (i.e., that on which the generated programs will
|
||||||
|
eventually be run) with `--host=TYPE'.
|
||||||
|
|
||||||
|
Sharing Defaults
|
||||||
|
================
|
||||||
|
|
||||||
|
If you want to set default values for `configure' scripts to share, you
|
||||||
|
can create a site shell script called `config.site' that gives default
|
||||||
|
values for variables like `CC', `cache_file', and `prefix'.
|
||||||
|
`configure' looks for `PREFIX/share/config.site' if it exists, then
|
||||||
|
`PREFIX/etc/config.site' if it exists. Or, you can set the
|
||||||
|
`CONFIG_SITE' environment variable to the location of the site script.
|
||||||
|
A warning: not all `configure' scripts look for a site script.
|
||||||
|
|
||||||
|
Defining Variables
|
||||||
|
==================
|
||||||
|
|
||||||
|
Variables not defined in a site shell script can be set in the
|
||||||
|
environment passed to `configure'. However, some packages may run
|
||||||
|
configure again during the build, and the customized values of these
|
||||||
|
variables may be lost. In order to avoid this problem, you should set
|
||||||
|
them in the `configure' command line, using `VAR=value'. For example:
|
||||||
|
|
||||||
|
./configure CC=/usr/local2/bin/gcc
|
||||||
|
|
||||||
|
causes the specified `gcc' to be used as the C compiler (unless it is
|
||||||
|
overridden in the site shell script). Here is a another example:
|
||||||
|
|
||||||
|
/bin/bash ./configure CONFIG_SHELL=/bin/bash
|
||||||
|
|
||||||
|
Here the `CONFIG_SHELL=/bin/bash' operand causes subsequent
|
||||||
|
configuration-related scripts to be executed by `/bin/bash'.
|
||||||
|
|
||||||
|
`configure' Invocation
|
||||||
|
======================
|
||||||
|
|
||||||
|
`configure' recognizes the following options to control how it operates.
|
||||||
|
|
||||||
|
`--help'
|
||||||
|
`-h'
|
||||||
|
Print a summary of the options to `configure', and exit.
|
||||||
|
|
||||||
|
`--version'
|
||||||
|
`-V'
|
||||||
|
Print the version of Autoconf used to generate the `configure'
|
||||||
|
script, and exit.
|
||||||
|
|
||||||
|
`--cache-file=FILE'
|
||||||
|
Enable the cache: use and save the results of the tests in FILE,
|
||||||
|
traditionally `config.cache'. FILE defaults to `/dev/null' to
|
||||||
|
disable caching.
|
||||||
|
|
||||||
|
`--config-cache'
|
||||||
|
`-C'
|
||||||
|
Alias for `--cache-file=config.cache'.
|
||||||
|
|
||||||
|
`--quiet'
|
||||||
|
`--silent'
|
||||||
|
`-q'
|
||||||
|
Do not print messages saying which checks are being made. To
|
||||||
|
suppress all normal output, redirect it to `/dev/null' (any error
|
||||||
|
messages will still be shown).
|
||||||
|
|
||||||
|
`--srcdir=DIR'
|
||||||
|
Look for the package's source code in directory DIR. Usually
|
||||||
|
`configure' can determine that directory automatically.
|
||||||
|
|
||||||
|
`configure' also accepts some other, not widely useful, options. Run
|
||||||
|
`configure --help' for more details.
|
||||||
|
|
193
Make.mk
Normal file
193
Make.mk
Normal file
|
@ -0,0 +1,193 @@
|
||||||
|
#
|
||||||
|
# Empire - A multi-player, client/server Internet based war game.
|
||||||
|
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
||||||
|
# Ken Stevens, Steve McClure
|
||||||
|
#
|
||||||
|
# This program 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.
|
||||||
|
#
|
||||||
|
# This program 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.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License
|
||||||
|
# along with this program; if not, write to the Free Software
|
||||||
|
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
|
#
|
||||||
|
# ---
|
||||||
|
#
|
||||||
|
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
||||||
|
# related information and legal notices. It is expected that any future
|
||||||
|
# projects/authors will amend these files as needed.
|
||||||
|
#
|
||||||
|
# ---
|
||||||
|
#
|
||||||
|
# Make.mk:
|
||||||
|
#
|
||||||
|
# Known contributors to this file:
|
||||||
|
# Markus Armbruster, 2005
|
||||||
|
#
|
||||||
|
|
||||||
|
# This makefile was inspired by `Recursive Make Considered Harmful',
|
||||||
|
# Peter Miller, 1997.
|
||||||
|
# http://www.pcug.org.au/~millerp/rmch/recu-make-cons-harm.html
|
||||||
|
|
||||||
|
# Recursively expanded variables are occasionally useful, but can be
|
||||||
|
# slow and tricky. Do not use them gratuitously. If you don't
|
||||||
|
# understand this, always use `:=' rather than `='.
|
||||||
|
|
||||||
|
# Delete target on error. Every Makefile should have this.
|
||||||
|
.DELETE_ON_ERROR:
|
||||||
|
|
||||||
|
# Source files
|
||||||
|
-include sources.mk
|
||||||
|
dirs := $(sort $(dir $(src)))
|
||||||
|
csrc := $(filter %.c, $(src))
|
||||||
|
|
||||||
|
# Generated files
|
||||||
|
mk := sources.mk
|
||||||
|
ac := autom4te.cache config.h config.status config.log stamp-h \
|
||||||
|
$(basename $(filter %.in, $(src)))
|
||||||
|
obj := $(csrc:.c=.o) $(filter %.o, $(ac:.c=.o))
|
||||||
|
# TODO AIX needs lwpInit.o lwpRestore.o lwpSave.o unless UCONTEXT
|
||||||
|
deps := $(obj:.o=.d)
|
||||||
|
libs := $(addprefix lib/, libcommon.a libgen.a libglobal.a)
|
||||||
|
util := $(addprefix src/util/, fairland files pconfig)
|
||||||
|
progs := $(util) src/client/empire src/server/emp_server
|
||||||
|
|
||||||
|
ifeq ($(empthread),POSIX)
|
||||||
|
empth_obj := src/lib/empthread/pthread.o
|
||||||
|
empth_lib :=
|
||||||
|
else
|
||||||
|
empth_obj := src/lib/empthread/lwp.o
|
||||||
|
empth_lib := lib/liblwp.a
|
||||||
|
endif
|
||||||
|
|
||||||
|
# Abbreviations
|
||||||
|
scripts = $(srcdir)/src/scripts
|
||||||
|
clean := $(obj) $(deps) $(libs) $(progs) $(empth_lib)
|
||||||
|
distclean := $(ac)
|
||||||
|
|
||||||
|
# Compiler flags
|
||||||
|
CPPFLAGS += -I$(srcdir)/include -Iinclude
|
||||||
|
ifeq ($(have_gcc),yes)
|
||||||
|
CFLAGS += -fno-common
|
||||||
|
CFLAGS += -Wall -W -Wno-unused -Wpointer-arith -Wstrict-prototypes \
|
||||||
|
-Wmissing-prototypes -Wnested-externs -Wredundant-decls
|
||||||
|
endif
|
||||||
|
LDLIBS += -lm
|
||||||
|
|
||||||
|
### Advertized goals
|
||||||
|
|
||||||
|
.PHONY: all
|
||||||
|
all: $(progs) # FIXME info
|
||||||
|
|
||||||
|
.PHONY: info html
|
||||||
|
info html:
|
||||||
|
false # FIXME
|
||||||
|
|
||||||
|
.PHONY: clean
|
||||||
|
clean:
|
||||||
|
rm -f $(clean)
|
||||||
|
|
||||||
|
.PHONY: distclean
|
||||||
|
distclean: clean
|
||||||
|
rm -rf $(distclean)
|
||||||
|
|
||||||
|
.PHONY: install install-html
|
||||||
|
install: all
|
||||||
|
false # FIXME
|
||||||
|
install-html: html
|
||||||
|
false # FIXME
|
||||||
|
|
||||||
|
.PHONY: uninstall
|
||||||
|
uninstall:
|
||||||
|
false # FIXME
|
||||||
|
|
||||||
|
.PHONY: dist
|
||||||
|
dist:
|
||||||
|
false # FIXME
|
||||||
|
|
||||||
|
|
||||||
|
### Implicit rules
|
||||||
|
|
||||||
|
# Compile with dependencies as side effect, i.e. create %.d in
|
||||||
|
# addition to %.o.
|
||||||
|
ifeq ($(how_to_dep),fast)
|
||||||
|
%.o: %.c
|
||||||
|
$(COMPILE.c) -MT $@ -MMD -MP $(OUTPUT_OPTION) $<
|
||||||
|
endif
|
||||||
|
ifeq ($(how_to_dep),depcomp)
|
||||||
|
%.o: %.c
|
||||||
|
source='$<' object='$@' depfile='$(@:.o=.d)' $(CCDEPMODE) $(depcomp) \
|
||||||
|
$(COMPILE.c) $(OUTPUT_OPTION) $<
|
||||||
|
endif
|
||||||
|
# Cancel the rule to compile %.c straight to %, it interferes with
|
||||||
|
# automatic dependency generation
|
||||||
|
%: %.c
|
||||||
|
|
||||||
|
|
||||||
|
### Explicit rules
|
||||||
|
|
||||||
|
src/server/emp_server: $(filter src/server/% src/lib/as/% src/lib/commands/% src/lib/player/% src/lib/subs/% src/lib/update/%, $(obj)) $(empth_obj) $(libs) $(empth_lib)
|
||||||
|
$(LINK.o) $^ $(LOADLIBES) $(LDLIBS) -o $@
|
||||||
|
|
||||||
|
src/client/empire: $(filter src/client/%, $(obj)) $(termlibs)
|
||||||
|
$(LINK.o) $^ $(LOADLIBES) $(LDLIBS) -o $@
|
||||||
|
|
||||||
|
$(util): $(libs)
|
||||||
|
|
||||||
|
lib/libcommon.a: $(filter src/lib/common/%, $(obj))
|
||||||
|
lib/libgen.a: $(filter src/lib/gen/%, $(obj))
|
||||||
|
lib/libglobal.a: $(filter src/lib/global/%, $(obj))
|
||||||
|
lib/liblwp.a: $(filter src/lib/lwp/%, $(obj))
|
||||||
|
|
||||||
|
$(libs) $(empth_lib): | lib
|
||||||
|
$(AR) rc $@ $?
|
||||||
|
$(RANLIB) $@
|
||||||
|
|
||||||
|
lib:
|
||||||
|
mkdir -p $@
|
||||||
|
|
||||||
|
ifeq ($(cvs_controlled),yes)
|
||||||
|
# Find files and directories under CVS control
|
||||||
|
sources.mk: $(scripts)/cvsfiles.awk $(addprefix $(srcdir)/, $(addsuffix CVS/Entries, $(dirs)))
|
||||||
|
echo 'src := ' `cd $(srcdir) && $(AWK) -f src/scripts/cvsfiles.awk` >$@
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifneq ($(deps),)
|
||||||
|
-include $(deps)
|
||||||
|
endif
|
||||||
|
|
||||||
|
# Automatic remake of configuration
|
||||||
|
# See (autoconf)Automatic Remaking.
|
||||||
|
# This requires sufficiently recent versions of autoconf and automake
|
||||||
|
|
||||||
|
$(srcdir)/configure: configure.ac aclocal.m4
|
||||||
|
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.ac aclocal.m4
|
||||||
|
cd $(srcdir) && autoheader
|
||||||
|
>$@
|
||||||
|
|
||||||
|
$(srcdir)/aclocal.m4: $(filter m4/%.m4, $(src))
|
||||||
|
cd $(srcdir) && aclocal -I m4
|
||||||
|
|
||||||
|
# config.status might not change config.h; use the stamp file.
|
||||||
|
config.h: stamp-h
|
||||||
|
stamp-h: config.h.in config.status
|
||||||
|
./config.status config.h stamp-h
|
||||||
|
|
||||||
|
GNUmakefile: GNUmakefile.in config.status
|
||||||
|
./config.status $@
|
||||||
|
|
||||||
|
config.status: configure
|
||||||
|
./config.status --recheck
|
||||||
|
|
||||||
|
src/lib/global/path.c src/client/ipglob.c: %: %.in GNUmakefile
|
||||||
|
$(subst.in) <$< >$@
|
145
Make.sysdefs
145
Make.sysdefs
|
@ -1,145 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
#
|
|
||||||
# Make.sysdefs - Wolfpack, 1996-2000
|
|
||||||
#
|
|
||||||
# To add a new architecture, just copy one of the models below. Change the
|
|
||||||
# CFLAGS as needed, and then put in a target build in the Makefile. See
|
|
||||||
# the examples there on what to do.
|
|
||||||
#
|
|
||||||
|
|
||||||
# Warning flags appropriate for gcc, unless system headers are severly broken
|
|
||||||
GCCWARNFLAGS = -Wall -W -Wno-unused -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Wredundant-decls
|
|
||||||
|
|
||||||
OSXCFLAGS = -g -fno-common -ansi -D_EMPTH_POSIX=1 $(GCCWARNFLAGS)
|
|
||||||
# -O fails on Darwin 5.5, works on 6.6
|
|
||||||
OSXLFLAGS = -flat_namespace -lcurses
|
|
||||||
OSXMASTER = GLOBALCFLAGS="$(OSXCFLAGS)" GLOBALLFLAGS="$(OSXLFLAGS)"
|
|
||||||
|
|
||||||
FREEBSDRANLIB = /usr/bin/ranlib
|
|
||||||
FREEBSDCFLAGS = -g -fno-common -DRel4 -DFBSD -ansi -pedantic $(GCCWARNFLAGS)
|
|
||||||
FREEBSDLFLAGS =
|
|
||||||
FREEBSDMASTER = GLOBALCFLAGS="$(FREEBSDCFLAGS)" GLOBALLFLAGS="$(FREEBSDLFLAGS)" RANLIB="$(FREEBSDRANLIB)"
|
|
||||||
|
|
||||||
APOLLOCFLAGS = -g
|
|
||||||
APOLLOLFLAGS =
|
|
||||||
APOLLOMASTER = GLOBALCFLAGS="$(APOLLOCFLAGS)" GLOBALLFLAGS="$(APOLLOLFLAGS)"
|
|
||||||
|
|
||||||
NTCFLAGS = /D_WIN32 /Od /G3 /Zp2 /nologo /MT
|
|
||||||
NTLFLAGS =
|
|
||||||
NTMASTER = CC=CL GLOBALCFLAGS="$(NTCFLAGS)" GLOBALLFLAGS="$(NTLFLAGS)"
|
|
||||||
|
|
||||||
INTERIXCFLAGS = -g -fno-common -D_EMPTH_POSIX=1 -U_EMPTH_LWP -DRel4 -D_ALL_SOURCE $(GCCWARNFLAGS)
|
|
||||||
INTERIXLFLAGS = -lpthread
|
|
||||||
INTERIXMASTER = GLOBALCFLAGS="$(INTERIXCFLAGS)" GLOBALLFLAGS="$(INTERIXLFLAGS)" CLIENTLIBS=-lncurses
|
|
||||||
|
|
||||||
NEXTCFLAGS = -bsd -fwritable-strings -traditional -Dconst="" -Dinline=""
|
|
||||||
NEXTLFLAGS = -lsys_s
|
|
||||||
NEXTMASTER = GLOBALCFLAGS="$(NEXTCFLAGS)" GLOBALLFLAGS="$(NEXTLFLAGS)"
|
|
||||||
|
|
||||||
LINUXCFLAGS = -g -fno-common -D__USE_BSD -DRel4 $(GCCWARNFLAGS)
|
|
||||||
LINUXLFLAGS =
|
|
||||||
LINUXMASTER = GLOBALCFLAGS="$(LINUXCFLAGS)" GLOBALLFLAGS="$(LINUXLFLAGS)" CLIENTLIBS=-lncurses
|
|
||||||
|
|
||||||
LINUXPTHCFLAGS = -g -fno-common -D_EMPTH_POSIX=1 -U_EMPTH_LWP -DRel4 $(GCCWARNFLAGS)
|
|
||||||
LINUXPTHLFLAGS = -lpthread
|
|
||||||
LINUXPTHMASTER = GLOBALCFLAGS="$(LINUXPTHCFLAGS)" GLOBALLFLAGS="$(LINUXPTHLFLAGS)" CLIENTLIBS=-lncurses
|
|
||||||
|
|
||||||
HPRANLIB = true
|
|
||||||
HPCFLAGS = -Aa -Dsys5 -Dhpc -D_HPUX_SOURCE -Dhpux
|
|
||||||
HPLFLAGS =
|
|
||||||
HPMASTER = GLOBALCFLAGS="$(HPCFLAGS)" GLOBALLFLAGS="$(HPLFLAGS)" RANLIB="$(HPRANLIB)" CLIENTLIBS=-ltermcap
|
|
||||||
|
|
||||||
HPUXRANLIB = true
|
|
||||||
HPUXCFLAGS = -Dsys5
|
|
||||||
HPUXLFLAGS =
|
|
||||||
HPUXMASTER = GLOBALCFLAGS="$(HPUXCFLAGS)" GLOBALLFLAGS="$(HPUXLFLAGS)" RANLIB="$(HPUXRANLIB)" CLIENTLIBS=-ltermcap
|
|
||||||
|
|
||||||
IRIX5RANLIB = echo
|
|
||||||
IRIX5CFLAGS = -DSVR4 -DRel4 -DUCONTEXT -DMAKECONTEXT_SP_HIGH -O3 -fullwarn -woff 835,709
|
|
||||||
IRIX5LFLAGS = -lnsl
|
|
||||||
IRIX5MASTER = GLOBALCFLAGS="$(IRIX5CFLAGS)" GLOBALLFLAGS="$(IRIX5LFLAGS)" RANLIB="$(IRIX5RANLIB)"
|
|
||||||
|
|
||||||
IRIXRANLIB = echo
|
|
||||||
IRIXCFLAGS = -g -O -cckr -D_BSD_SIGNALS
|
|
||||||
IRIXLFLAGS =
|
|
||||||
IRIXMASTER = GLOBALCFLAGS="$(IRIXCFLAGS)" GLOBALLFLAGS="$(IRIXLFLAGS)" RANLIB="$(IRIXRANLIB)"
|
|
||||||
|
|
||||||
ISICFLAGS =
|
|
||||||
ISILFLAGS =
|
|
||||||
ISIMASTER = GLOBALCFLAGS="$(ISICFLAGS)" GLOBALLFLAGS="$(ISILFLAGS)"
|
|
||||||
|
|
||||||
RTPCCFLAGS = -DBSD_INCLUDES -Daix -Dsys5 $(LOCALCFLAGS) -a
|
|
||||||
RTPCLFLAGS =
|
|
||||||
RTPCMASTER = GLOBALCFLAGS="$(RTPCCFLAGS)" GLOBALLFLAGS="$(RTPCLFLAGS)"
|
|
||||||
|
|
||||||
# FIXME -DMAKECONTEXT_SP_HIGH is wrong for Solaris 10.
|
|
||||||
SOLCFLAGS = -g -DSVR4 -DRel4 -DUCONTEXT -DMAKECONTEXT_SP_HIGH -Dsolaris
|
|
||||||
SOLLFLAGS = -lnsl -lsocket -lthread
|
|
||||||
SOLMASTER = GLOBALCFLAGS="$(SOLCFLAGS)" GLOBALLFLAGS="$(SOLLFLAGS)"
|
|
||||||
|
|
||||||
SEQCFLAGS = -O -DALLYHARBOR -DSHOWPLANE -DDROPANY -DREJECTS -DBMAP -DAUTONAV -DSCUTTLE -DCONVASAT -DORBIT -DABM -DGRIND -DPINPOINTMISSILE -DFALLOUT -DSAIL -DLOWSTARTMOB -DFIXREALMS -DBUYTAX -DNUKEFAILDETONATE -DMISSINGMISSILES
|
|
||||||
SEQLFLAGS = /usr/att/lib/libc.a -lresolv
|
|
||||||
SEQIFLAGS = -I/usr/include -I/usr/att/usr/include
|
|
||||||
SEQMASTER = GLOBALCFLAGS="$(SEQCFLAGS)" GLOBALLFLAGS="$(SEQLFLAGS)" LOCALIFLAGS="$(SEQIFLAGS)"
|
|
||||||
|
|
||||||
SEQFPACFLAGS = -g
|
|
||||||
SEQFPALFLAGS = /usr/att/lib/libfpac.a
|
|
||||||
SEQFPAIFLAGS = -I/usr/include -I/usr/att/usr/include -fpa
|
|
||||||
SEQFPAMASTER = GLOBALCFLAGS="$(SEQFPACFLAGS)" GLOBALLFLAGS="$(SEQFPALFLAGS)" LOCALIFLAGS="$(SEQFPAIFLAGS)"
|
|
||||||
|
|
||||||
SUN3CFLAGS = -g -f68881
|
|
||||||
SUN3LFLAGS =
|
|
||||||
SUN3MASTER = GLOBALCFLAGS="$(SUN3CFLAGS)" GLOBALLFLAGS="$(SUN3LFLAGS)"
|
|
||||||
|
|
||||||
SUN4CFLAGS = -DSUN4
|
|
||||||
SUN4LFLAGS =
|
|
||||||
SUN4MASTER = GLOBALCFLAGS="$(SUN4CFLAGS)" GLOBALLFLAGS="$(SUN4LFLAGS)"
|
|
||||||
|
|
||||||
SUN4DBGCFLAGS = -g -DSUN4
|
|
||||||
SUN4DBGLFLAGS =
|
|
||||||
SUN4DBGMASTER = GLOBALCFLAGS="$(SUN4DBGCFLAGS)" GLOBALLFLAGS="$(SUN4DBGLFLAGS)"
|
|
||||||
|
|
||||||
SUN4OPTCFLAGS = -O -DSUN4
|
|
||||||
SUN4OPTLFLAGS =
|
|
||||||
SUN4OPTMASTER = GLOBALCFLAGS="$(SUN4OPTCFLAGS)" GLOBALLFLAGS="$(SUN4OPTLFLAGS)"
|
|
||||||
|
|
||||||
AIXCFLAGS = -Daix -Dsys5 $(LOCALCFLAGS) -D_BSD_INCLUDES -D_BSD -D_NO_PROTO -D_NONSTD_TYPES -U__STR__ -DAIX32
|
|
||||||
AIXLFLAGS = -lbsd
|
|
||||||
AIXMASTER = GLOBALCFLAGS="$(AIXCFLAGS)" GLOBALLFLAGS="$(AIXLFLAGS)" CLIENTLIBS="-lcurses"
|
|
||||||
|
|
||||||
ALPHACFLAGS = -DALPHA -g -std1
|
|
||||||
ALPHALFLAGS = -non_shared -lots
|
|
||||||
ALPHAMASTER = GLOBALCFLAGS="$(ALPHACFLAGS)" GLOBALLFLAGS="$(ALPHALFLAGS)"
|
|
||||||
|
|
||||||
ALPHAPOSCFLAGS = -D_EMPTH_POSIX=1 -U_EMPTH_LWP -D_PTHREAD_USE_D4 -D_REENTRANT -DALPHA -g -std1
|
|
||||||
ALPHAPOSLFLAGS = -lpthreads
|
|
||||||
ALPHAPOSPFLAGS =
|
|
||||||
ALPHAPOSMASTER = GLOBALCFLAGS="$(ALPHAPOSCFLAGS)" GLOBALLFLAGS="$(ALPHAPOSLFLAGS)" GLOBALPFLAGS="$(ALPHAPOSPFLAGS)"
|
|
||||||
|
|
||||||
MACH25CFLAGS = -O
|
|
||||||
MACH25LFLAGS =
|
|
||||||
MACH25MASTER = GLOBALCFLAGS="$(MACH25CFLAGS)" GLOBALLFLAGS="$(MACH25LFLAGS)"
|
|
484
Makefile
484
Makefile
|
@ -1,484 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996-2000
|
|
||||||
# Do a generic build just by typing in "make <arch>"
|
|
||||||
#
|
|
||||||
# Note that the NT builds were done using MSVC 5.0 and using "nmake nt"
|
|
||||||
# So, to build anything on NT, just put an "nt" in front (for example,
|
|
||||||
# "ntclean", "ntinstall", etc.
|
|
||||||
|
|
||||||
include build.conf
|
|
||||||
include Make.sysdefs
|
|
||||||
|
|
||||||
TOBUILD = all
|
|
||||||
GENMASTER = $(TOBUILD) GLOBALCFLAGS="$(GLOBALCFLAGS)" GLOBALLFLAGS="$(GLOBALLFLAGS)"
|
|
||||||
CLIENTLIBS = -ltermcap
|
|
||||||
|
|
||||||
|
|
||||||
#
|
|
||||||
# Specific targets - make a new one for each new architecture or
|
|
||||||
# build environment.
|
|
||||||
#
|
|
||||||
|
|
||||||
all:
|
|
||||||
@echo 'You must type "make <arch>" to build for a specific system.'
|
|
||||||
@echo 'Currently buildable architectures are:'
|
|
||||||
@echo ' aix'
|
|
||||||
@echo ' alpha'
|
|
||||||
@echo ' alpha-pthreads'
|
|
||||||
@echo ' apollo'
|
|
||||||
@echo ' freebsd'
|
|
||||||
@echo ' hp'
|
|
||||||
@echo ' hpux'
|
|
||||||
@echo ' interix'
|
|
||||||
@echo ' irix'
|
|
||||||
@echo ' irix5'
|
|
||||||
@echo ' isi'
|
|
||||||
@echo ' linux'
|
|
||||||
@echo ' linux-pthreads'
|
|
||||||
@echo ' mach2.5'
|
|
||||||
@echo ' next'
|
|
||||||
@echo ' nt'
|
|
||||||
@echo ' osx'
|
|
||||||
@echo ' rtpc'
|
|
||||||
@echo ' sequent'
|
|
||||||
@echo ' sequent.fpa'
|
|
||||||
@echo ' solaris'
|
|
||||||
@echo ' sun3'
|
|
||||||
@echo ' sun4'
|
|
||||||
@echo ' sun4.debug'
|
|
||||||
@echo ' sun4.opt'
|
|
||||||
|
|
||||||
alpha:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(ALPHAMASTER))
|
|
||||||
($(MAKE) genlibs $(ALPHAMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(ALPHAMASTER))
|
|
||||||
($(MAKE) binaries $(ALPHAMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
alpha-pthreads:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(ALPHAPOSMASTER))
|
|
||||||
($(MAKE) genlibs $(ALPHAPOSMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(ALPHAPOSMASTER))
|
|
||||||
($(MAKE) binaries $(ALPHAPOSMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
apollo:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(APOLLOMASTER))
|
|
||||||
($(MAKE) genlibs $(APOLLOMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(APOLLOMASTER))
|
|
||||||
($(MAKE) binaries $(APOLLOMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
freebsd:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(FREEBSDMASTER))
|
|
||||||
($(MAKE) genlibs $(FREEBSDMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(FREEBSDMASTER))
|
|
||||||
($(MAKE) binaries $(FREEBSDMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
hp:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(HPMASTER))
|
|
||||||
($(MAKE) genlibs $(HPMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(HPMASTER))
|
|
||||||
($(MAKE) binaries $(HPMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
hpux:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(HPUXMASTER))
|
|
||||||
($(MAKE) genlibs $(HPUXMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(HPUXMASTER))
|
|
||||||
($(MAKE) binaries $(HPUXMASTER) CLIENTLIBS="")
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
next:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(NEXTMASTER))
|
|
||||||
($(MAKE) genlibs $(NEXTMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(NEXTMASTER))
|
|
||||||
($(MAKE) binaries $(NEXTMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
osx:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(OSXMASTER))
|
|
||||||
($(MAKE) genlibs $(OSXMASTER))
|
|
||||||
($(MAKE) binaries TOBUILD=osx $(OSXMASTER) CLIENTLIBS="")
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
irix:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(IRIXMASTER))
|
|
||||||
($(MAKE) genlibs $(IRIXMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(IRIXMASTER))
|
|
||||||
($(MAKE) binaries $(IRIXMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
irix5:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(IRIX5MASTER))
|
|
||||||
($(MAKE) genlibs $(IRIX5MASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(IRIX5MASTER))
|
|
||||||
($(MAKE) binaries $(IRIX5MASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
isi:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(ISIMASTER))
|
|
||||||
($(MAKE) genlibs $(ISIMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(ISIMASTER))
|
|
||||||
($(MAKE) binaries $(ISIMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
linux:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
@echo 'This build is only tested on x86 machines. Try using'
|
|
||||||
@echo 'linux-pthreads for other architectures.'
|
|
||||||
(cd src/doconfig; $(MAKE) $(LINUXMASTER))
|
|
||||||
($(MAKE) genlibs $(LINUXMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(LINUXMASTER))
|
|
||||||
($(MAKE) binaries $(LINUXMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
linux-pthreads:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(LINUXPTHMASTER))
|
|
||||||
($(MAKE) genlibs $(LINUXPTHMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(LINUXPTHMASTER))
|
|
||||||
($(MAKE) binaries $(LINUXPTHMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
mach2.5:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(MACH25MASTER))
|
|
||||||
($(MAKE) genlibs $(MACH25MASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) mipsultrix $(MACH25MASTER))
|
|
||||||
($(MAKE) binaries $(MACH25MASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
nt:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
cd src/doconfig
|
|
||||||
$(MAKE) nt $(NTMASTER)
|
|
||||||
cd ../..
|
|
||||||
$(MAKE) ntgenlibs TOBUILD=nt $(NTMASTER)
|
|
||||||
cd src/lib/lwp
|
|
||||||
$(MAKE) nt $(NTMASTER)
|
|
||||||
cd ../../..
|
|
||||||
$(MAKE) ntbinaries TOBUILD=nt $(NTMASTER)
|
|
||||||
$(MAKE) ntinstall
|
|
||||||
|
|
||||||
interix:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(INTERIXMASTER))
|
|
||||||
($(MAKE) genlibs $(INTERIXMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(INTERIXMASTER))
|
|
||||||
($(MAKE) binaries $(INTERIXMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
aix:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(AIXMASTER))
|
|
||||||
($(MAKE) genlibs $(AIXMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) aix $(AIXMASTER))
|
|
||||||
($(MAKE) binaries $(AIXMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
rtpc:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(RTPCMASTER))
|
|
||||||
($(MAKE) genlibs $(RTPCMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) aix $(RTPCMASTER))
|
|
||||||
($(MAKE) binaries $(RTPCMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
sequent:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(SEQMASTER))
|
|
||||||
($(MAKE) genlibs $(SEQMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(SEQMASTER))
|
|
||||||
($(MAKE) binaries $(SEQMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
sequent.fpa:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(SEQFPAMASTER))
|
|
||||||
($(MAKE) genlibs $(SEQFPAMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(SEQFPAMASTER))
|
|
||||||
($(MAKE) binaries $(SEQFPAMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
solaris:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(SOLMASTER))
|
|
||||||
($(MAKE) genlibs $(SOLMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(SOLMASTER))
|
|
||||||
($(MAKE) binaries $(SOLMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
sun3:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(SUN3MASTER))
|
|
||||||
($(MAKE) genlibs $(SUN3MASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(SUN3MASTER))
|
|
||||||
($(MAKE) binaries $(SUN3MASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
sun4:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(SUN4MASTER))
|
|
||||||
($(MAKE) genlibs $(SUN4MASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(SUN4MASTER))
|
|
||||||
($(MAKE) binaries $(SUN4MASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
sun4.opt:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(SUN4OPTMASTER))
|
|
||||||
($(MAKE) genlibs $(SUN4OPTMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(SUN4OPTMASTER))
|
|
||||||
($(MAKE) binaries $(SUN4OPTMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
sun4.debug:
|
|
||||||
@echo 'building a $(WORLDX) by $(WORLDY) server...'
|
|
||||||
(cd src/doconfig; $(MAKE) $(SUN4DBGMASTER))
|
|
||||||
($(MAKE) genlibs $(SUN4DBGMASTER))
|
|
||||||
(cd src/lib/lwp; $(MAKE) $(SUN4DBGMASTER))
|
|
||||||
($(MAKE) binaries $(SUN4DBGMASTER))
|
|
||||||
($(MAKE) install)
|
|
||||||
|
|
||||||
#
|
|
||||||
# Generic stuff that is called from the architecture specific stuff.
|
|
||||||
#
|
|
||||||
|
|
||||||
binaries:
|
|
||||||
@echo 'building the binaries'
|
|
||||||
(cd src/client; $(MAKE) $(GENMASTER) CLIENTLIBS=$(CLIENTLIBS))
|
|
||||||
(cd src/server; $(MAKE) $(GENMASTER))
|
|
||||||
(cd src/util; $(MAKE) $(GENMASTER))
|
|
||||||
|
|
||||||
ntbinaries:
|
|
||||||
@echo 'building the binaries'
|
|
||||||
cd src/client
|
|
||||||
$(MAKE) $(GENMASTER) CLIENTLIBS=$(CLIENTLIBS)
|
|
||||||
cd ../..
|
|
||||||
cd src/server
|
|
||||||
$(MAKE) $(GENMASTER)
|
|
||||||
cd ../..
|
|
||||||
cd src/util
|
|
||||||
$(MAKE) $(GENMASTER)
|
|
||||||
cd ../..
|
|
||||||
|
|
||||||
genlibs:
|
|
||||||
@echo 'building generic libraries'
|
|
||||||
-mkdir lib
|
|
||||||
(cd src/lib/as; $(MAKE) $(GENMASTER))
|
|
||||||
(cd src/lib/commands; $(MAKE) $(GENMASTER))
|
|
||||||
(cd src/lib/common; $(MAKE) $(GENMASTER))
|
|
||||||
(cd src/lib/empthread; $(MAKE) $(GENMASTER))
|
|
||||||
(cd src/lib/gen; $(MAKE) $(GENMASTER))
|
|
||||||
(cd src/lib/global; $(MAKE) $(GENMASTER))
|
|
||||||
(cd src/lib/player; $(MAKE) $(GENMASTER))
|
|
||||||
(cd src/lib/subs; $(MAKE) $(GENMASTER))
|
|
||||||
(cd src/lib/update; $(MAKE) $(GENMASTER))
|
|
||||||
@echo 'done building generic libraries'
|
|
||||||
|
|
||||||
ntgenlibs:
|
|
||||||
@echo 'building generic libraries'
|
|
||||||
-(mkdir lib)
|
|
||||||
cd src/lib/as
|
|
||||||
$(MAKE) $(GENMASTER)
|
|
||||||
cd ../../..
|
|
||||||
cd src/lib/commands
|
|
||||||
$(MAKE) $(GENMASTER)
|
|
||||||
cd ../../..
|
|
||||||
cd src/lib/common
|
|
||||||
$(MAKE) $(GENMASTER)
|
|
||||||
cd ../../..
|
|
||||||
cd src/lib/empthread
|
|
||||||
$(MAKE) $(GENMASTER)
|
|
||||||
cd ../../..
|
|
||||||
cd src/lib/gen
|
|
||||||
$(MAKE) $(GENMASTER)
|
|
||||||
cd ../../..
|
|
||||||
cd src/lib/global
|
|
||||||
$(MAKE) $(GENMASTER)
|
|
||||||
cd ../../..
|
|
||||||
cd src/lib/player
|
|
||||||
$(MAKE) $(GENMASTER)
|
|
||||||
cd ../../..
|
|
||||||
cd src/lib/subs
|
|
||||||
$(MAKE) $(GENMASTER)
|
|
||||||
cd ../../..
|
|
||||||
cd src/lib/update
|
|
||||||
$(MAKE) $(GENMASTER)
|
|
||||||
cd ../../..
|
|
||||||
@echo 'done building generic libraries'
|
|
||||||
|
|
||||||
clean:
|
|
||||||
(cd src/lib/as; $(MAKE) clean)
|
|
||||||
(cd src/lib/commands; $(MAKE) clean)
|
|
||||||
(cd src/lib/common; $(MAKE) clean)
|
|
||||||
(cd src/lib/gen; $(MAKE) clean)
|
|
||||||
(cd src/lib/global; $(MAKE) clean)
|
|
||||||
(cd src/lib/player; $(MAKE) clean)
|
|
||||||
(cd src/lib/subs; $(MAKE) clean)
|
|
||||||
(cd src/lib/update; $(MAKE) clean)
|
|
||||||
(cd src/lib/lwp; $(MAKE) clean)
|
|
||||||
(cd src/lib/empthread; $(MAKE) clean)
|
|
||||||
(cd src/client; $(MAKE) clean)
|
|
||||||
(cd src/server; $(MAKE) clean)
|
|
||||||
(cd src/util; $(MAKE) clean)
|
|
||||||
(cd src/doconfig; $(MAKE) clean)
|
|
||||||
(rm -f lib/*.a)
|
|
||||||
|
|
||||||
ntclean:
|
|
||||||
cd src/lib/as
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../../
|
|
||||||
cd src/lib/commands
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../../
|
|
||||||
cd src/lib/common
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../../
|
|
||||||
cd src/lib/gen
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../../
|
|
||||||
cd src/lib/global
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../../
|
|
||||||
cd src/lib/player
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../../
|
|
||||||
cd src/lib/subs
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../../
|
|
||||||
cd src/lib/update
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../../
|
|
||||||
cd src/lib/lwp
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../../
|
|
||||||
cd src/lib/empthread
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../../
|
|
||||||
cd src/client
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../
|
|
||||||
cd src/server
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../
|
|
||||||
cd src/util
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../
|
|
||||||
cd src/doconfig
|
|
||||||
$(MAKE) clean
|
|
||||||
cd ../../
|
|
||||||
cd lib
|
|
||||||
-(del /Q *.lib)
|
|
||||||
|
|
||||||
realclean:
|
|
||||||
($(MAKE) clean)
|
|
||||||
(rm -f bin/*)
|
|
||||||
(rm -rf data/*)
|
|
||||||
-(rm -rf $(EMPDIR)/data/*)
|
|
||||||
-(rm -rf $(EMPDIR)/bin/*)
|
|
||||||
rm -rf lib info.nr info.html
|
|
||||||
rm -f include/gamesdef.h src/client/ipglob.c src/make.src
|
|
||||||
|
|
||||||
ntrealclean:
|
|
||||||
$(MAKE) ntclean
|
|
||||||
cd bin
|
|
||||||
-(del /Q *.*)
|
|
||||||
cd ..
|
|
||||||
cd data
|
|
||||||
-(del /Q *.*)
|
|
||||||
cd ..
|
|
||||||
cd $(EMPDIR)\data
|
|
||||||
-(del /Q *.*)
|
|
||||||
-(rmdir tel)
|
|
||||||
cd $(EMPDIR)\bin
|
|
||||||
-(del /Q *.*)
|
|
||||||
cd $(EMPDIR)\data\tel
|
|
||||||
-(del /Q *.*)
|
|
||||||
|
|
||||||
depend:
|
|
||||||
(cd src/lib/as; $(MAKE) depend)
|
|
||||||
(cd src/lib/commands; $(MAKE) depend)
|
|
||||||
(cd src/lib/common; $(MAKE) depend)
|
|
||||||
(cd src/lib/gen; $(MAKE) depend)
|
|
||||||
(cd src/lib/global; $(MAKE) depend)
|
|
||||||
(cd src/lib/player; $(MAKE) depend)
|
|
||||||
(cd src/lib/subs; $(MAKE) depend)
|
|
||||||
(cd src/lib/update; $(MAKE) depend)
|
|
||||||
(cd src/lib/lwp; $(MAKE) depend)
|
|
||||||
(cd src/lib/empthread; $(MAKE) depend)
|
|
||||||
(cd src/client; $(MAKE) depend)
|
|
||||||
(cd src/server; $(MAKE) depend)
|
|
||||||
(cd src/util; $(MAKE) depend)
|
|
||||||
(cd src/doconfig; $(MAKE) depend)
|
|
||||||
|
|
||||||
# The last three lines here ensure that we don't overwrite an existing
|
|
||||||
# econfig file, by moving it first then moving it back. The '-''s
|
|
||||||
# ignore any errors (like if the files don't exist.)
|
|
||||||
# So, after an install, you will have an "econfig" file in the
|
|
||||||
# data directory if you didn't have one before.
|
|
||||||
|
|
||||||
install:
|
|
||||||
(cd src/client; $(MAKE) install)
|
|
||||||
(cd src/server; $(MAKE) install)
|
|
||||||
(cd src/util; $(MAKE) install)
|
|
||||||
-mkdir $(EMPDIR)/data
|
|
||||||
-(mv $(EMPDIR)/data/econfig $(EMPDIR)/data/econfig.bak)
|
|
||||||
($(EMPDIR)/bin/pconfig > $(EMPDIR)/data/econfig)
|
|
||||||
-(mv $(EMPDIR)/data/econfig.bak $(EMPDIR)/data/econfig)
|
|
||||||
|
|
||||||
ntinstall:
|
|
||||||
cd src\client
|
|
||||||
$(MAKE) ntinstall
|
|
||||||
cd ..\..
|
|
||||||
cd src\server
|
|
||||||
$(MAKE) ntinstall
|
|
||||||
cd ..\..
|
|
||||||
cd src\util
|
|
||||||
$(MAKE) ntinstall
|
|
||||||
cd ..\..
|
|
||||||
-mkdir $(NTINSTDIR)\data
|
|
||||||
cd $(NTINSTDIR)\data
|
|
||||||
($(NTINSTDIR)\bin\pconfig.exe > $(NTINSTDIR)\data\econfig.new)
|
|
||||||
-(move econfig.new econfig)
|
|
||||||
cd ..
|
|
||||||
|
|
||||||
dist:
|
|
||||||
src/scripts/mkdist
|
|
18
README
18
README
|
@ -19,18 +19,13 @@ below to build and start the server.
|
||||||
server in binary format, go to the next step, "Creating the world."
|
server in binary format, go to the next step, "Creating the world."
|
||||||
|
|
||||||
To build the server, you need to do the following steps:
|
To build the server, you need to do the following steps:
|
||||||
|
FIXME needs work
|
||||||
|
|
||||||
1) Get a copy of the source. Since you're reading this, we assume
|
1) Get a copy of the source. Since you're reading this, we assume
|
||||||
you have done that.
|
you have done that.
|
||||||
2) Gunzip the source. Again, since you're reading this . . . ;-)
|
2) Gunzip the source. Again, since you're reading this . . . ;-)
|
||||||
3) edit the build.conf file in this directory, and answer the questions
|
3) Run configure.
|
||||||
it asks you.
|
4) Run make.
|
||||||
4) type "make" to see what architectures are currently supported.
|
|
||||||
5) choose the architecture that best suits you, and type "make <arch>"
|
|
||||||
where <arch> is the architecture you want to build.
|
|
||||||
6) type "make depend" to build the dependencies (not required, but
|
|
||||||
helps a lot when you want to recompile something again.)
|
|
||||||
Note: "make depend" doesn't work under NT yet.
|
|
||||||
|
|
||||||
(3) Creating the world
|
(3) Creating the world
|
||||||
(NOTE: If you received a binary, you must edit the included data/econfig
|
(NOTE: If you received a binary, you must edit the included data/econfig
|
||||||
|
@ -63,11 +58,8 @@ is POGO/peter.
|
||||||
If you get a "You're not a deity!" message and logged off, check the
|
If you get a "You're not a deity!" message and logged off, check the
|
||||||
"data/server.log" file and look at the end for a "NON-AUTH" entry.
|
"data/server.log" file and look at the end for a "NON-AUTH" entry.
|
||||||
There should be a "user@host" message in there that failed to log in.
|
There should be a "user@host" message in there that failed to log in.
|
||||||
The user and host that your system is using may be different than the
|
Enter this user and host in the auth file, and you should be able to
|
||||||
one you put in your build.conf file. So, enter this new user and host
|
log into the server as a deity now.
|
||||||
in the auth file, and you should be able to log into the server as a
|
|
||||||
deity now. Note that if you rebuild the server again, the auth file
|
|
||||||
will be overwritten.
|
|
||||||
|
|
||||||
For more information on options, programs, files and other general hints
|
For more information on options, programs, files and other general hints
|
||||||
look in the "doc" directory. The README there describes the files there and
|
look in the "doc" directory. The README there describes the files there and
|
||||||
|
|
72
build.conf
72
build.conf
|
@ -1,72 +0,0 @@
|
||||||
#
|
|
||||||
# Below are a list of questions you may or may not need to answer. They
|
|
||||||
# are all one-liner. Just change the default value if needed, and save
|
|
||||||
# the file when done. Have fun!!!
|
|
||||||
#
|
|
||||||
|
|
||||||
# Please enter your name:
|
|
||||||
MYNAME = Wolfpack
|
|
||||||
|
|
||||||
# Please enter your user name:
|
|
||||||
# (For NT and the basic emp_client build, use "USERNAME = nobody")
|
|
||||||
USERNAME = wolfpack
|
|
||||||
|
|
||||||
# Please enter your e-mail address:
|
|
||||||
EMAIL = wolfpack@wolfpackempire.com
|
|
||||||
|
|
||||||
# Please enter the host name you will be running on:
|
|
||||||
# (For NT you can use "HOSTNAME = localhost" as this seems to be what it
|
|
||||||
# always resolves to if you use 127.0.0.1 below)
|
|
||||||
HOSTNAME = blitz.wolfpackempire.com
|
|
||||||
|
|
||||||
# Please enter the ip address of the host you will be running on:
|
|
||||||
# (For NT you can use "IPADDR = 127.0.0.1")
|
|
||||||
IPADDR = 216.162.200.183
|
|
||||||
|
|
||||||
# Please enter the port you will be running on:
|
|
||||||
PORTNUM = 6665
|
|
||||||
|
|
||||||
# Please enter the directory where you want the files for the game:
|
|
||||||
# (Note: Use a '/' to delimit directories. For NT, include a
|
|
||||||
# drive letter.)
|
|
||||||
EMPDIR = /home/wolfpack/emp4
|
|
||||||
|
|
||||||
# Ignore this next value for all builds except NT builds.
|
|
||||||
# For NT builds, use the above path, but replace the '/' with a '\'.
|
|
||||||
# Note that NTINSTDIR is not used for non-NT builds, and can be ignored.
|
|
||||||
# This is needed for the 'copy' comamnds, since they get very confused
|
|
||||||
# with the normal path names.
|
|
||||||
NTINSTDIR = C:\home\wolfpack\emp4
|
|
||||||
|
|
||||||
# Please enter the C-compiler you are using (full path is allowed):
|
|
||||||
# (For NT builds using MSVC, use "CC = CL")
|
|
||||||
CC = gcc
|
|
||||||
|
|
||||||
# Please enter the linker you are using (full path is allowed):
|
|
||||||
# (For NT builds using MSVC, using "LD = ld" works fine.)
|
|
||||||
LD = ld
|
|
||||||
|
|
||||||
# Please enter the maximum number of countries you want:
|
|
||||||
MAXNOC = 99
|
|
||||||
|
|
||||||
# Please enter the world size you would like (WORLDX must be
|
|
||||||
# divisible by 2):
|
|
||||||
WORLDX = 64
|
|
||||||
WORLDY = 32
|
|
||||||
|
|
||||||
# Please enter if you are setting up a blitz (1 - yes, 0 - no)
|
|
||||||
BLITZ = 1
|
|
||||||
|
|
||||||
# Please enter the number of ETUs per update (must be divisible by 4):
|
|
||||||
ETUS = 60
|
|
||||||
|
|
||||||
# Please enter the frequency of the updates. For example:
|
|
||||||
# Once per day - 1d
|
|
||||||
# Once every 20 minutes - 20m
|
|
||||||
# Once every 4 hours - 4h
|
|
||||||
ETUFREQ = 10m
|
|
||||||
|
|
||||||
# That's it... Save this file, and type "make <arch>" to build the
|
|
||||||
# server. If you are not sure of what architectures are supported,
|
|
||||||
# just type "make" and it will tell you. (If you are building the
|
|
||||||
# NT port, use "nmake" instead of "make".)
|
|
142
compile
Executable file
142
compile
Executable file
|
@ -0,0 +1,142 @@
|
||||||
|
#! /bin/sh
|
||||||
|
# Wrapper for compilers which do not understand `-c -o'.
|
||||||
|
|
||||||
|
scriptversion=2005-02-03.08
|
||||||
|
|
||||||
|
# Copyright (C) 1999, 2000, 2003, 2004, 2005 Free Software Foundation, Inc.
|
||||||
|
# Written by Tom Tromey <tromey@cygnus.com>.
|
||||||
|
#
|
||||||
|
# This program 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, or (at your option)
|
||||||
|
# any later version.
|
||||||
|
#
|
||||||
|
# This program 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.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License
|
||||||
|
# along with this program; if not, write to the Free Software
|
||||||
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
|
# As a special exception to the GNU General Public License, if you
|
||||||
|
# distribute this file as part of a program that contains a
|
||||||
|
# configuration script generated by Autoconf, you may include it under
|
||||||
|
# the same distribution terms that you use for the rest of that program.
|
||||||
|
|
||||||
|
# This file is maintained in Automake, please report
|
||||||
|
# bugs to <bug-automake@gnu.org> or send patches to
|
||||||
|
# <automake-patches@gnu.org>.
|
||||||
|
|
||||||
|
case $1 in
|
||||||
|
'')
|
||||||
|
echo "$0: No command. Try \`$0 --help' for more information." 1>&2
|
||||||
|
exit 1;
|
||||||
|
;;
|
||||||
|
-h | --h*)
|
||||||
|
cat <<\EOF
|
||||||
|
Usage: compile [--help] [--version] PROGRAM [ARGS]
|
||||||
|
|
||||||
|
Wrapper for compilers which do not understand `-c -o'.
|
||||||
|
Remove `-o dest.o' from ARGS, run PROGRAM with the remaining
|
||||||
|
arguments, and rename the output as expected.
|
||||||
|
|
||||||
|
If you are trying to build a whole package this is not the
|
||||||
|
right script to run: please start by reading the file `INSTALL'.
|
||||||
|
|
||||||
|
Report bugs to <bug-automake@gnu.org>.
|
||||||
|
EOF
|
||||||
|
exit $?
|
||||||
|
;;
|
||||||
|
-v | --v*)
|
||||||
|
echo "compile $scriptversion"
|
||||||
|
exit $?
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
ofile=
|
||||||
|
cfile=
|
||||||
|
eat=
|
||||||
|
|
||||||
|
for arg
|
||||||
|
do
|
||||||
|
if test -n "$eat"; then
|
||||||
|
eat=
|
||||||
|
else
|
||||||
|
case $1 in
|
||||||
|
-o)
|
||||||
|
# configure might choose to run compile as `compile cc -o foo foo.c'.
|
||||||
|
# So we strip `-o arg' only if arg is an object.
|
||||||
|
eat=1
|
||||||
|
case $2 in
|
||||||
|
*.o | *.obj)
|
||||||
|
ofile=$2
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set x "$@" -o "$2"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
*.c)
|
||||||
|
cfile=$1
|
||||||
|
set x "$@" "$1"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set x "$@" "$1"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
shift
|
||||||
|
done
|
||||||
|
|
||||||
|
if test -z "$ofile" || test -z "$cfile"; then
|
||||||
|
# If no `-o' option was seen then we might have been invoked from a
|
||||||
|
# pattern rule where we don't need one. That is ok -- this is a
|
||||||
|
# normal compilation that the losing compiler can handle. If no
|
||||||
|
# `.c' file was seen then we are probably linking. That is also
|
||||||
|
# ok.
|
||||||
|
exec "$@"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Name of file we expect compiler to create.
|
||||||
|
cofile=`echo "$cfile" | sed -e 's|^.*/||' -e 's/\.c$/.o/'`
|
||||||
|
|
||||||
|
# Create the lock directory.
|
||||||
|
# Note: use `[/.-]' here to ensure that we don't use the same name
|
||||||
|
# that we are using for the .o file. Also, base the name on the expected
|
||||||
|
# object file name, since that is what matters with a parallel build.
|
||||||
|
lockdir=`echo "$cofile" | sed -e 's|[/.-]|_|g'`.d
|
||||||
|
while true; do
|
||||||
|
if mkdir "$lockdir" >/dev/null 2>&1; then
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
sleep 1
|
||||||
|
done
|
||||||
|
# FIXME: race condition here if user kills between mkdir and trap.
|
||||||
|
trap "rmdir '$lockdir'; exit 1" 1 2 15
|
||||||
|
|
||||||
|
# Run the compile.
|
||||||
|
"$@"
|
||||||
|
ret=$?
|
||||||
|
|
||||||
|
if test -f "$cofile"; then
|
||||||
|
mv "$cofile" "$ofile"
|
||||||
|
elif test -f "${cofile}bj"; then
|
||||||
|
mv "${cofile}bj" "$ofile"
|
||||||
|
fi
|
||||||
|
|
||||||
|
rmdir "$lockdir"
|
||||||
|
exit $ret
|
||||||
|
|
||||||
|
# Local Variables:
|
||||||
|
# mode: shell-script
|
||||||
|
# sh-indentation: 2
|
||||||
|
# eval: (add-hook 'write-file-hooks 'time-stamp)
|
||||||
|
# time-stamp-start: "scriptversion="
|
||||||
|
# time-stamp-format: "%:y-%02m-%02d.%02H"
|
||||||
|
# time-stamp-end: "$"
|
||||||
|
# End:
|
1465
config.guess
vendored
Executable file
1465
config.guess
vendored
Executable file
File diff suppressed because it is too large
Load diff
1569
config.sub
vendored
Executable file
1569
config.sub
vendored
Executable file
File diff suppressed because it is too large
Load diff
139
configure.ac
Normal file
139
configure.ac
Normal file
|
@ -0,0 +1,139 @@
|
||||||
|
#
|
||||||
|
# Empire - A multi-player, client/server Internet based war game.
|
||||||
|
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
||||||
|
# Ken Stevens, Steve McClure
|
||||||
|
#
|
||||||
|
# This program 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.
|
||||||
|
#
|
||||||
|
# This program 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.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License
|
||||||
|
# along with this program; if not, write to the Free Software
|
||||||
|
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
|
#
|
||||||
|
# ---
|
||||||
|
#
|
||||||
|
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
||||||
|
# related information and legal notices. It is expected that any future
|
||||||
|
# projects/authors will amend these files as needed.
|
||||||
|
#
|
||||||
|
# ---
|
||||||
|
#
|
||||||
|
# configure.ac: Autoconf input file
|
||||||
|
#
|
||||||
|
# Known contributors to this file:
|
||||||
|
# Markus Armbruster, 2005
|
||||||
|
#
|
||||||
|
# Process this file with autoconf to produce a configure script.
|
||||||
|
|
||||||
|
# Autoconf makes checking for and programming around assorted ancient
|
||||||
|
# crap relatively painless. But why bother? Just rely on C89 and
|
||||||
|
# POSIX, and when something breaks on some oddball machine, see
|
||||||
|
# whether it's worth fixing.
|
||||||
|
|
||||||
|
AC_PREREQ(2.59)
|
||||||
|
AC_INIT([Empire], [4.3.0], [wolfpack@wolfpackempire.com])
|
||||||
|
AC_CONFIG_SRCDIR([include/combat.h])
|
||||||
|
AC_CONFIG_MACRO_DIR([m4])
|
||||||
|
AC_CONFIG_HEADERS([config.h])
|
||||||
|
|
||||||
|
|
||||||
|
### Checks for programs
|
||||||
|
AC_PROG_AWK
|
||||||
|
AC_PROG_INSTALL
|
||||||
|
AC_PROG_RANLIB
|
||||||
|
AC_PROG_CC
|
||||||
|
AC_SUBST(GCC)
|
||||||
|
AM_PROG_CC_C_O
|
||||||
|
# Private automake macro, tsk, tsk, tsk...
|
||||||
|
_AM_DEPENDENCIES(CC)
|
||||||
|
|
||||||
|
# not really a check for a program, but close enough
|
||||||
|
if test -d $srcdir/CVS; then cvs_controlled=yes; else cvs_controlled=no; fi
|
||||||
|
AC_SUBST(cvs_controlled,$cvs_controlled)
|
||||||
|
|
||||||
|
|
||||||
|
### Checks for libraries
|
||||||
|
ACX_PTHREAD
|
||||||
|
LIB_SOCKET_NSL
|
||||||
|
|
||||||
|
# TODO turn this into a macro?
|
||||||
|
save_LIBS=$LIBS
|
||||||
|
AC_SEARCH_LIBS([setupterm], [termlib termcap])
|
||||||
|
termlibs=`echo $LIBS | sed s/\`echo $save_LIBS | sed 's/././g'\`'$//'`
|
||||||
|
AC_SUBST(termlibs)
|
||||||
|
LIBS=$save_LIBS
|
||||||
|
|
||||||
|
|
||||||
|
### Checks for header files
|
||||||
|
|
||||||
|
|
||||||
|
### Checks for typedefs, structures, and compiler characteristics
|
||||||
|
|
||||||
|
|
||||||
|
### Checks for library functions
|
||||||
|
|
||||||
|
MY_FUNC_MAKECONTEXT
|
||||||
|
|
||||||
|
|
||||||
|
### Site configuration
|
||||||
|
|
||||||
|
AC_ARG_VAR([EMPIREHOST], [Default host (client only) [127.0.0.1]])
|
||||||
|
test "$EMPIREHOST" || EMPIREHOST=127.0.0.1
|
||||||
|
|
||||||
|
AC_ARG_VAR([EMPIREPORT], [Default port (client and server) [6665]])
|
||||||
|
test "$EMPIREPORT" || EMPIREPORT=6665
|
||||||
|
|
||||||
|
AC_ARG_WITH([pthread],
|
||||||
|
AS_HELP_STRING([--with-pthread],
|
||||||
|
[use POSIX threads]))
|
||||||
|
|
||||||
|
case "$ac_cv_func_makecontext$acx_pthread_ok" in
|
||||||
|
yesyes)
|
||||||
|
if test -z "$with_pthread" || test "$with_pthread" = no; then
|
||||||
|
empthread=LWP
|
||||||
|
else
|
||||||
|
empthread=POSIX
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
yes*)
|
||||||
|
empthread=LWP ;;
|
||||||
|
*yes)
|
||||||
|
empthread=POSIX ;;
|
||||||
|
*)
|
||||||
|
AC_MSG_ERROR([No usable thread package found])
|
||||||
|
esac
|
||||||
|
AC_SUBST(empthread)
|
||||||
|
AC_MSG_NOTICE([Using $empthread threads])
|
||||||
|
|
||||||
|
op=
|
||||||
|
if test "$with_pthread" = no; then
|
||||||
|
op='=='
|
||||||
|
elif test "$with_pthread"; then
|
||||||
|
op='!='
|
||||||
|
fi
|
||||||
|
if test "$op" && test "$empthread" $op POSIX; then
|
||||||
|
AC_MSG_WARN([Ignoring --with-pthread=$with_pthread])
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
### Output
|
||||||
|
|
||||||
|
AC_CONFIG_FILES([GNUmakefile])
|
||||||
|
AC_CONFIG_COMMANDS([stamp-h],
|
||||||
|
[if test $cvs_controlled = yes; then
|
||||||
|
mkdir -p `cd $srcdir && $AWK -f src/scripts/cvsfiles.awk \
|
||||||
|
| sed -n '/\//s,/@<:@^/@:>@*$,,gp'| uniq`
|
||||||
|
elif test -f $srcdir/sources.mk; then
|
||||||
|
mkdir -p `sed s/.*=// <$srcdir/sources.mk \
|
||||||
|
| sed -n '/\//s,/@<:@^/@:>@*$,,gp'| uniq`
|
||||||
|
fi
|
||||||
|
>stamp-h],
|
||||||
|
[cvs_controlled=$cvs_controlled; AWK=$AWK])
|
||||||
|
AC_OUTPUT
|
529
depcomp
Executable file
529
depcomp
Executable file
|
@ -0,0 +1,529 @@
|
||||||
|
#! /bin/sh
|
||||||
|
# depcomp - compile a program generating dependencies as side-effects
|
||||||
|
|
||||||
|
scriptversion=2005-02-09.22
|
||||||
|
|
||||||
|
# Copyright (C) 1999, 2000, 2003, 2004, 2005 Free Software Foundation, Inc.
|
||||||
|
|
||||||
|
# This program 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, or (at your option)
|
||||||
|
# any later version.
|
||||||
|
|
||||||
|
# This program 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.
|
||||||
|
|
||||||
|
# You should have received a copy of the GNU General Public License
|
||||||
|
# along with this program; if not, write to the Free Software
|
||||||
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
||||||
|
# 02111-1307, USA.
|
||||||
|
|
||||||
|
# As a special exception to the GNU General Public License, if you
|
||||||
|
# distribute this file as part of a program that contains a
|
||||||
|
# configuration script generated by Autoconf, you may include it under
|
||||||
|
# the same distribution terms that you use for the rest of that program.
|
||||||
|
|
||||||
|
# Originally written by Alexandre Oliva <oliva@dcc.unicamp.br>.
|
||||||
|
|
||||||
|
case $1 in
|
||||||
|
'')
|
||||||
|
echo "$0: No command. Try \`$0 --help' for more information." 1>&2
|
||||||
|
exit 1;
|
||||||
|
;;
|
||||||
|
-h | --h*)
|
||||||
|
cat <<\EOF
|
||||||
|
Usage: depcomp [--help] [--version] PROGRAM [ARGS]
|
||||||
|
|
||||||
|
Run PROGRAMS ARGS to compile a file, generating dependencies
|
||||||
|
as side-effects.
|
||||||
|
|
||||||
|
Environment variables:
|
||||||
|
depmode Dependency tracking mode.
|
||||||
|
source Source file read by `PROGRAMS ARGS'.
|
||||||
|
object Object file output by `PROGRAMS ARGS'.
|
||||||
|
DEPDIR directory where to store dependencies.
|
||||||
|
depfile Dependency file to output.
|
||||||
|
tmpdepfile Temporary file to use when outputing dependencies.
|
||||||
|
libtool Whether libtool is used (yes/no).
|
||||||
|
|
||||||
|
Report bugs to <bug-automake@gnu.org>.
|
||||||
|
EOF
|
||||||
|
exit $?
|
||||||
|
;;
|
||||||
|
-v | --v*)
|
||||||
|
echo "depcomp $scriptversion"
|
||||||
|
exit $?
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if test -z "$depmode" || test -z "$source" || test -z "$object"; then
|
||||||
|
echo "depcomp: Variables source, object and depmode must be set" 1>&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po.
|
||||||
|
depfile=${depfile-`echo "$object" |
|
||||||
|
sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`}
|
||||||
|
tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`}
|
||||||
|
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
|
||||||
|
# Some modes work just like other modes, but use different flags. We
|
||||||
|
# parameterize here, but still list the modes in the big case below,
|
||||||
|
# to make depend.m4 easier to write. Note that we *cannot* use a case
|
||||||
|
# here, because this file can only contain one case statement.
|
||||||
|
if test "$depmode" = hp; then
|
||||||
|
# HP compiler uses -M and no extra arg.
|
||||||
|
gccflag=-M
|
||||||
|
depmode=gcc
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test "$depmode" = dashXmstdout; then
|
||||||
|
# This is just like dashmstdout with a different argument.
|
||||||
|
dashmflag=-xM
|
||||||
|
depmode=dashmstdout
|
||||||
|
fi
|
||||||
|
|
||||||
|
case "$depmode" in
|
||||||
|
gcc3)
|
||||||
|
## gcc 3 implements dependency tracking that does exactly what
|
||||||
|
## we want. Yay! Note: for some reason libtool 1.4 doesn't like
|
||||||
|
## it if -MD -MP comes after the -MF stuff. Hmm.
|
||||||
|
"$@" -MT "$object" -MD -MP -MF "$tmpdepfile"
|
||||||
|
stat=$?
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
mv "$tmpdepfile" "$depfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
gcc)
|
||||||
|
## There are various ways to get dependency output from gcc. Here's
|
||||||
|
## why we pick this rather obscure method:
|
||||||
|
## - Don't want to use -MD because we'd like the dependencies to end
|
||||||
|
## up in a subdir. Having to rename by hand is ugly.
|
||||||
|
## (We might end up doing this anyway to support other compilers.)
|
||||||
|
## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like
|
||||||
|
## -MM, not -M (despite what the docs say).
|
||||||
|
## - Using -M directly means running the compiler twice (even worse
|
||||||
|
## than renaming).
|
||||||
|
if test -z "$gccflag"; then
|
||||||
|
gccflag=-MD,
|
||||||
|
fi
|
||||||
|
"$@" -Wp,"$gccflag$tmpdepfile"
|
||||||
|
stat=$?
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
rm -f "$depfile"
|
||||||
|
echo "$object : \\" > "$depfile"
|
||||||
|
alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
|
||||||
|
## The second -e expression handles DOS-style file names with drive letters.
|
||||||
|
sed -e 's/^[^:]*: / /' \
|
||||||
|
-e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile"
|
||||||
|
## This next piece of magic avoids the `deleted header file' problem.
|
||||||
|
## The problem is that when a header file which appears in a .P file
|
||||||
|
## is deleted, the dependency causes make to die (because there is
|
||||||
|
## typically no way to rebuild the header). We avoid this by adding
|
||||||
|
## dummy dependencies for each header file. Too bad gcc doesn't do
|
||||||
|
## this for us directly.
|
||||||
|
tr ' ' '
|
||||||
|
' < "$tmpdepfile" |
|
||||||
|
## Some versions of gcc put a space before the `:'. On the theory
|
||||||
|
## that the space means something, we add a space to the output as
|
||||||
|
## well.
|
||||||
|
## Some versions of the HPUX 10.20 sed can't process this invocation
|
||||||
|
## correctly. Breaking it into two sed invocations is a workaround.
|
||||||
|
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
hp)
|
||||||
|
# This case exists only to let depend.m4 do its work. It works by
|
||||||
|
# looking at the text of this script. This case will never be run,
|
||||||
|
# since it is checked for above.
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
|
||||||
|
sgi)
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
"$@" "-Wp,-MDupdate,$tmpdepfile"
|
||||||
|
else
|
||||||
|
"$@" -MDupdate "$tmpdepfile"
|
||||||
|
fi
|
||||||
|
stat=$?
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
rm -f "$depfile"
|
||||||
|
|
||||||
|
if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files
|
||||||
|
echo "$object : \\" > "$depfile"
|
||||||
|
|
||||||
|
# Clip off the initial element (the dependent). Don't try to be
|
||||||
|
# clever and replace this with sed code, as IRIX sed won't handle
|
||||||
|
# lines with more than a fixed number of characters (4096 in
|
||||||
|
# IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines;
|
||||||
|
# the IRIX cc adds comments like `#:fec' to the end of the
|
||||||
|
# dependency line.
|
||||||
|
tr ' ' '
|
||||||
|
' < "$tmpdepfile" \
|
||||||
|
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \
|
||||||
|
tr '
|
||||||
|
' ' ' >> $depfile
|
||||||
|
echo >> $depfile
|
||||||
|
|
||||||
|
# The second pass generates a dummy entry for each header file.
|
||||||
|
tr ' ' '
|
||||||
|
' < "$tmpdepfile" \
|
||||||
|
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \
|
||||||
|
>> $depfile
|
||||||
|
else
|
||||||
|
# The sourcefile does not contain any dependencies, so just
|
||||||
|
# store a dummy comment line, to avoid errors with the Makefile
|
||||||
|
# "include basename.Plo" scheme.
|
||||||
|
echo "#dummy" > "$depfile"
|
||||||
|
fi
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
aix)
|
||||||
|
# The C for AIX Compiler uses -M and outputs the dependencies
|
||||||
|
# in a .u file. In older versions, this file always lives in the
|
||||||
|
# current directory. Also, the AIX compiler puts `$object:' at the
|
||||||
|
# start of each line; $object doesn't have directory information.
|
||||||
|
# Version 6 uses the directory in both cases.
|
||||||
|
stripped=`echo "$object" | sed 's/\(.*\)\..*$/\1/'`
|
||||||
|
tmpdepfile="$stripped.u"
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
"$@" -Wc,-M
|
||||||
|
else
|
||||||
|
"$@" -M
|
||||||
|
fi
|
||||||
|
stat=$?
|
||||||
|
|
||||||
|
if test -f "$tmpdepfile"; then :
|
||||||
|
else
|
||||||
|
stripped=`echo "$stripped" | sed 's,^.*/,,'`
|
||||||
|
tmpdepfile="$stripped.u"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test -f "$tmpdepfile"; then
|
||||||
|
outname="$stripped.o"
|
||||||
|
# Each line is of the form `foo.o: dependent.h'.
|
||||||
|
# Do two passes, one to just change these to
|
||||||
|
# `$object: dependent.h' and one to simply `dependent.h:'.
|
||||||
|
sed -e "s,^$outname:,$object :," < "$tmpdepfile" > "$depfile"
|
||||||
|
sed -e "s,^$outname: \(.*\)$,\1:," < "$tmpdepfile" >> "$depfile"
|
||||||
|
else
|
||||||
|
# The sourcefile does not contain any dependencies, so just
|
||||||
|
# store a dummy comment line, to avoid errors with the Makefile
|
||||||
|
# "include basename.Plo" scheme.
|
||||||
|
echo "#dummy" > "$depfile"
|
||||||
|
fi
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
icc)
|
||||||
|
# Intel's C compiler understands `-MD -MF file'. However on
|
||||||
|
# icc -MD -MF foo.d -c -o sub/foo.o sub/foo.c
|
||||||
|
# ICC 7.0 will fill foo.d with something like
|
||||||
|
# foo.o: sub/foo.c
|
||||||
|
# foo.o: sub/foo.h
|
||||||
|
# which is wrong. We want:
|
||||||
|
# sub/foo.o: sub/foo.c
|
||||||
|
# sub/foo.o: sub/foo.h
|
||||||
|
# sub/foo.c:
|
||||||
|
# sub/foo.h:
|
||||||
|
# ICC 7.1 will output
|
||||||
|
# foo.o: sub/foo.c sub/foo.h
|
||||||
|
# and will wrap long lines using \ :
|
||||||
|
# foo.o: sub/foo.c ... \
|
||||||
|
# sub/foo.h ... \
|
||||||
|
# ...
|
||||||
|
|
||||||
|
"$@" -MD -MF "$tmpdepfile"
|
||||||
|
stat=$?
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
rm -f "$depfile"
|
||||||
|
# Each line is of the form `foo.o: dependent.h',
|
||||||
|
# or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'.
|
||||||
|
# Do two passes, one to just change these to
|
||||||
|
# `$object: dependent.h' and one to simply `dependent.h:'.
|
||||||
|
sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile"
|
||||||
|
# Some versions of the HPUX 10.20 sed can't process this invocation
|
||||||
|
# correctly. Breaking it into two sed invocations is a workaround.
|
||||||
|
sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" |
|
||||||
|
sed -e 's/$/ :/' >> "$depfile"
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
tru64)
|
||||||
|
# The Tru64 compiler uses -MD to generate dependencies as a side
|
||||||
|
# effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'.
|
||||||
|
# At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put
|
||||||
|
# dependencies in `foo.d' instead, so we check for that too.
|
||||||
|
# Subdirectories are respected.
|
||||||
|
dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
|
||||||
|
test "x$dir" = "x$object" && dir=
|
||||||
|
base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
|
||||||
|
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
# With Tru64 cc, shared objects can also be used to make a
|
||||||
|
# static library. This mecanism is used in libtool 1.4 series to
|
||||||
|
# handle both shared and static libraries in a single compilation.
|
||||||
|
# With libtool 1.4, dependencies were output in $dir.libs/$base.lo.d.
|
||||||
|
#
|
||||||
|
# With libtool 1.5 this exception was removed, and libtool now
|
||||||
|
# generates 2 separate objects for the 2 libraries. These two
|
||||||
|
# compilations output dependencies in in $dir.libs/$base.o.d and
|
||||||
|
# in $dir$base.o.d. We have to check for both files, because
|
||||||
|
# one of the two compilations can be disabled. We should prefer
|
||||||
|
# $dir$base.o.d over $dir.libs/$base.o.d because the latter is
|
||||||
|
# automatically cleaned when .libs/ is deleted, while ignoring
|
||||||
|
# the former would cause a distcleancheck panic.
|
||||||
|
tmpdepfile1=$dir.libs/$base.lo.d # libtool 1.4
|
||||||
|
tmpdepfile2=$dir$base.o.d # libtool 1.5
|
||||||
|
tmpdepfile3=$dir.libs/$base.o.d # libtool 1.5
|
||||||
|
tmpdepfile4=$dir.libs/$base.d # Compaq CCC V6.2-504
|
||||||
|
"$@" -Wc,-MD
|
||||||
|
else
|
||||||
|
tmpdepfile1=$dir$base.o.d
|
||||||
|
tmpdepfile2=$dir$base.d
|
||||||
|
tmpdepfile3=$dir$base.d
|
||||||
|
tmpdepfile4=$dir$base.d
|
||||||
|
"$@" -MD
|
||||||
|
fi
|
||||||
|
|
||||||
|
stat=$?
|
||||||
|
if test $stat -eq 0; then :
|
||||||
|
else
|
||||||
|
rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4"
|
||||||
|
exit $stat
|
||||||
|
fi
|
||||||
|
|
||||||
|
for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4"
|
||||||
|
do
|
||||||
|
test -f "$tmpdepfile" && break
|
||||||
|
done
|
||||||
|
if test -f "$tmpdepfile"; then
|
||||||
|
sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile"
|
||||||
|
# That's a tab and a space in the [].
|
||||||
|
sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile"
|
||||||
|
else
|
||||||
|
echo "#dummy" > "$depfile"
|
||||||
|
fi
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
#nosideeffect)
|
||||||
|
# This comment above is used by automake to tell side-effect
|
||||||
|
# dependency tracking mechanisms from slower ones.
|
||||||
|
|
||||||
|
dashmstdout)
|
||||||
|
# Important note: in order to support this mode, a compiler *must*
|
||||||
|
# always write the preprocessed file to stdout, regardless of -o.
|
||||||
|
"$@" || exit $?
|
||||||
|
|
||||||
|
# Remove the call to Libtool.
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
while test $1 != '--mode=compile'; do
|
||||||
|
shift
|
||||||
|
done
|
||||||
|
shift
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Remove `-o $object'.
|
||||||
|
IFS=" "
|
||||||
|
for arg
|
||||||
|
do
|
||||||
|
case $arg in
|
||||||
|
-o)
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
$object)
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set fnord "$@" "$arg"
|
||||||
|
shift # fnord
|
||||||
|
shift # $arg
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
test -z "$dashmflag" && dashmflag=-M
|
||||||
|
# Require at least two characters before searching for `:'
|
||||||
|
# in the target name. This is to cope with DOS-style filenames:
|
||||||
|
# a dependency such as `c:/foo/bar' could be seen as target `c' otherwise.
|
||||||
|
"$@" $dashmflag |
|
||||||
|
sed 's:^[ ]*[^: ][^:][^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile"
|
||||||
|
rm -f "$depfile"
|
||||||
|
cat < "$tmpdepfile" > "$depfile"
|
||||||
|
tr ' ' '
|
||||||
|
' < "$tmpdepfile" | \
|
||||||
|
## Some versions of the HPUX 10.20 sed can't process this invocation
|
||||||
|
## correctly. Breaking it into two sed invocations is a workaround.
|
||||||
|
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
dashXmstdout)
|
||||||
|
# This case only exists to satisfy depend.m4. It is never actually
|
||||||
|
# run, as this mode is specially recognized in the preamble.
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
|
||||||
|
makedepend)
|
||||||
|
"$@" || exit $?
|
||||||
|
# Remove any Libtool call
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
while test $1 != '--mode=compile'; do
|
||||||
|
shift
|
||||||
|
done
|
||||||
|
shift
|
||||||
|
fi
|
||||||
|
# X makedepend
|
||||||
|
shift
|
||||||
|
cleared=no
|
||||||
|
for arg in "$@"; do
|
||||||
|
case $cleared in
|
||||||
|
no)
|
||||||
|
set ""; shift
|
||||||
|
cleared=yes ;;
|
||||||
|
esac
|
||||||
|
case "$arg" in
|
||||||
|
-D*|-I*)
|
||||||
|
set fnord "$@" "$arg"; shift ;;
|
||||||
|
# Strip any option that makedepend may not understand. Remove
|
||||||
|
# the object too, otherwise makedepend will parse it as a source file.
|
||||||
|
-*|$object)
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set fnord "$@" "$arg"; shift ;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
obj_suffix="`echo $object | sed 's/^.*\././'`"
|
||||||
|
touch "$tmpdepfile"
|
||||||
|
${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
|
||||||
|
rm -f "$depfile"
|
||||||
|
cat < "$tmpdepfile" > "$depfile"
|
||||||
|
sed '1,2d' "$tmpdepfile" | tr ' ' '
|
||||||
|
' | \
|
||||||
|
## Some versions of the HPUX 10.20 sed can't process this invocation
|
||||||
|
## correctly. Breaking it into two sed invocations is a workaround.
|
||||||
|
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
|
||||||
|
rm -f "$tmpdepfile" "$tmpdepfile".bak
|
||||||
|
;;
|
||||||
|
|
||||||
|
cpp)
|
||||||
|
# Important note: in order to support this mode, a compiler *must*
|
||||||
|
# always write the preprocessed file to stdout.
|
||||||
|
"$@" || exit $?
|
||||||
|
|
||||||
|
# Remove the call to Libtool.
|
||||||
|
if test "$libtool" = yes; then
|
||||||
|
while test $1 != '--mode=compile'; do
|
||||||
|
shift
|
||||||
|
done
|
||||||
|
shift
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Remove `-o $object'.
|
||||||
|
IFS=" "
|
||||||
|
for arg
|
||||||
|
do
|
||||||
|
case $arg in
|
||||||
|
-o)
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
$object)
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set fnord "$@" "$arg"
|
||||||
|
shift # fnord
|
||||||
|
shift # $arg
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
"$@" -E |
|
||||||
|
sed -n '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' |
|
||||||
|
sed '$ s: \\$::' > "$tmpdepfile"
|
||||||
|
rm -f "$depfile"
|
||||||
|
echo "$object : \\" > "$depfile"
|
||||||
|
cat < "$tmpdepfile" >> "$depfile"
|
||||||
|
sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile"
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
msvisualcpp)
|
||||||
|
# Important note: in order to support this mode, a compiler *must*
|
||||||
|
# always write the preprocessed file to stdout, regardless of -o,
|
||||||
|
# because we must use -o when running libtool.
|
||||||
|
"$@" || exit $?
|
||||||
|
IFS=" "
|
||||||
|
for arg
|
||||||
|
do
|
||||||
|
case "$arg" in
|
||||||
|
"-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI")
|
||||||
|
set fnord "$@"
|
||||||
|
shift
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set fnord "$@" "$arg"
|
||||||
|
shift
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
"$@" -E |
|
||||||
|
sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile"
|
||||||
|
rm -f "$depfile"
|
||||||
|
echo "$object : \\" > "$depfile"
|
||||||
|
. "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile"
|
||||||
|
echo " " >> "$depfile"
|
||||||
|
. "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile"
|
||||||
|
rm -f "$tmpdepfile"
|
||||||
|
;;
|
||||||
|
|
||||||
|
none)
|
||||||
|
exec "$@"
|
||||||
|
;;
|
||||||
|
|
||||||
|
*)
|
||||||
|
echo "Unknown depmode $depmode" 1>&2
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
|
||||||
|
# Local Variables:
|
||||||
|
# mode: shell-script
|
||||||
|
# sh-indentation: 2
|
||||||
|
# eval: (add-hook 'write-file-hooks 'time-stamp)
|
||||||
|
# time-stamp-start: "scriptversion="
|
||||||
|
# time-stamp-format: "%:y-%02m-%02d.%02H"
|
||||||
|
# time-stamp-end: "$"
|
||||||
|
# End:
|
|
@ -39,7 +39,8 @@
|
||||||
#ifndef _OPTIONS_H_
|
#ifndef _OPTIONS_H_
|
||||||
#define _OPTIONS_H_
|
#define _OPTIONS_H_
|
||||||
|
|
||||||
#include "gamesdef.h"
|
#define MAXNOC 99
|
||||||
|
#define BLITZ
|
||||||
|
|
||||||
/* #define NO_FORT_FIRE *//* Forts cannot fire */
|
/* #define NO_FORT_FIRE *//* Forts cannot fire */
|
||||||
|
|
||||||
|
|
|
@ -1 +0,0 @@
|
||||||
MakeSrcs
|
|
|
@ -1,62 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
SRCDIR = ../..
|
|
||||||
NROFF = nroff
|
|
||||||
TROFF = troff
|
|
||||||
|
|
||||||
INFOSRCS = empty
|
|
||||||
|
|
||||||
INFOOBJS = $(INFOSRCS:.t=)
|
|
||||||
|
|
||||||
HTMLOBJS = $(INFOSRCS:.t=.)
|
|
||||||
|
|
||||||
include MakeSrcs
|
|
||||||
|
|
||||||
.SUFFIXES: .t
|
|
||||||
|
|
||||||
all:
|
|
||||||
@echo INFOSRCS=`echo *.t` > MakeSrcs
|
|
||||||
@make nroffs
|
|
||||||
@echo Done.
|
|
||||||
|
|
||||||
html:
|
|
||||||
@echo INFOSRCS=`echo *.t` > MakeSrcs
|
|
||||||
@make htmlfiles
|
|
||||||
@echo Done.
|
|
||||||
|
|
||||||
htmlfiles: $(HTMLOBJS)
|
|
||||||
|
|
||||||
nroffs: $(INFOOBJS)
|
|
||||||
|
|
||||||
$(INFOOBJS):
|
|
||||||
@$(NROFF) $(SRCDIR)/info/CRT.MAC $@.t | awk -f $(SRCDIR)/info/Blank.awk > $(SRCDIR)/info.nr/$@
|
|
||||||
@echo Created $(SRCDIR)/info.nr/$@
|
|
||||||
|
|
||||||
$(HTMLOBJS):
|
|
||||||
@perl $(SRCDIR)/info/emp2html.pl $@t > $(SRCDIR)/info.html/$@html
|
|
||||||
@echo Created $(SRCDIR)/info.html/$@html
|
|
||||||
|
|
||||||
|
|
|
@ -1 +0,0 @@
|
||||||
MakeSrcs
|
|
|
@ -1,62 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
SRCDIR = ../..
|
|
||||||
NROFF = nroff
|
|
||||||
TROFF = troff
|
|
||||||
|
|
||||||
INFOSRCS = empty
|
|
||||||
|
|
||||||
INFOOBJS = $(INFOSRCS:.t=)
|
|
||||||
|
|
||||||
HTMLOBJS = $(INFOSRCS:.t=.)
|
|
||||||
|
|
||||||
include MakeSrcs
|
|
||||||
|
|
||||||
.SUFFIXES: .t
|
|
||||||
|
|
||||||
all:
|
|
||||||
@echo INFOSRCS=`echo *.t` > MakeSrcs
|
|
||||||
@make nroffs
|
|
||||||
@echo Done.
|
|
||||||
|
|
||||||
html:
|
|
||||||
@echo INFOSRCS=`echo *.t` > MakeSrcs
|
|
||||||
@make htmlfiles
|
|
||||||
@echo Done.
|
|
||||||
|
|
||||||
htmlfiles: $(HTMLOBJS)
|
|
||||||
|
|
||||||
nroffs: $(INFOOBJS)
|
|
||||||
|
|
||||||
$(INFOOBJS):
|
|
||||||
@$(NROFF) $(SRCDIR)/info/CRT.MAC $@.t | awk -f $(SRCDIR)/info/Blank.awk > $(SRCDIR)/info.nr/$@
|
|
||||||
@echo Created $(SRCDIR)/info.nr/$@
|
|
||||||
|
|
||||||
$(HTMLOBJS):
|
|
||||||
@perl $(SRCDIR)/info/emp2html.pl $@t > $(SRCDIR)/info.html/$@html
|
|
||||||
@echo Created $(SRCDIR)/info.html/$@html
|
|
||||||
|
|
||||||
|
|
|
@ -1 +0,0 @@
|
||||||
MakeSrcs
|
|
|
@ -1,62 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
SRCDIR = ../..
|
|
||||||
NROFF = nroff
|
|
||||||
TROFF = troff
|
|
||||||
|
|
||||||
INFOSRCS = empty
|
|
||||||
|
|
||||||
INFOOBJS = $(INFOSRCS:.t=)
|
|
||||||
|
|
||||||
HTMLOBJS = $(INFOSRCS:.t=.)
|
|
||||||
|
|
||||||
include MakeSrcs
|
|
||||||
|
|
||||||
.SUFFIXES: .t
|
|
||||||
|
|
||||||
all:
|
|
||||||
@echo INFOSRCS=`echo *.t` > MakeSrcs
|
|
||||||
@make nroffs
|
|
||||||
@echo Done.
|
|
||||||
|
|
||||||
html:
|
|
||||||
@echo INFOSRCS=`echo *.t` > MakeSrcs
|
|
||||||
@make htmlfiles
|
|
||||||
@echo Done.
|
|
||||||
|
|
||||||
htmlfiles: $(HTMLOBJS)
|
|
||||||
|
|
||||||
nroffs: $(INFOOBJS)
|
|
||||||
|
|
||||||
$(INFOOBJS):
|
|
||||||
@$(NROFF) $(SRCDIR)/info/CRT.MAC $@.t | awk -f $(SRCDIR)/info/Blank.awk > $(SRCDIR)/info.nr/$@
|
|
||||||
@echo Created $(SRCDIR)/info.nr/$@
|
|
||||||
|
|
||||||
$(HTMLOBJS):
|
|
||||||
@perl $(SRCDIR)/info/emp2html.pl $@t > $(SRCDIR)/info.html/$@html
|
|
||||||
@echo Created $(SRCDIR)/info.html/$@html
|
|
||||||
|
|
||||||
|
|
|
@ -1,54 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
all:
|
|
||||||
-mkdir ../info.nr
|
|
||||||
@echo "Making automated Subjects."
|
|
||||||
@echo "If this fails, you may not have perl5 installed."
|
|
||||||
-perl info.pl
|
|
||||||
@echo "Done making automated Subjects."
|
|
||||||
(cd Commands ; make)
|
|
||||||
(cd Concepts ; make)
|
|
||||||
(cd Introduction ; make)
|
|
||||||
(cd Server ; make)
|
|
||||||
(cd Subjects ; make)
|
|
||||||
-(cd ../info.nr ; ls -CF > all)
|
|
||||||
@echo Done making info files.
|
|
||||||
|
|
||||||
html:
|
|
||||||
-mkdir ../info.html
|
|
||||||
@echo "Making automated Subjects."
|
|
||||||
@echo "If this fails, you may not have perl5 installed."
|
|
||||||
-perl info.pl
|
|
||||||
@echo "Done making automated Subjects."
|
|
||||||
@echo "Building HTML info files."
|
|
||||||
(cd Commands ; make html)
|
|
||||||
(cd Concepts ; make html)
|
|
||||||
(cd Introduction ; make html)
|
|
||||||
(cd Server ; make html)
|
|
||||||
(cd Subjects ; make html)
|
|
||||||
(cp ls2html.pl ../info.html)
|
|
||||||
-(cd ../info.html ; ls -CF *.html | expand | perl ls2html.pl > all.html)
|
|
||||||
@echo Done making HTML info files.
|
|
|
@ -1 +0,0 @@
|
||||||
MakeSrcs
|
|
|
@ -1,62 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
SRCDIR = ../..
|
|
||||||
NROFF = nroff
|
|
||||||
TROFF = troff
|
|
||||||
|
|
||||||
INFOSRCS = empty
|
|
||||||
|
|
||||||
INFOOBJS = $(INFOSRCS:.t=)
|
|
||||||
|
|
||||||
HTMLOBJS = $(INFOSRCS:.t=.)
|
|
||||||
|
|
||||||
include MakeSrcs
|
|
||||||
|
|
||||||
.SUFFIXES: .t
|
|
||||||
|
|
||||||
all:
|
|
||||||
@echo INFOSRCS=`echo *.t` > MakeSrcs
|
|
||||||
@make nroffs
|
|
||||||
@echo Done.
|
|
||||||
|
|
||||||
html:
|
|
||||||
@echo INFOSRCS=`echo *.t` > MakeSrcs
|
|
||||||
@make htmlfiles
|
|
||||||
@echo Done.
|
|
||||||
|
|
||||||
htmlfiles: $(HTMLOBJS)
|
|
||||||
|
|
||||||
nroffs: $(INFOOBJS)
|
|
||||||
|
|
||||||
$(INFOOBJS):
|
|
||||||
@$(NROFF) $(SRCDIR)/info/CRT.MAC $@.t | awk -f $(SRCDIR)/info/Blank.awk > $(SRCDIR)/info.nr/$@
|
|
||||||
@echo Created $(SRCDIR)/info.nr/$@
|
|
||||||
|
|
||||||
$(HTMLOBJS):
|
|
||||||
@perl $(SRCDIR)/info/emp2html.pl $@t > $(SRCDIR)/info.html/$@html
|
|
||||||
@echo Created $(SRCDIR)/info.html/$@html
|
|
||||||
|
|
||||||
|
|
|
@ -1,2 +0,0 @@
|
||||||
*.t
|
|
||||||
MakeSrcs
|
|
|
@ -1,62 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
SRCDIR = ../..
|
|
||||||
NROFF = nroff
|
|
||||||
TROFF = troff
|
|
||||||
|
|
||||||
INFOSRCS = empty
|
|
||||||
|
|
||||||
INFOOBJS = $(INFOSRCS:.t=)
|
|
||||||
|
|
||||||
HTMLOBJS = $(INFOSRCS:.t=.)
|
|
||||||
|
|
||||||
include MakeSrcs
|
|
||||||
|
|
||||||
.SUFFIXES: .t
|
|
||||||
|
|
||||||
all:
|
|
||||||
@echo INFOSRCS=`echo *.t` > MakeSrcs
|
|
||||||
@make nroffs
|
|
||||||
@echo Done.
|
|
||||||
|
|
||||||
html:
|
|
||||||
@echo INFOSRCS=`echo *.t` > MakeSrcs
|
|
||||||
@make htmlfiles
|
|
||||||
@echo Done.
|
|
||||||
|
|
||||||
htmlfiles: $(HTMLOBJS)
|
|
||||||
|
|
||||||
nroffs: $(INFOOBJS)
|
|
||||||
|
|
||||||
$(INFOOBJS):
|
|
||||||
@$(NROFF) $(SRCDIR)/info/CRT.MAC $@.t | awk -f $(SRCDIR)/info/Blank.awk > $(SRCDIR)/info.nr/$@
|
|
||||||
@echo Created $(SRCDIR)/info.nr/$@
|
|
||||||
|
|
||||||
$(HTMLOBJS):
|
|
||||||
@perl $(SRCDIR)/info/subj2html.pl $@t > $(SRCDIR)/info.html/$@html
|
|
||||||
@echo Created $(SRCDIR)/info.html/$@html
|
|
||||||
|
|
||||||
|
|
323
install-sh
Executable file
323
install-sh
Executable file
|
@ -0,0 +1,323 @@
|
||||||
|
#!/bin/sh
|
||||||
|
# install - install a program, script, or datafile
|
||||||
|
|
||||||
|
scriptversion=2005-02-02.21
|
||||||
|
|
||||||
|
# This originates from X11R5 (mit/util/scripts/install.sh), which was
|
||||||
|
# later released in X11R6 (xc/config/util/install.sh) with the
|
||||||
|
# following copyright and license.
|
||||||
|
#
|
||||||
|
# Copyright (C) 1994 X Consortium
|
||||||
|
#
|
||||||
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
# of this software and associated documentation files (the "Software"), to
|
||||||
|
# deal in the Software without restriction, including without limitation the
|
||||||
|
# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
|
||||||
|
# sell copies of the Software, and to permit persons to whom the Software is
|
||||||
|
# furnished to do so, subject to the following conditions:
|
||||||
|
#
|
||||||
|
# The above copyright notice and this permission notice shall be included in
|
||||||
|
# all copies or substantial portions of the Software.
|
||||||
|
#
|
||||||
|
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
|
||||||
|
# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC-
|
||||||
|
# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
|
#
|
||||||
|
# Except as contained in this notice, the name of the X Consortium shall not
|
||||||
|
# be used in advertising or otherwise to promote the sale, use or other deal-
|
||||||
|
# ings in this Software without prior written authorization from the X Consor-
|
||||||
|
# tium.
|
||||||
|
#
|
||||||
|
#
|
||||||
|
# FSF changes to this file are in the public domain.
|
||||||
|
#
|
||||||
|
# Calling this script install-sh is preferred over install.sh, to prevent
|
||||||
|
# `make' implicit rules from creating a file called install from it
|
||||||
|
# when there is no Makefile.
|
||||||
|
#
|
||||||
|
# This script is compatible with the BSD install script, but was written
|
||||||
|
# from scratch. It can only install one file at a time, a restriction
|
||||||
|
# shared with many OS's install programs.
|
||||||
|
|
||||||
|
# set DOITPROG to echo to test this script
|
||||||
|
|
||||||
|
# Don't use :- since 4.3BSD and earlier shells don't like it.
|
||||||
|
doit="${DOITPROG-}"
|
||||||
|
|
||||||
|
# put in absolute paths if you don't have them in your path; or use env. vars.
|
||||||
|
|
||||||
|
mvprog="${MVPROG-mv}"
|
||||||
|
cpprog="${CPPROG-cp}"
|
||||||
|
chmodprog="${CHMODPROG-chmod}"
|
||||||
|
chownprog="${CHOWNPROG-chown}"
|
||||||
|
chgrpprog="${CHGRPPROG-chgrp}"
|
||||||
|
stripprog="${STRIPPROG-strip}"
|
||||||
|
rmprog="${RMPROG-rm}"
|
||||||
|
mkdirprog="${MKDIRPROG-mkdir}"
|
||||||
|
|
||||||
|
chmodcmd="$chmodprog 0755"
|
||||||
|
chowncmd=
|
||||||
|
chgrpcmd=
|
||||||
|
stripcmd=
|
||||||
|
rmcmd="$rmprog -f"
|
||||||
|
mvcmd="$mvprog"
|
||||||
|
src=
|
||||||
|
dst=
|
||||||
|
dir_arg=
|
||||||
|
dstarg=
|
||||||
|
no_target_directory=
|
||||||
|
|
||||||
|
usage="Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE
|
||||||
|
or: $0 [OPTION]... SRCFILES... DIRECTORY
|
||||||
|
or: $0 [OPTION]... -t DIRECTORY SRCFILES...
|
||||||
|
or: $0 [OPTION]... -d DIRECTORIES...
|
||||||
|
|
||||||
|
In the 1st form, copy SRCFILE to DSTFILE.
|
||||||
|
In the 2nd and 3rd, copy all SRCFILES to DIRECTORY.
|
||||||
|
In the 4th, create DIRECTORIES.
|
||||||
|
|
||||||
|
Options:
|
||||||
|
-c (ignored)
|
||||||
|
-d create directories instead of installing files.
|
||||||
|
-g GROUP $chgrpprog installed files to GROUP.
|
||||||
|
-m MODE $chmodprog installed files to MODE.
|
||||||
|
-o USER $chownprog installed files to USER.
|
||||||
|
-s $stripprog installed files.
|
||||||
|
-t DIRECTORY install into DIRECTORY.
|
||||||
|
-T report an error if DSTFILE is a directory.
|
||||||
|
--help display this help and exit.
|
||||||
|
--version display version info and exit.
|
||||||
|
|
||||||
|
Environment variables override the default commands:
|
||||||
|
CHGRPPROG CHMODPROG CHOWNPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG
|
||||||
|
"
|
||||||
|
|
||||||
|
while test -n "$1"; do
|
||||||
|
case $1 in
|
||||||
|
-c) shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
-d) dir_arg=true
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
-g) chgrpcmd="$chgrpprog $2"
|
||||||
|
shift
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
--help) echo "$usage"; exit $?;;
|
||||||
|
|
||||||
|
-m) chmodcmd="$chmodprog $2"
|
||||||
|
shift
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
-o) chowncmd="$chownprog $2"
|
||||||
|
shift
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
-s) stripcmd=$stripprog
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
-t) dstarg=$2
|
||||||
|
shift
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
-T) no_target_directory=true
|
||||||
|
shift
|
||||||
|
continue;;
|
||||||
|
|
||||||
|
--version) echo "$0 $scriptversion"; exit $?;;
|
||||||
|
|
||||||
|
*) # When -d is used, all remaining arguments are directories to create.
|
||||||
|
# When -t is used, the destination is already specified.
|
||||||
|
test -n "$dir_arg$dstarg" && break
|
||||||
|
# Otherwise, the last argument is the destination. Remove it from $@.
|
||||||
|
for arg
|
||||||
|
do
|
||||||
|
if test -n "$dstarg"; then
|
||||||
|
# $@ is not empty: it contains at least $arg.
|
||||||
|
set fnord "$@" "$dstarg"
|
||||||
|
shift # fnord
|
||||||
|
fi
|
||||||
|
shift # arg
|
||||||
|
dstarg=$arg
|
||||||
|
done
|
||||||
|
break;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
if test -z "$1"; then
|
||||||
|
if test -z "$dir_arg"; then
|
||||||
|
echo "$0: no input file specified." >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
# It's OK to call `install-sh -d' without argument.
|
||||||
|
# This can happen when creating conditional directories.
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
for src
|
||||||
|
do
|
||||||
|
# Protect names starting with `-'.
|
||||||
|
case $src in
|
||||||
|
-*) src=./$src ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if test -n "$dir_arg"; then
|
||||||
|
dst=$src
|
||||||
|
src=
|
||||||
|
|
||||||
|
if test -d "$dst"; then
|
||||||
|
mkdircmd=:
|
||||||
|
chmodcmd=
|
||||||
|
else
|
||||||
|
mkdircmd=$mkdirprog
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
# Waiting for this to be detected by the "$cpprog $src $dsttmp" command
|
||||||
|
# might cause directories to be created, which would be especially bad
|
||||||
|
# if $src (and thus $dsttmp) contains '*'.
|
||||||
|
if test ! -f "$src" && test ! -d "$src"; then
|
||||||
|
echo "$0: $src does not exist." >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test -z "$dstarg"; then
|
||||||
|
echo "$0: no destination specified." >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
dst=$dstarg
|
||||||
|
# Protect names starting with `-'.
|
||||||
|
case $dst in
|
||||||
|
-*) dst=./$dst ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
# If destination is a directory, append the input filename; won't work
|
||||||
|
# if double slashes aren't ignored.
|
||||||
|
if test -d "$dst"; then
|
||||||
|
if test -n "$no_target_directory"; then
|
||||||
|
echo "$0: $dstarg: Is a directory" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
dst=$dst/`basename "$src"`
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
# This sed command emulates the dirname command.
|
||||||
|
dstdir=`echo "$dst" | sed -e 's,/*$,,;s,[^/]*$,,;s,/*$,,;s,^$,.,'`
|
||||||
|
|
||||||
|
# Make sure that the destination directory exists.
|
||||||
|
|
||||||
|
# Skip lots of stat calls in the usual case.
|
||||||
|
if test ! -d "$dstdir"; then
|
||||||
|
defaultIFS='
|
||||||
|
'
|
||||||
|
IFS="${IFS-$defaultIFS}"
|
||||||
|
|
||||||
|
oIFS=$IFS
|
||||||
|
# Some sh's can't handle IFS=/ for some reason.
|
||||||
|
IFS='%'
|
||||||
|
set x `echo "$dstdir" | sed -e 's@/@%@g' -e 's@^%@/@'`
|
||||||
|
shift
|
||||||
|
IFS=$oIFS
|
||||||
|
|
||||||
|
pathcomp=
|
||||||
|
|
||||||
|
while test $# -ne 0 ; do
|
||||||
|
pathcomp=$pathcomp$1
|
||||||
|
shift
|
||||||
|
if test ! -d "$pathcomp"; then
|
||||||
|
$mkdirprog "$pathcomp"
|
||||||
|
# mkdir can fail with a `File exist' error in case several
|
||||||
|
# install-sh are creating the directory concurrently. This
|
||||||
|
# is OK.
|
||||||
|
test -d "$pathcomp" || exit
|
||||||
|
fi
|
||||||
|
pathcomp=$pathcomp/
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test -n "$dir_arg"; then
|
||||||
|
$doit $mkdircmd "$dst" \
|
||||||
|
&& { test -z "$chowncmd" || $doit $chowncmd "$dst"; } \
|
||||||
|
&& { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } \
|
||||||
|
&& { test -z "$stripcmd" || $doit $stripcmd "$dst"; } \
|
||||||
|
&& { test -z "$chmodcmd" || $doit $chmodcmd "$dst"; }
|
||||||
|
|
||||||
|
else
|
||||||
|
dstfile=`basename "$dst"`
|
||||||
|
|
||||||
|
# Make a couple of temp file names in the proper directory.
|
||||||
|
dsttmp=$dstdir/_inst.$$_
|
||||||
|
rmtmp=$dstdir/_rm.$$_
|
||||||
|
|
||||||
|
# Trap to clean up those temp files at exit.
|
||||||
|
trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0
|
||||||
|
trap '(exit $?); exit' 1 2 13 15
|
||||||
|
|
||||||
|
# Copy the file name to the temp name.
|
||||||
|
$doit $cpprog "$src" "$dsttmp" &&
|
||||||
|
|
||||||
|
# and set any options; do chmod last to preserve setuid bits.
|
||||||
|
#
|
||||||
|
# If any of these fail, we abort the whole thing. If we want to
|
||||||
|
# ignore errors from any of these, just make sure not to ignore
|
||||||
|
# errors from the above "$doit $cpprog $src $dsttmp" command.
|
||||||
|
#
|
||||||
|
{ test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } \
|
||||||
|
&& { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } \
|
||||||
|
&& { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } \
|
||||||
|
&& { test -z "$chmodcmd" || $doit $chmodcmd "$dsttmp"; } &&
|
||||||
|
|
||||||
|
# Now rename the file to the real destination.
|
||||||
|
{ $doit $mvcmd -f "$dsttmp" "$dstdir/$dstfile" 2>/dev/null \
|
||||||
|
|| {
|
||||||
|
# The rename failed, perhaps because mv can't rename something else
|
||||||
|
# to itself, or perhaps because mv is so ancient that it does not
|
||||||
|
# support -f.
|
||||||
|
|
||||||
|
# Now remove or move aside any old file at destination location.
|
||||||
|
# We try this two ways since rm can't unlink itself on some
|
||||||
|
# systems and the destination file might be busy for other
|
||||||
|
# reasons. In this case, the final cleanup might fail but the new
|
||||||
|
# file should still install successfully.
|
||||||
|
{
|
||||||
|
if test -f "$dstdir/$dstfile"; then
|
||||||
|
$doit $rmcmd -f "$dstdir/$dstfile" 2>/dev/null \
|
||||||
|
|| $doit $mvcmd -f "$dstdir/$dstfile" "$rmtmp" 2>/dev/null \
|
||||||
|
|| {
|
||||||
|
echo "$0: cannot unlink or rename $dstdir/$dstfile" >&2
|
||||||
|
(exit 1); exit 1
|
||||||
|
}
|
||||||
|
else
|
||||||
|
:
|
||||||
|
fi
|
||||||
|
} &&
|
||||||
|
|
||||||
|
# Now rename the file to the real destination.
|
||||||
|
$doit $mvcmd "$dsttmp" "$dstdir/$dstfile"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
fi || { (exit 1); exit 1; }
|
||||||
|
done
|
||||||
|
|
||||||
|
# The final little trick to "correctly" pass the exit status to the exit trap.
|
||||||
|
{
|
||||||
|
(exit 0); exit 0
|
||||||
|
}
|
||||||
|
|
||||||
|
# Local variables:
|
||||||
|
# eval: (add-hook 'write-file-hooks 'time-stamp)
|
||||||
|
# time-stamp-start: "scriptversion="
|
||||||
|
# time-stamp-format: "%:y-%02m-%02d.%02H"
|
||||||
|
# time-stamp-end: "$"
|
||||||
|
# End:
|
238
m4/acx_pthread.m4
Normal file
238
m4/acx_pthread.m4
Normal file
|
@ -0,0 +1,238 @@
|
||||||
|
dnl @synopsis ACX_PTHREAD([ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
|
||||||
|
dnl
|
||||||
|
dnl @summary figure out how to build C programs using POSIX threads
|
||||||
|
dnl
|
||||||
|
dnl This macro figures out how to build C programs using POSIX threads.
|
||||||
|
dnl It sets the PTHREAD_LIBS output variable to the threads library and
|
||||||
|
dnl linker flags, and the PTHREAD_CFLAGS output variable to any special
|
||||||
|
dnl C compiler flags that are needed. (The user can also force certain
|
||||||
|
dnl compiler flags/libs to be tested by setting these environment
|
||||||
|
dnl variables.)
|
||||||
|
dnl
|
||||||
|
dnl Also sets PTHREAD_CC to any special C compiler that is needed for
|
||||||
|
dnl multi-threaded programs (defaults to the value of CC otherwise).
|
||||||
|
dnl (This is necessary on AIX to use the special cc_r compiler alias.)
|
||||||
|
dnl
|
||||||
|
dnl NOTE: You are assumed to not only compile your program with these
|
||||||
|
dnl flags, but also link it with them as well. e.g. you should link
|
||||||
|
dnl with $PTHREAD_CC $CFLAGS $PTHREAD_CFLAGS $LDFLAGS ... $PTHREAD_LIBS
|
||||||
|
dnl $LIBS
|
||||||
|
dnl
|
||||||
|
dnl If you are only building threads programs, you may wish to use
|
||||||
|
dnl these variables in your default LIBS, CFLAGS, and CC:
|
||||||
|
dnl
|
||||||
|
dnl LIBS="$PTHREAD_LIBS $LIBS"
|
||||||
|
dnl CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
|
||||||
|
dnl CC="$PTHREAD_CC"
|
||||||
|
dnl
|
||||||
|
dnl In addition, if the PTHREAD_CREATE_JOINABLE thread-attribute
|
||||||
|
dnl constant has a nonstandard name, defines PTHREAD_CREATE_JOINABLE to
|
||||||
|
dnl that name (e.g. PTHREAD_CREATE_UNDETACHED on AIX).
|
||||||
|
dnl
|
||||||
|
dnl ACTION-IF-FOUND is a list of shell commands to run if a threads
|
||||||
|
dnl library is found, and ACTION-IF-NOT-FOUND is a list of commands to
|
||||||
|
dnl run it if it is not found. If ACTION-IF-FOUND is not specified, the
|
||||||
|
dnl default action will define HAVE_PTHREAD.
|
||||||
|
dnl
|
||||||
|
dnl Please let the authors know if this macro fails on any platform, or
|
||||||
|
dnl if you have any other suggestions or comments. This macro was based
|
||||||
|
dnl on work by SGJ on autoconf scripts for FFTW (www.fftw.org) (with
|
||||||
|
dnl help from M. Frigo), as well as ac_pthread and hb_pthread macros
|
||||||
|
dnl posted by Alejandro Forero Cuervo to the autoconf macro repository.
|
||||||
|
dnl We are also grateful for the helpful feedback of numerous users.
|
||||||
|
dnl
|
||||||
|
dnl @category InstalledPackages
|
||||||
|
dnl @author Steven G. Johnson <stevenj@alum.mit.edu>
|
||||||
|
dnl @version 2005-06-15
|
||||||
|
dnl @license GPLWithACException
|
||||||
|
|
||||||
|
AC_DEFUN([ACX_PTHREAD], [
|
||||||
|
AC_REQUIRE([AC_CANONICAL_HOST])
|
||||||
|
AC_LANG_SAVE
|
||||||
|
AC_LANG_C
|
||||||
|
acx_pthread_ok=no
|
||||||
|
|
||||||
|
# We used to check for pthread.h first, but this fails if pthread.h
|
||||||
|
# requires special compiler flags (e.g. on True64 or Sequent).
|
||||||
|
# It gets checked for in the link test anyway.
|
||||||
|
|
||||||
|
# First of all, check if the user has set any of the PTHREAD_LIBS,
|
||||||
|
# etcetera environment variables, and if threads linking works using
|
||||||
|
# them:
|
||||||
|
if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
|
||||||
|
save_CFLAGS="$CFLAGS"
|
||||||
|
CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
|
||||||
|
save_LIBS="$LIBS"
|
||||||
|
LIBS="$PTHREAD_LIBS $LIBS"
|
||||||
|
AC_MSG_CHECKING([for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS])
|
||||||
|
AC_TRY_LINK_FUNC(pthread_join, acx_pthread_ok=yes)
|
||||||
|
AC_MSG_RESULT($acx_pthread_ok)
|
||||||
|
if test x"$acx_pthread_ok" = xno; then
|
||||||
|
PTHREAD_LIBS=""
|
||||||
|
PTHREAD_CFLAGS=""
|
||||||
|
fi
|
||||||
|
LIBS="$save_LIBS"
|
||||||
|
CFLAGS="$save_CFLAGS"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# We must check for the threads library under a number of different
|
||||||
|
# names; the ordering is very important because some systems
|
||||||
|
# (e.g. DEC) have both -lpthread and -lpthreads, where one of the
|
||||||
|
# libraries is broken (non-POSIX).
|
||||||
|
|
||||||
|
# Create a list of thread flags to try. Items starting with a "-" are
|
||||||
|
# C compiler flags, and other items are library names, except for "none"
|
||||||
|
# which indicates that we try without any flags at all, and "pthread-config"
|
||||||
|
# which is a program returning the flags for the Pth emulation library.
|
||||||
|
|
||||||
|
acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
|
||||||
|
|
||||||
|
# The ordering *is* (sometimes) important. Some notes on the
|
||||||
|
# individual items follow:
|
||||||
|
|
||||||
|
# pthreads: AIX (must check this before -lpthread)
|
||||||
|
# none: in case threads are in libc; should be tried before -Kthread and
|
||||||
|
# other compiler flags to prevent continual compiler warnings
|
||||||
|
# -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
|
||||||
|
# -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
|
||||||
|
# lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
|
||||||
|
# -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
|
||||||
|
# -pthreads: Solaris/gcc
|
||||||
|
# -mthreads: Mingw32/gcc, Lynx/gcc
|
||||||
|
# -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
|
||||||
|
# doesn't hurt to check since this sometimes defines pthreads too;
|
||||||
|
# also defines -D_REENTRANT)
|
||||||
|
# ... -mt is also the pthreads flag for HP/aCC
|
||||||
|
# pthread: Linux, etcetera
|
||||||
|
# --thread-safe: KAI C++
|
||||||
|
# pthread-config: use pthread-config program (for GNU Pth library)
|
||||||
|
|
||||||
|
case "${host_cpu}-${host_os}" in
|
||||||
|
*solaris*)
|
||||||
|
|
||||||
|
# On Solaris (at least, for some versions), libc contains stubbed
|
||||||
|
# (non-functional) versions of the pthreads routines, so link-based
|
||||||
|
# tests will erroneously succeed. (We need to link with -pthreads/-mt/
|
||||||
|
# -lpthread.) (The stubs are missing pthread_cleanup_push, or rather
|
||||||
|
# a function called by this macro, so we could check for that, but
|
||||||
|
# who knows whether they'll stub that too in a future libc.) So,
|
||||||
|
# we'll just look for -pthreads and -lpthread first:
|
||||||
|
|
||||||
|
acx_pthread_flags="-pthreads pthread -mt -pthread $acx_pthread_flags"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if test x"$acx_pthread_ok" = xno; then
|
||||||
|
for flag in $acx_pthread_flags; do
|
||||||
|
|
||||||
|
case $flag in
|
||||||
|
none)
|
||||||
|
AC_MSG_CHECKING([whether pthreads work without any flags])
|
||||||
|
;;
|
||||||
|
|
||||||
|
-*)
|
||||||
|
AC_MSG_CHECKING([whether pthreads work with $flag])
|
||||||
|
PTHREAD_CFLAGS="$flag"
|
||||||
|
;;
|
||||||
|
|
||||||
|
pthread-config)
|
||||||
|
AC_CHECK_PROG(acx_pthread_config, pthread-config, yes, no)
|
||||||
|
if test x"$acx_pthread_config" = xno; then continue; fi
|
||||||
|
PTHREAD_CFLAGS="`pthread-config --cflags`"
|
||||||
|
PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
|
||||||
|
;;
|
||||||
|
|
||||||
|
*)
|
||||||
|
AC_MSG_CHECKING([for the pthreads library -l$flag])
|
||||||
|
PTHREAD_LIBS="-l$flag"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
save_LIBS="$LIBS"
|
||||||
|
save_CFLAGS="$CFLAGS"
|
||||||
|
LIBS="$PTHREAD_LIBS $LIBS"
|
||||||
|
CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
|
||||||
|
|
||||||
|
# Check for various functions. We must include pthread.h,
|
||||||
|
# since some functions may be macros. (On the Sequent, we
|
||||||
|
# need a special flag -Kthread to make this header compile.)
|
||||||
|
# We check for pthread_join because it is in -lpthread on IRIX
|
||||||
|
# while pthread_create is in libc. We check for pthread_attr_init
|
||||||
|
# due to DEC craziness with -lpthreads. We check for
|
||||||
|
# pthread_cleanup_push because it is one of the few pthread
|
||||||
|
# functions on Solaris that doesn't have a non-functional libc stub.
|
||||||
|
# We try pthread_create on general principles.
|
||||||
|
AC_TRY_LINK([#include <pthread.h>],
|
||||||
|
[pthread_t th; pthread_join(th, 0);
|
||||||
|
pthread_attr_init(0); pthread_cleanup_push(0, 0);
|
||||||
|
pthread_create(0,0,0,0); pthread_cleanup_pop(0); ],
|
||||||
|
[acx_pthread_ok=yes])
|
||||||
|
|
||||||
|
LIBS="$save_LIBS"
|
||||||
|
CFLAGS="$save_CFLAGS"
|
||||||
|
|
||||||
|
AC_MSG_RESULT($acx_pthread_ok)
|
||||||
|
if test "x$acx_pthread_ok" = xyes; then
|
||||||
|
break;
|
||||||
|
fi
|
||||||
|
|
||||||
|
PTHREAD_LIBS=""
|
||||||
|
PTHREAD_CFLAGS=""
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Various other checks:
|
||||||
|
if test "x$acx_pthread_ok" = xyes; then
|
||||||
|
save_LIBS="$LIBS"
|
||||||
|
LIBS="$PTHREAD_LIBS $LIBS"
|
||||||
|
save_CFLAGS="$CFLAGS"
|
||||||
|
CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
|
||||||
|
|
||||||
|
# Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
|
||||||
|
AC_MSG_CHECKING([for joinable pthread attribute])
|
||||||
|
attr_name=unknown
|
||||||
|
for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
|
||||||
|
AC_TRY_LINK([#include <pthread.h>], [int attr=$attr; return attr;],
|
||||||
|
[attr_name=$attr; break])
|
||||||
|
done
|
||||||
|
AC_MSG_RESULT($attr_name)
|
||||||
|
if test "$attr_name" != PTHREAD_CREATE_JOINABLE; then
|
||||||
|
AC_DEFINE_UNQUOTED(PTHREAD_CREATE_JOINABLE, $attr_name,
|
||||||
|
[Define to necessary symbol if this constant
|
||||||
|
uses a non-standard name on your system.])
|
||||||
|
fi
|
||||||
|
|
||||||
|
AC_MSG_CHECKING([if more special flags are required for pthreads])
|
||||||
|
flag=no
|
||||||
|
case "${host_cpu}-${host_os}" in
|
||||||
|
*-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
|
||||||
|
*solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
|
||||||
|
esac
|
||||||
|
AC_MSG_RESULT(${flag})
|
||||||
|
if test "x$flag" != xno; then
|
||||||
|
PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
|
||||||
|
fi
|
||||||
|
|
||||||
|
LIBS="$save_LIBS"
|
||||||
|
CFLAGS="$save_CFLAGS"
|
||||||
|
|
||||||
|
# More AIX lossage: must compile with cc_r
|
||||||
|
AC_CHECK_PROG(PTHREAD_CC, cc_r, cc_r, ${CC})
|
||||||
|
else
|
||||||
|
PTHREAD_CC="$CC"
|
||||||
|
fi
|
||||||
|
|
||||||
|
AC_SUBST(PTHREAD_LIBS)
|
||||||
|
AC_SUBST(PTHREAD_CFLAGS)
|
||||||
|
AC_SUBST(PTHREAD_CC)
|
||||||
|
|
||||||
|
# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
|
||||||
|
if test x"$acx_pthread_ok" = xyes; then
|
||||||
|
ifelse([$1],,AC_DEFINE(HAVE_PTHREAD,1,[Define if you have POSIX threads libraries and header files.]),[$1])
|
||||||
|
:
|
||||||
|
else
|
||||||
|
acx_pthread_ok=no
|
||||||
|
$2
|
||||||
|
fi
|
||||||
|
AC_LANG_RESTORE
|
||||||
|
])dnl ACX_PTHREAD
|
24
m4/lib_socket_nsl.m4
Normal file
24
m4/lib_socket_nsl.m4
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
dnl @synopsis LIB_SOCKET_NSL
|
||||||
|
dnl
|
||||||
|
dnl This macro figures out what libraries are required on this platform
|
||||||
|
dnl to link sockets programs.
|
||||||
|
dnl
|
||||||
|
dnl The common cases are not to need any extra libraries, or to need
|
||||||
|
dnl -lsocket and -lnsl. We need to avoid linking with libnsl unless we
|
||||||
|
dnl need it, though, since on some OSes where it isn't necessary it
|
||||||
|
dnl will totally break networking. Unisys also includes gethostbyname()
|
||||||
|
dnl in libsocket but needs libnsl for socket().
|
||||||
|
dnl
|
||||||
|
dnl @category Misc
|
||||||
|
dnl @author Russ Allbery <rra@stanford.edu>
|
||||||
|
dnl @author Stepan Kasal <kasal@ucw.cz>
|
||||||
|
dnl @author Warren Young <warren@etr-usa.com>
|
||||||
|
dnl @version 2005-09-06
|
||||||
|
|
||||||
|
AC_DEFUN([LIB_SOCKET_NSL],
|
||||||
|
[
|
||||||
|
AC_SEARCH_LIBS([gethostbyname], [nsl])
|
||||||
|
AC_SEARCH_LIBS([socket], [socket], [], [
|
||||||
|
AC_CHECK_LIB([socket], [socket], [LIBS="-lsocket -lnsl $LIBS"],
|
||||||
|
[], [-lnsl])])
|
||||||
|
])
|
11
m4/my_func_makecontext.m4
Normal file
11
m4/my_func_makecontext.m4
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
AC_DEFUN([MY_FUNC_MAKECONTEXT],
|
||||||
|
[
|
||||||
|
AC_REQUIRE([AC_CANONICAL_HOST])
|
||||||
|
AC_CHECK_FUNCS(makecontext)
|
||||||
|
case "$host_os" in
|
||||||
|
*irix*|*solaris2.?)
|
||||||
|
AC_DEFINE([MAKECONTEXT_SP_HIGH], 1,
|
||||||
|
[Define if your makecontext() requires ss_sp at the top of the stack])
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
])
|
|
@ -1 +0,0 @@
|
||||||
make.src
|
|
|
@ -1,3 +1,2 @@
|
||||||
Makedepend
|
empire
|
||||||
emp_client
|
|
||||||
ipglob.c
|
ipglob.c
|
||||||
|
|
|
@ -1,90 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
#
|
|
||||||
# Empire front end Makefile
|
|
||||||
# (server mode)
|
|
||||||
#
|
|
||||||
|
|
||||||
include ../../build.conf
|
|
||||||
include ../make.src
|
|
||||||
include ../make.defs
|
|
||||||
|
|
||||||
CFILES = expect.c handle.c host.c \
|
|
||||||
ioqueue.c ipglob.c login.c main.c queue.c saveargv.c \
|
|
||||||
servcmd.c serverio.c tags.c termio.c termlib.c
|
|
||||||
OFILES = expect.o handle.o host.o \
|
|
||||||
ioqueue.o ipglob.o login.o main.o queue.o saveargv.o \
|
|
||||||
servcmd.o serverio.o tags.o termio.o termlib.o
|
|
||||||
OBJFILES = expect.obj handle.obj host.obj \
|
|
||||||
ioqueue.obj ipglob.obj login.obj main.obj queue.obj saveargv.obj \
|
|
||||||
servcmd.obj serverio.obj tags.obj termio.obj termlib.obj
|
|
||||||
|
|
||||||
CLIENTLIBS= -ltermlib
|
|
||||||
|
|
||||||
#
|
|
||||||
# Change this line to the compiler you are going to use.
|
|
||||||
#
|
|
||||||
|
|
||||||
all: emp_client
|
|
||||||
|
|
||||||
osx: emp_client
|
|
||||||
|
|
||||||
emp_client: $(OFILES)
|
|
||||||
$(CC) -o emp_client $(OFILES) $(LFLAGS) $(CLIENTLIBS) -lc
|
|
||||||
|
|
||||||
nt: emp_client.exe
|
|
||||||
|
|
||||||
emp_client.exe: $(OBJFILES) $(CFILES)
|
|
||||||
cl $(CFLAGS) /Feemp_client.exe $(OBJFILES) wsock32.lib advapi32.lib
|
|
||||||
|
|
||||||
dgux: $(OFILES)
|
|
||||||
$(CC) $(CFLAGS) -dn -o emp_client $(OFILES) -lsocket -lnsl -ltermcap -lc
|
|
||||||
|
|
||||||
solaris:
|
|
||||||
$(MAKE) emp_client CLIENTLIBS="-lsocket -lnsl -ltermcap -lc"
|
|
||||||
|
|
||||||
hpux:
|
|
||||||
$(MAKE) emp_client CLIENTLIBS=-ltermcap
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f $(OFILES))
|
|
||||||
-(rm -f emp_client)
|
|
||||||
-(del /q $(OBJFILES))
|
|
||||||
-(del /q emp_client.exe)
|
|
||||||
-(del /q emp_client.ilk)
|
|
||||||
-(del /q emp_client.pdb)
|
|
||||||
|
|
||||||
install:
|
|
||||||
-(mkdir $(EMPDIR)/bin)
|
|
||||||
cp emp_client $(EMPDIR)/bin
|
|
||||||
|
|
||||||
ntinstall:
|
|
||||||
-(mkdir $(NTINSTDIR)\bin)
|
|
||||||
copy emp_client.exe $(NTINSTDIR)\bin
|
|
||||||
|
|
||||||
include ../make.rules
|
|
||||||
include Makedepend
|
|
||||||
|
|
|
@ -1,85 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
#
|
|
||||||
# Empire front end Makefile
|
|
||||||
# (standalone mode)
|
|
||||||
#
|
|
||||||
|
|
||||||
CFILES = expect.c handle.c host.c \
|
|
||||||
ioqueue.c ipglob.c login.c main.c queue.c saveargv.c \
|
|
||||||
servcmd.c serverio.c tags.c termio.c termlib.c
|
|
||||||
OFILES = expect.o handle.o host.o \
|
|
||||||
ioqueue.o ipglob.o login.o main.o queue.o saveargv.o \
|
|
||||||
servcmd.o serverio.o tags.o termio.o termlib.o
|
|
||||||
OBJFILES = expect.obj handle.obj host.obj \
|
|
||||||
ioqueue.obj ipglob.obj login.obj main.obj queue.obj saveargv.obj \
|
|
||||||
servcmd.obj serverio.obj tags.obj termio.obj termlib.obj
|
|
||||||
|
|
||||||
CFLAGS= -g
|
|
||||||
LIBS= -ltermlib
|
|
||||||
|
|
||||||
#
|
|
||||||
# Change this line to the compiler you are going to use.
|
|
||||||
#
|
|
||||||
CC=cc
|
|
||||||
|
|
||||||
empire: $(OFILES)
|
|
||||||
$(CC) -o empire $(OFILES) $(LIBS)
|
|
||||||
|
|
||||||
linux: $(OFILES)
|
|
||||||
$(CC) -o empire $(OFILES) -lcurses
|
|
||||||
|
|
||||||
nt:
|
|
||||||
cl /DWIN32 /Feempire.exe $(CFILES) wsock32.lib advapi32.lib
|
|
||||||
|
|
||||||
dgux: $(OFILES)
|
|
||||||
$(CC) $(CFLAGS) -dn -o empire $(OFILES) -lsocket -lnsl -ltermcap -lc
|
|
||||||
|
|
||||||
solaris:
|
|
||||||
make empire LIBS="-lsocket -lnsl -ltermcap -lc"
|
|
||||||
|
|
||||||
hpux:
|
|
||||||
make empire LIBS=-ltermcap
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f $(OFILES) empire)
|
|
||||||
-(del /q $(OBJFILES))
|
|
||||||
-(del /q empire.exe)
|
|
||||||
|
|
||||||
expect.o: misc.h
|
|
||||||
handle.o: misc.h
|
|
||||||
host.o: misc.h
|
|
||||||
ioqueue.o: misc.h queue.h ioqueue.h
|
|
||||||
ipglob.o: misc.h
|
|
||||||
login.o: misc.h proto.h
|
|
||||||
main.o: misc.h proto.h queue.h ioqueue.h tags.h
|
|
||||||
queue.o: misc.h queue.h
|
|
||||||
saveargv.o: misc.h
|
|
||||||
servcmd.o: misc.h proto.h queue.h ioqueue.h tags.h
|
|
||||||
serverio.o: misc.h queue.h ioqueue.h
|
|
||||||
tags.o: misc.h tags.h
|
|
||||||
termio.o: misc.h tags.h
|
|
||||||
termlib.o: misc.h
|
|
36
src/client/ipglob.c.in
Normal file
36
src/client/ipglob.c.in
Normal file
|
@ -0,0 +1,36 @@
|
||||||
|
/*
|
||||||
|
* Empire - A multi-player, client/server Internet based war game.
|
||||||
|
* Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
||||||
|
* Ken Stevens, Steve McClure
|
||||||
|
*
|
||||||
|
* This program 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.
|
||||||
|
*
|
||||||
|
* This program 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.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
|
*
|
||||||
|
* ---
|
||||||
|
*
|
||||||
|
* See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
||||||
|
* related information and legal notices. It is expected that any future
|
||||||
|
* projects/authors will amend these files as needed.
|
||||||
|
*
|
||||||
|
* ---
|
||||||
|
*
|
||||||
|
* @configure_input@
|
||||||
|
* ipglob.c.in: IP globals.
|
||||||
|
*
|
||||||
|
* Known contributors to this file:
|
||||||
|
* Markus Armbruster, 2005
|
||||||
|
*/
|
||||||
|
|
||||||
|
char empirehost[] = "@EMPIREHOST@";
|
||||||
|
char empireport[] = "@EMPIREPORT@";
|
|
@ -1,2 +0,0 @@
|
||||||
Makedepend
|
|
||||||
doconfig
|
|
|
@ -1,73 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
# build the configuration program, then run it.
|
|
||||||
# Note that this is a stand-alone - it doesn't need anything
|
|
||||||
# else to build and run, other than build.conf for definitions.
|
|
||||||
|
|
||||||
|
|
||||||
include ../../build.conf
|
|
||||||
|
|
||||||
DPV = -DPV="\"$(MYNAME)\""
|
|
||||||
DHN = -DHN="\"$(HOSTNAME)\""
|
|
||||||
DPN = -DPN=$(PORTNUM)
|
|
||||||
DEM = -DEM="\"$(EMAIL)\""
|
|
||||||
DEP = -DEP="\"$(EMPDIR)\""
|
|
||||||
DMC = -DMC=$(MAXNOC)
|
|
||||||
DWX = -DWX=$(WORLDX)
|
|
||||||
DWY = -DWY=$(WORLDY)
|
|
||||||
DBL = -DBL=$(BLITZ)
|
|
||||||
DET = -DET=$(ETUS)
|
|
||||||
DEF = -DEF="\"$(ETUFREQ)\""
|
|
||||||
DIP = -DIP="\"$(IPADDR)\""
|
|
||||||
DUN = -DUN="\"$(USERNAME)\""
|
|
||||||
|
|
||||||
DALL = $(DPV) $(DHN) $(DPN) $(DEM) $(DEP) $(DMC) $(DWX) $(DWY) $(DBL) $(DET) $(DEF) $(DIP) $(DUN)
|
|
||||||
|
|
||||||
all: doconfig
|
|
||||||
|
|
||||||
doconfig: ../../build.conf doconfig.c
|
|
||||||
@echo 'globalcflags = $(GLOBALCFLAGS)'
|
|
||||||
@echo 'globallflags = $(GLOBALLFLAGS)'
|
|
||||||
$(CC) $(GLOBALCFLAGS) $(DALL) doconfig.c -o doconfig $(GLOBALLFLAGS)
|
|
||||||
./doconfig
|
|
||||||
|
|
||||||
nt: ntdoconfig
|
|
||||||
|
|
||||||
ntdoconfig: ..\..\build.conf doconfig.c
|
|
||||||
@echo 'globalcflags = $(GLOBALCFLAGS)'
|
|
||||||
@echo 'globallflags = $(GLOBALLFLAGS)'
|
|
||||||
$(CC) $(GLOBALCFLAGS) $(DALL) doconfig.c -o doconfig $(GLOBALLFLAGS)
|
|
||||||
doconfig.exe
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f doconfig)
|
|
||||||
-(del doconfig.exe)
|
|
||||||
-(del *.obj)
|
|
||||||
-(del *.pdb)
|
|
||||||
|
|
||||||
include ../make.rules
|
|
||||||
include Makedepend
|
|
|
@ -1,284 +0,0 @@
|
||||||
/*
|
|
||||||
* Empire - A multi-player, client/server Internet based war game.
|
|
||||||
* Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
* Ken Stevens, Steve McClure
|
|
||||||
*
|
|
||||||
* This program 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.
|
|
||||||
*
|
|
||||||
* This program 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.
|
|
||||||
*
|
|
||||||
* You should have received a copy of the GNU General Public License
|
|
||||||
* along with this program; if not, write to the Free Software
|
|
||||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
*
|
|
||||||
* ---
|
|
||||||
*
|
|
||||||
* See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
* related information and legal notices. It is expected that any future
|
|
||||||
* projects/authors will amend these files as needed.
|
|
||||||
*
|
|
||||||
* ---
|
|
||||||
*
|
|
||||||
* doconfig.c: Generates the gamesdef.h file used to build the game, and
|
|
||||||
* the various make include files needed to build correctly.
|
|
||||||
*
|
|
||||||
* Known contributors to this file:
|
|
||||||
* Steve McClure, 1996-2000
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <errno.h>
|
|
||||||
#include <sys/types.h>
|
|
||||||
#include <sys/stat.h>
|
|
||||||
#include <stdio.h>
|
|
||||||
#include <stdlib.h>
|
|
||||||
#if !defined(_WIN32)
|
|
||||||
#include <unistd.h>
|
|
||||||
#else
|
|
||||||
#include <fcntl.h>
|
|
||||||
#include <direct.h>
|
|
||||||
#include <io.h>
|
|
||||||
#define mkdir(dir,perm) _mkdir(dir)
|
|
||||||
#endif
|
|
||||||
#include <string.h>
|
|
||||||
|
|
||||||
static void wrmakesrc(char *pathname);
|
|
||||||
static void wripglob(char *filename);
|
|
||||||
static void wrauth(char *filename);
|
|
||||||
static void wrgamesdef(char *filename);
|
|
||||||
|
|
||||||
char *copyright_header =
|
|
||||||
"/*\n"
|
|
||||||
" * Empire - A multi-player, client/server Internet based war game.\n"
|
|
||||||
" * Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,\n"
|
|
||||||
" * Ken Stevens, Steve McClure\n"
|
|
||||||
" *\n"
|
|
||||||
" * This program is free software; you can redistribute it and/or modify\n"
|
|
||||||
" * it under the terms of the GNU General Public License as published by\n"
|
|
||||||
" * the Free Software Foundation; either version 2 of the License, or\n"
|
|
||||||
" * (at your option) any later version.\n"
|
|
||||||
" *\n"
|
|
||||||
" * This program is distributed in the hope that it will be useful,\n"
|
|
||||||
" * but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
|
|
||||||
" * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n"
|
|
||||||
" * GNU General Public License for more details.\n"
|
|
||||||
" *\n"
|
|
||||||
" * You should have received a copy of the GNU General Public License\n"
|
|
||||||
" * along with this program; if not, write to the Free Software\n"
|
|
||||||
" * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA\n"
|
|
||||||
" *\n"
|
|
||||||
" * ---\n"
|
|
||||||
" *\n"
|
|
||||||
" * See the \"LEGAL\", \"LICENSE\", \"CREDITS\" and \"README\" files for all the\n"
|
|
||||||
" * related information and legal notices. It is expected that any future\n"
|
|
||||||
" * projects/authors will amend these files as needed.\n"
|
|
||||||
" *\n"
|
|
||||||
" * ---\n"
|
|
||||||
" *\n"
|
|
||||||
" * %s: %s\n"
|
|
||||||
" * \n"
|
|
||||||
" * Known contributors to this file:\n"
|
|
||||||
" * Automatically generated by doconfig.c\n"
|
|
||||||
" */\n\n";
|
|
||||||
|
|
||||||
#if defined(__GLIBC__) || defined(FBSD) || defined(__APPLE_) || defined(_WIN32)
|
|
||||||
#define safe_getcwd() getcwd(NULL, 0)
|
|
||||||
#else
|
|
||||||
static char *
|
|
||||||
safe_getcwd(void)
|
|
||||||
{
|
|
||||||
size_t size = 256;
|
|
||||||
|
|
||||||
for (;;) {
|
|
||||||
char *buf = malloc(size);
|
|
||||||
if (!buf)
|
|
||||||
return buf;
|
|
||||||
if (getcwd (buf, size))
|
|
||||||
return buf;
|
|
||||||
free (buf);
|
|
||||||
if (errno != ERANGE)
|
|
||||||
return NULL;
|
|
||||||
size *= 2;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
int
|
|
||||||
main(void)
|
|
||||||
{
|
|
||||||
char buf[256];
|
|
||||||
char *cp;
|
|
||||||
char *pathname;
|
|
||||||
|
|
||||||
if ((pathname = safe_getcwd()) == NULL) {
|
|
||||||
printf("Can't get current path!\n");
|
|
||||||
exit(-1);
|
|
||||||
}
|
|
||||||
#if !defined(_WIN32)
|
|
||||||
cp = strrchr(pathname, '/');
|
|
||||||
*cp = '\0';
|
|
||||||
cp = strrchr(pathname, '/');
|
|
||||||
*cp = '\0';
|
|
||||||
#else
|
|
||||||
cp = strrchr(pathname, '\\');
|
|
||||||
*cp = '\0';
|
|
||||||
cp = strrchr(pathname, '\\');
|
|
||||||
*cp = '\0';
|
|
||||||
#endif
|
|
||||||
printf("Configuring...\n");
|
|
||||||
wrmakesrc(pathname);
|
|
||||||
sprintf(buf, "%s/include/gamesdef.h", pathname);
|
|
||||||
wrgamesdef(buf);
|
|
||||||
sprintf(buf, "%s/src/client/ipglob.c", pathname);
|
|
||||||
wripglob(buf);
|
|
||||||
|
|
||||||
if (access(EP, 0)) {
|
|
||||||
printf("making directory %s\n", EP);
|
|
||||||
if (mkdir(EP, 0755)) {
|
|
||||||
printf("mkdir failed on %s, exiting.\n", EP);
|
|
||||||
exit(-1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
sprintf(buf, "%s/data", EP);
|
|
||||||
if (access(buf, 0)) {
|
|
||||||
printf("making directory %s\n", buf);
|
|
||||||
if (mkdir(buf, 0755)) {
|
|
||||||
printf("mkdir failed on %s, exiting.\n", buf);
|
|
||||||
exit(-1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
sprintf(buf, "%s/data/auth", EP);
|
|
||||||
wrauth(buf);
|
|
||||||
exit(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
|
||||||
wrmakesrc(char *pathname)
|
|
||||||
{
|
|
||||||
FILE *fp;
|
|
||||||
char buf[256];
|
|
||||||
|
|
||||||
sprintf(buf, "%s/src/make.src", pathname);
|
|
||||||
if ((fp = fopen(buf, "wb")) == NULL) {
|
|
||||||
printf("Cannot open %s for writing, exiting.\n", buf);
|
|
||||||
exit(-1);
|
|
||||||
}
|
|
||||||
fprintf(fp,
|
|
||||||
"# make.src: Source tree absolute pathname - auto generated.\n\n");
|
|
||||||
fprintf(fp, "SRCDIR = %s\n", pathname);
|
|
||||||
fclose(fp);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
|
||||||
wripglob(char *filename)
|
|
||||||
{
|
|
||||||
FILE *fp;
|
|
||||||
|
|
||||||
printf("Writing %s\n", filename);
|
|
||||||
if ((fp = fopen(filename, "wb")) == NULL) {
|
|
||||||
printf("Cannot open %s for writing, exiting.\n", filename);
|
|
||||||
exit(-1);
|
|
||||||
}
|
|
||||||
fprintf(fp, copyright_header,
|
|
||||||
strrchr(filename, '/')+1, "IP globals.");
|
|
||||||
fprintf(fp, "char empirehost[] = \"%s\";\n", HN);
|
|
||||||
fprintf(fp, "char empireport[] = \"%d\";\n", PN);
|
|
||||||
fclose(fp);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
|
||||||
wrauth(char *filename)
|
|
||||||
{
|
|
||||||
FILE *fp;
|
|
||||||
|
|
||||||
printf("Writing %s\n", filename);
|
|
||||||
if ((fp = fopen(filename, "w")) == NULL) {
|
|
||||||
printf("Cannot open %s for writing, exiting.\n", filename);
|
|
||||||
exit(-1);
|
|
||||||
}
|
|
||||||
|
|
||||||
fprintf(fp,
|
|
||||||
"# %s: Empire Authorization File\n"
|
|
||||||
"# Users listed will be allowed to log in as deities.\n#\n",
|
|
||||||
strrchr(filename, '/')+1);
|
|
||||||
fprintf(fp, "# Format is:\n");
|
|
||||||
fprintf(fp, "# hostname that authorized user uses on a line\n");
|
|
||||||
fprintf(fp, "# username that authorized user uses on a line\n#\n");
|
|
||||||
fprintf(fp, "# REMEMBER TO USE PAIRS OF LINES!\n#\n");
|
|
||||||
fprintf(fp, "# Example:\n#\n");
|
|
||||||
fprintf(fp, "#nowhere.land.edu\n#nowhereman\n");
|
|
||||||
fprintf(fp, "%s\n%s\n", HN, UN);
|
|
||||||
fprintf(fp, "%s\n%s\n", IP, UN);
|
|
||||||
fprintf(fp, "127.0.0.1\n%s\n", UN);
|
|
||||||
fclose(fp);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
|
||||||
wrgamesdef(char *filename)
|
|
||||||
{
|
|
||||||
FILE *fp;
|
|
||||||
char path[512];
|
|
||||||
char *cp;
|
|
||||||
unsigned int i;
|
|
||||||
int s_p_etu;
|
|
||||||
char buf[40];
|
|
||||||
char c = 'b';
|
|
||||||
|
|
||||||
cp = &path[0];
|
|
||||||
for (i = 0; i < strlen(EP); i++) {
|
|
||||||
*cp++ = EP[i];
|
|
||||||
if (EP[i] == '\\')
|
|
||||||
*cp++ = '\\';
|
|
||||||
}
|
|
||||||
*cp = 0;
|
|
||||||
|
|
||||||
strcpy(buf, EF);
|
|
||||||
if (strlen(buf) > 0)
|
|
||||||
c = buf[strlen(buf) - 1];
|
|
||||||
if (strchr("dhm", c) && strlen(buf) > 0) {
|
|
||||||
s_p_etu = atoi(buf);
|
|
||||||
if (c == 'd')
|
|
||||||
s_p_etu =
|
|
||||||
(((double)s_p_etu * 60.0 * 60.0 * 24.0) / (double)ET);
|
|
||||||
else if (c == 'h')
|
|
||||||
s_p_etu = (((double)s_p_etu * 60.0 * 60.0) / (double)ET);
|
|
||||||
else if (c == 'm')
|
|
||||||
s_p_etu = (((double)s_p_etu * 60.0) / (double)ET);
|
|
||||||
} else {
|
|
||||||
printf("ETU frequency is bad - using 10 minutes.\n");
|
|
||||||
s_p_etu = 600 / ET;
|
|
||||||
}
|
|
||||||
|
|
||||||
printf("Writing %s\n", filename);
|
|
||||||
if ((fp = fopen(filename, "wb")) == NULL) {
|
|
||||||
printf("Cannot open %s for writing, exiting.\n", filename);
|
|
||||||
exit(-1);
|
|
||||||
}
|
|
||||||
fprintf(fp, copyright_header,
|
|
||||||
strrchr(filename,'/')+1, "Server compile-time configuration");
|
|
||||||
fprintf(fp, "/*\n * Feel free to change these, but if you rerun doconfig this file will\n");
|
|
||||||
fprintf(fp, " * be overwritten again.\n");
|
|
||||||
fprintf(fp, " */\n\n");
|
|
||||||
fprintf(fp, "#ifndef _GAMESDEF_H_\n");
|
|
||||||
fprintf(fp, "#define _GAMESDEF_H_\n\n");
|
|
||||||
fprintf(fp, "#define EMPDIR \"%s\"\n", EP);
|
|
||||||
fprintf(fp, "#define PRVNAM \"%s\"\n", PV);
|
|
||||||
fprintf(fp, "#define PRVLOG \"%s\"\n", EM);
|
|
||||||
fprintf(fp, "#define GET_SOURCE \"using:\\n http://www.wolfpackempire.com/\"\n");
|
|
||||||
fprintf(fp, "#define EMP_HOST \"%s\"\n", IP);
|
|
||||||
fprintf(fp, "#define EMP_PORT \"%d\"\n\n", PN);
|
|
||||||
fprintf(fp, "#define MAXNOC %d\n\n", MC);
|
|
||||||
fprintf(fp, "#define DEF_WORLD_X %d\n", WX);
|
|
||||||
fprintf(fp, "#define DEF_WORLD_Y %d\n\n", WY);
|
|
||||||
fprintf(fp, "#define DEF_S_P_ETU %d\n", s_p_etu);
|
|
||||||
fprintf(fp, "#define ETUS %d\n\n", ET);
|
|
||||||
if (BL)
|
|
||||||
fprintf(fp, "#define BLITZ 1\n\n");
|
|
||||||
fprintf(fp, "#endif /* _GAMESDEF_H_ */\n");
|
|
||||||
fclose(fp);
|
|
||||||
}
|
|
|
@ -1 +0,0 @@
|
||||||
Makedepend
|
|
|
@ -1,62 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
|
|
||||||
# Note that these could have been listed 1 per line, but I chose to just
|
|
||||||
# stick them all together this way to shorten the file.
|
|
||||||
|
|
||||||
include ../../../build.conf
|
|
||||||
include ../../make.src
|
|
||||||
include ../../make.defs
|
|
||||||
|
|
||||||
LIB = $(SRCDIR)/lib/libas.a
|
|
||||||
NTLIB = $(SRCDIR)\lib\libas.lib
|
|
||||||
|
|
||||||
OBJS = as_cache.o as_costcomp.o as_delete.o as_extend.o as_hash.o as_init.o \
|
|
||||||
as_merge.o as_search.o as_stats.o as_winnow.o
|
|
||||||
|
|
||||||
NTOBJS = as_cache.obj as_costcomp.obj as_delete.obj as_extend.obj as_hash.obj \
|
|
||||||
as_init.obj as_merge.obj as_search.obj as_stats.obj as_winnow.obj
|
|
||||||
|
|
||||||
all: $(LIB)
|
|
||||||
|
|
||||||
nt: $(NTLIB)
|
|
||||||
|
|
||||||
$(NTLIB): $(NTOBJS)
|
|
||||||
-del /q $@
|
|
||||||
lib /OUT:$@ /DEBUGTYPE:CV $(NTOBJS)
|
|
||||||
|
|
||||||
$(LIB): $(OBJS)
|
|
||||||
rm -f $(LIB)
|
|
||||||
ar cq $(LIB) $(OBJS)
|
|
||||||
$(RANLIB) $(LIB)
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f $(OBJS))
|
|
||||||
-(del /q $(NTOBJS))
|
|
||||||
|
|
||||||
include ../../make.rules
|
|
||||||
include Makedepend
|
|
|
@ -1 +0,0 @@
|
||||||
Makedepend
|
|
|
@ -1,98 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
|
|
||||||
# Note that these could have been listed 1 per line, but I chose to just
|
|
||||||
# stick them all together this way to shorten the file.
|
|
||||||
|
|
||||||
include ../../../build.conf
|
|
||||||
include ../../make.src
|
|
||||||
include ../../make.defs
|
|
||||||
|
|
||||||
LIB = $(SRCDIR)/lib/libcommands.a
|
|
||||||
NTLIB = $(SRCDIR)\lib\libcommands.lib
|
|
||||||
|
|
||||||
OBJS = acce.o add.o anti.o arm.o army.o assa.o atta.o bdes.o best.o boar.o \
|
|
||||||
bomb.o brea.o budg.o buil.o buy.o capi.o carg.o cede.o cens.o chan.o \
|
|
||||||
coas.o coll.o comm.o cons.o conv.o coun.o cuto.o decl.o deli.o demo.o \
|
|
||||||
desi.o disa.o dist.o drop.o dump.o echo.o edit.o enab.o enli.o \
|
|
||||||
expl.o fina.o flash.o flee.o fly.o foll.o forc.o fort.o fuel.o give.o \
|
|
||||||
grin.o hard.o head.o improve.o info.o land.o laun.o lboard.o ldump.o \
|
|
||||||
ledg.o leve.o load.o look.o lost.o lstat.o lten.o map.o marc.o mark.o \
|
|
||||||
mfir.o mine.o miss.o mobq.o mobu.o mora.o move.o name.o nati.o navi.o \
|
|
||||||
ndump.o new.o newe.o news.o nuke.o offe.o offs.o orde.o orig.o para.o \
|
|
||||||
path.o payo.o pboa.o peek.o pdump.o plan.o play.o \
|
|
||||||
powe.o prod.o pstat.o rada.o rang.o rea.o real.o reco.o reje.o rela.o \
|
|
||||||
repa.o repo.o rese.o reso.o retr.o rout.o sabo.o sail.o sate.o scra.o \
|
|
||||||
scut.o sdump.o sect.o sell.o set.o setres.o setsect.o shar.o shark.o \
|
|
||||||
shi.o shoo.o show.o shut.o sinf.o skyw.o sona.o spy.o sstat.o star.o \
|
|
||||||
stop.o stre.o strv.o supp.o surv.o swap.o tele.o tend.o terr.o thre.o \
|
|
||||||
togg.o torp.o trad.o tran.o trea.o turn.o upda.o upgr.o vers.o wai.o \
|
|
||||||
wing.o wipe.o work.o xdump.o zdon.o
|
|
||||||
|
|
||||||
NTOBJS = acce.obj add.obj anti.obj arm.obj army.obj assa.obj atta.obj \
|
|
||||||
bdes.obj best.obj boar.obj bomb.obj brea.obj budg.obj buil.obj \
|
|
||||||
buy.obj capi.obj carg.obj cede.obj cens.obj chan.obj coas.obj \
|
|
||||||
coll.obj comm.obj cons.obj conv.obj coun.obj cuto.obj decl.obj \
|
|
||||||
deli.obj demo.obj desi.obj disa.obj dist.obj drop.obj \
|
|
||||||
dump.obj echo.obj edit.obj enab.obj enli.obj expl.obj fina.obj \
|
|
||||||
flash.obj flee.obj fly.obj foll.obj forc.obj fort.obj fuel.obj \
|
|
||||||
give.obj grin.obj hard.obj head.obj improve.obj info.obj \
|
|
||||||
land.obj laun.obj lboard.obj ldump.obj ledg.obj leve.obj load.obj \
|
|
||||||
look.obj lost.obj lstat.obj lten.obj map.obj marc.obj mark.obj \
|
|
||||||
mfir.obj mine.obj miss.obj mobq.obj mobu.obj mora.obj move.obj \
|
|
||||||
name.obj nati.obj navi.obj ndump.obj new.obj newe.obj news.obj \
|
|
||||||
nuke.obj offe.obj offs.obj orde.obj orig.obj para.obj path.obj \
|
|
||||||
payo.obj pboa.obj pdump.obj peek.obj plan.obj play.obj powe.obj \
|
|
||||||
prod.obj pstat.obj rada.obj rang.obj rea.obj real.obj reco.obj \
|
|
||||||
reje.obj rela.obj repa.obj repo.obj rese.obj reso.obj retr.obj \
|
|
||||||
rout.obj sabo.obj sail.obj sate.obj scra.obj scut.obj sdump.obj \
|
|
||||||
sect.obj sell.obj set.obj setres.obj setsect.obj shar.obj shark.obj \
|
|
||||||
shi.obj shoo.obj show.obj shut.obj sinf.obj skyw.obj sona.obj spy.obj \
|
|
||||||
sstat.obj star.obj stop.obj stre.obj strv.obj supp.obj surv.obj \
|
|
||||||
swap.obj tele.obj tend.obj terr.obj thre.obj togg.obj torp.obj \
|
|
||||||
trad.obj tran.obj trea.obj turn.obj upda.obj upgr.obj vers.obj \
|
|
||||||
wai.obj wing.obj wipe.obj work.obj xdump.obj zdon.obj
|
|
||||||
|
|
||||||
all: $(LIB)
|
|
||||||
|
|
||||||
nt: $(NTLIB)
|
|
||||||
|
|
||||||
$(NTLIB): $(NTOBJS)
|
|
||||||
-del /q $@
|
|
||||||
lib /OUT:$@ /DEBUGTYPE:CV $(NTOBJS)
|
|
||||||
|
|
||||||
$(LIB): $(OBJS)
|
|
||||||
rm -f $(LIB)
|
|
||||||
ar cq $(LIB) $(OBJS)
|
|
||||||
$(RANLIB) $(LIB)
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f $(OBJS))
|
|
||||||
-(del /q $(NTOBJS))
|
|
||||||
|
|
||||||
include ../../make.rules
|
|
||||||
include Makedepend
|
|
|
@ -37,7 +37,6 @@
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <time.h>
|
#include <time.h>
|
||||||
#include "gamesdef.h"
|
|
||||||
#include "misc.h"
|
#include "misc.h"
|
||||||
#include "player.h"
|
#include "player.h"
|
||||||
#include "version.h"
|
#include "version.h"
|
||||||
|
@ -167,7 +166,8 @@ vers(void)
|
||||||
pr("\n\n");
|
pr("\n\n");
|
||||||
pr("The person to annoy if something goes wrong is:\n\t%s\n\t(%s).\n",
|
pr("The person to annoy if something goes wrong is:\n\t%s\n\t(%s).\n",
|
||||||
privname, privlog);
|
privname, privlog);
|
||||||
pr("You can get your own copy of the source %s\n", GET_SOURCE);
|
pr("You can get your own copy of the source from "
|
||||||
|
"http://www.wolfpackempire.com/\n");
|
||||||
return RET_OK;
|
return RET_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1 +0,0 @@
|
||||||
Makedepend
|
|
|
@ -1,68 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
|
|
||||||
# Note that these could have been listed 1 per line, but I chose to just
|
|
||||||
# stick them all together this way to shorten the file.
|
|
||||||
|
|
||||||
include ../../../build.conf
|
|
||||||
include ../../make.src
|
|
||||||
include ../../make.defs
|
|
||||||
|
|
||||||
LIB = $(SRCDIR)/lib/libcommon.a
|
|
||||||
NTLIB = $(SRCDIR)\lib\libcommon.lib
|
|
||||||
|
|
||||||
OBJS = bestpath.o bridgefall.o check.o damage.o ef_load.o ef_verify.o \
|
|
||||||
file.o fsize.o hap_fact.o hours.o land.o log.o mailbox.o \
|
|
||||||
maps.o move.o nat.o path.o res_pop.o sectdamage.o \
|
|
||||||
stmtch.o tfact.o type.o wantupd.o xundump.o xy.o
|
|
||||||
|
|
||||||
NTOBJS = bestpath.obj bridgefall.obj check.obj damage.obj \
|
|
||||||
ef_load.obj ef_verify.obj file.obj fsize.obj \
|
|
||||||
hap_fact.obj hours.obj land.obj log.obj \
|
|
||||||
mailbox.obj maps.obj move.obj nat.obj path.obj res_pop.obj \
|
|
||||||
sectdamage.obj stmtch.obj tfact.obj \
|
|
||||||
type.obj wantupd.obj xundump.obj xy.obj
|
|
||||||
|
|
||||||
all: $(LIB)
|
|
||||||
|
|
||||||
nt: $(NTLIB)
|
|
||||||
|
|
||||||
$(NTLIB): $(NTOBJS)
|
|
||||||
-del /q $@
|
|
||||||
lib /OUT:$@ /DEBUGTYPE:CV $(NTOBJS)
|
|
||||||
|
|
||||||
$(LIB): $(OBJS)
|
|
||||||
rm -f $(LIB)
|
|
||||||
ar cq $(LIB) $(OBJS)
|
|
||||||
$(RANLIB) $(LIB)
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f $(OBJS))
|
|
||||||
-(del /q $(NTOBJS))
|
|
||||||
|
|
||||||
include ../../make.rules
|
|
||||||
include Makedepend
|
|
|
@ -1 +0,0 @@
|
||||||
Makedepend
|
|
|
@ -1,60 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
|
|
||||||
# Note that these could have been listed 1 per line, but I chose to just
|
|
||||||
# stick them all together this way to shorten the file.
|
|
||||||
|
|
||||||
include ../../../build.conf
|
|
||||||
include ../../make.src
|
|
||||||
include ../../make.defs
|
|
||||||
|
|
||||||
LIB = $(SRCDIR)/lib/libempth.a
|
|
||||||
NTLIB = $(SRCDIR)\lib\libempth.lib
|
|
||||||
|
|
||||||
OBJS = lwp.o pthread.o ntthread.o
|
|
||||||
|
|
||||||
NTOBJS = lwp.obj pthread.obj ntthread.obj
|
|
||||||
|
|
||||||
all: $(LIB)
|
|
||||||
|
|
||||||
nt: $(NTLIB)
|
|
||||||
|
|
||||||
$(NTLIB): $(NTOBJS)
|
|
||||||
-del /q $@
|
|
||||||
lib /OUT:$@ /DEBUGTYPE:CV $(NTOBJS)
|
|
||||||
|
|
||||||
$(LIB): $(OBJS)
|
|
||||||
rm -f $(LIB)
|
|
||||||
ar cq $(LIB) $(OBJS)
|
|
||||||
$(RANLIB) $(LIB)
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f $(OBJS))
|
|
||||||
-(del /q $(NTOBJS))
|
|
||||||
|
|
||||||
include ../../make.rules
|
|
||||||
include Makedepend
|
|
|
@ -1 +0,0 @@
|
||||||
Makedepend
|
|
|
@ -1,67 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
|
|
||||||
# Note that these could have been listed 1 per line, but I chose to just
|
|
||||||
# stick them all together this way to shorten the file.
|
|
||||||
|
|
||||||
include ../../../build.conf
|
|
||||||
include ../../make.src
|
|
||||||
include ../../make.defs
|
|
||||||
|
|
||||||
LIB = $(SRCDIR)/lib/libgen.a
|
|
||||||
NTLIB = $(SRCDIR)\lib\libgen.lib
|
|
||||||
|
|
||||||
OBJS = chance.o copy.o disassoc.o \
|
|
||||||
emp_config.o getstarg.o getstring.o io.o \
|
|
||||||
ioqueue.o mapdist.o minmax.o numstr.o onearg.o \
|
|
||||||
parse.o plur.o queue.o round.o scthash.o
|
|
||||||
|
|
||||||
NTOBJS = chance.obj copy.obj \
|
|
||||||
emp_config.obj getstarg.obj getstring.obj \
|
|
||||||
io.obj ioqueue.obj mapdist.obj minmax.obj \
|
|
||||||
numstr.obj onearg.obj parse.obj plur.obj queue.obj round.obj \
|
|
||||||
scthash.obj getopt.obj service.obj
|
|
||||||
|
|
||||||
all: $(LIB)
|
|
||||||
|
|
||||||
nt: $(NTLIB)
|
|
||||||
|
|
||||||
$(NTLIB): $(NTOBJS)
|
|
||||||
-del /q $@
|
|
||||||
lib /OUT:$@ /DEBUGTYPE:CV $(NTOBJS)
|
|
||||||
|
|
||||||
$(LIB): $(OBJS)
|
|
||||||
rm -f $(LIB)
|
|
||||||
ar cq $(LIB) $(OBJS)
|
|
||||||
$(RANLIB) $(LIB)
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f $(OBJS))
|
|
||||||
-(del /q $(NTOBJS))
|
|
||||||
|
|
||||||
include ../../make.rules
|
|
||||||
include Makedepend
|
|
|
@ -1 +0,0 @@
|
||||||
Makedepend
|
|
|
@ -1,64 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
|
|
||||||
# Note that these could have been listed 1 per line, but I chose to just
|
|
||||||
# stick them all together this way to shorten the file.
|
|
||||||
|
|
||||||
include ../../../build.conf
|
|
||||||
include ../../make.src
|
|
||||||
include ../../make.defs
|
|
||||||
|
|
||||||
LIB = $(SRCDIR)/lib/libglobal.a
|
|
||||||
NTLIB = $(SRCDIR)\lib\libglobal.lib
|
|
||||||
|
|
||||||
OBJS = constants.o dir.o file.o init.o item.o land.o news.o nsc.o \
|
|
||||||
nuke.o options.o path.o plane.o product.o sect.o ship.o\
|
|
||||||
treaty.o
|
|
||||||
|
|
||||||
NTOBJS = constants.obj dir.obj file.obj init.obj item.obj land.obj \
|
|
||||||
news.obj nsc.obj nuke.obj options.obj path.obj plane.obj \
|
|
||||||
product.obj sect.obj ship.obj treaty.obj
|
|
||||||
|
|
||||||
all: $(LIB)
|
|
||||||
|
|
||||||
nt: $(NTLIB)
|
|
||||||
|
|
||||||
$(NTLIB): $(NTOBJS)
|
|
||||||
-del /q $@
|
|
||||||
lib /OUT:$@ /DEBUGTYPE:CV $(NTOBJS)
|
|
||||||
|
|
||||||
$(LIB): $(OBJS)
|
|
||||||
rm -f $(LIB)
|
|
||||||
ar cq $(LIB) $(OBJS)
|
|
||||||
$(RANLIB) $(LIB)
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f $(OBJS))
|
|
||||||
-(del /q $(NTOBJS))
|
|
||||||
|
|
||||||
include ../../make.rules
|
|
||||||
include Makedepend
|
|
|
@ -34,21 +34,20 @@
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "gamesdef.h"
|
|
||||||
#include "misc.h"
|
#include "misc.h"
|
||||||
|
|
||||||
char *privname = PRVNAM; /* name of priv user */
|
char *privname = "Deity forgot to edit econfig"; /* name of priv user */
|
||||||
char *privlog = PRVLOG; /* logname of priv user */
|
char *privlog = "careless@invalid"; /* logname of priv user */
|
||||||
|
|
||||||
int WORLD_X = DEF_WORLD_X; /* World size - x */
|
int WORLD_X = 64; /* World size - x */
|
||||||
int WORLD_Y = DEF_WORLD_Y; /* World size - y */
|
int WORLD_Y = 32; /* World size - y */
|
||||||
|
|
||||||
int MARK_DELAY = 7200; /* Seconds to bid on commodities */
|
int MARK_DELAY = 7200; /* Seconds to bid on commodities */
|
||||||
int TRADE_DELAY = 7200; /* Seconds to bid on units */
|
int TRADE_DELAY = 7200; /* Seconds to bid on units */
|
||||||
|
|
||||||
int m_m_p_d = 1440; /* max mins of play per day (per country) */
|
int m_m_p_d = 1440; /* max mins of play per day (per country) */
|
||||||
int s_p_etu = DEF_S_P_ETU; /* seconds per Empire time unit */
|
int s_p_etu = 10; /* seconds per Empire time unit */
|
||||||
int etu_per_update = ETUS; /* # of etu's per update, from misc.h */
|
int etu_per_update = 60; /* # of etu's per update */
|
||||||
int adj_update = 0; /* update time adjustment */
|
int adj_update = 0; /* update time adjustment */
|
||||||
int update_window = 0; /* update window adjustment */
|
int update_window = 0; /* update window adjustment */
|
||||||
int hourslop = 5; /* amount of slop to match update times */
|
int hourslop = 5; /* amount of slop to match update times */
|
||||||
|
|
|
@ -25,19 +25,17 @@
|
||||||
*
|
*
|
||||||
* ---
|
* ---
|
||||||
*
|
*
|
||||||
|
* @configure_input@
|
||||||
* path.c: Path initializations needed outside of the file initialization
|
* path.c: Path initializations needed outside of the file initialization
|
||||||
* tables
|
* tables
|
||||||
*
|
*
|
||||||
* Known contributors to this file:
|
* Known contributors to this file:
|
||||||
*
|
* Markus Armbruster, 2005
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "gamesdef.h"
|
char dflt_econfig[] = "@econfig@";
|
||||||
|
char *infodir = "@einfodir@";
|
||||||
char dflt_econfig[] = EMPDIR "/data/econfig";
|
char *datadir = "@edatadir@";
|
||||||
|
|
||||||
char *infodir = EMPDIR "/info.nr";
|
|
||||||
char *datadir = EMPDIR "/data";
|
|
||||||
|
|
||||||
/* relative to DATADIR */
|
/* relative to DATADIR */
|
||||||
char *teldir = "tel";
|
char *teldir = "tel";
|
||||||
|
@ -51,4 +49,4 @@ char *authfil = "auth";
|
||||||
char *timestampfil = "timestamp";
|
char *timestampfil = "timestamp";
|
||||||
|
|
||||||
char *listen_addr = "";
|
char *listen_addr = "";
|
||||||
char *loginport = EMP_PORT;
|
char *loginport = "@EMPIREPORT@";
|
|
@ -1 +0,0 @@
|
||||||
Makedepend
|
|
|
@ -1,59 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
|
|
||||||
# Note that these could have been listed 1 per line, but I chose to just
|
|
||||||
# stick them all together this way to shorten the file.
|
|
||||||
|
|
||||||
include ../../../build.conf
|
|
||||||
include ../../make.src
|
|
||||||
include ../../make.defs
|
|
||||||
|
|
||||||
LIB = $(SRCDIR)/lib/liblwp.a
|
|
||||||
|
|
||||||
OBJS = arch.o lwp.o queue.o sel.o sem.o status.o
|
|
||||||
|
|
||||||
AIXOBJS = lwpInit.o lwpRestore.o lwpSave.o
|
|
||||||
|
|
||||||
GENMASTER = GLOBALCFLAGS="$(GLOBALCFLAGS)" GLOBALLFLAGS="$(GLOBALLFLAGS)"
|
|
||||||
|
|
||||||
all: $(LIB)
|
|
||||||
|
|
||||||
$(LIB): $(OBJS) $(EXTRAOBJS)
|
|
||||||
rm -f $(LIB)
|
|
||||||
ar cq $(LIB) $(OBJS) $(EXTRAOBJS)
|
|
||||||
$(RANLIB) $(LIB)
|
|
||||||
|
|
||||||
nt:
|
|
||||||
|
|
||||||
aix:
|
|
||||||
make EXTRAOBJS="$(AIXOBJS)" $(GENMASTER)
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f $(OBJS) $(AIXOBJS) $(MIPSOBJS))
|
|
||||||
|
|
||||||
include ../../make.rules
|
|
||||||
include Makedepend
|
|
|
@ -1 +0,0 @@
|
||||||
Makedepend
|
|
|
@ -1,62 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
|
|
||||||
# Note that these could have been listed 1 per line, but I chose to just
|
|
||||||
# stick them all together this way to shorten the file.
|
|
||||||
|
|
||||||
include ../../../build.conf
|
|
||||||
include ../../make.src
|
|
||||||
include ../../make.defs
|
|
||||||
|
|
||||||
LIB = $(SRCDIR)/lib/libplayer.a
|
|
||||||
NTLIB = $(SRCDIR)\lib\libplayer.lib
|
|
||||||
|
|
||||||
OBJS = accept.o dispatch.o empdis.o empmod.o init_nats.o login.o nat.o \
|
|
||||||
player.o recvclient.o
|
|
||||||
|
|
||||||
NTOBJS = accept.obj dispatch.obj empdis.obj empmod.obj init_nats.obj \
|
|
||||||
login.obj nat.obj player.obj recvclient.obj
|
|
||||||
|
|
||||||
all: $(LIB)
|
|
||||||
|
|
||||||
nt: $(NTLIB)
|
|
||||||
|
|
||||||
$(NTLIB): $(NTOBJS)
|
|
||||||
-del /q $@
|
|
||||||
lib /OUT:$@ /DEBUGTYPE:CV $(NTOBJS)
|
|
||||||
|
|
||||||
$(LIB): $(OBJS)
|
|
||||||
rm -f $(LIB)
|
|
||||||
ar cq $(LIB) $(OBJS)
|
|
||||||
$(RANLIB) $(LIB)
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f $(OBJS))
|
|
||||||
-(del /q $(NTOBJS))
|
|
||||||
|
|
||||||
include ../../make.rules
|
|
||||||
include Makedepend
|
|
|
@ -1 +0,0 @@
|
||||||
Makedepend
|
|
|
@ -1,76 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
|
|
||||||
# Note that these could have been listed 1 per line, but I chose to just
|
|
||||||
# stick them all together this way to shorten the file.
|
|
||||||
|
|
||||||
include ../../../build.conf
|
|
||||||
include ../../make.src
|
|
||||||
include ../../make.defs
|
|
||||||
|
|
||||||
LIB = $(SRCDIR)/lib/libsubs.a
|
|
||||||
NTLIB = $(SRCDIR)\lib\libsubs.lib
|
|
||||||
|
|
||||||
OBJS = aircombat.o askyn.o aswplnsubs.o attsub.o bigmap.o border.o bsanct.o \
|
|
||||||
caploss.o chkmoney.o cnumb.o coastal.o control.o detonate.o disloan.o \
|
|
||||||
distrea.o fileinit.o fortdef.o getbit.o getele.o land.o landgun.o \
|
|
||||||
list.o lndsub.o lostsub.o mission.o move.o mslsub.o mtch.o natarg.o \
|
|
||||||
neigh.o nreport.o nstr.o nuke.o nxtitem.o nxtsct.o paths.o plane.o \
|
|
||||||
plnsub.o pr.o radmap.o rej.o retreat.o sarg.o satmap.o \
|
|
||||||
sect.o ship.o show.o shpsub.o snxtitem.o snxtsct.o supply.o \
|
|
||||||
takeover.o trdsub.o trechk.o whatitem.o wu.o
|
|
||||||
|
|
||||||
NTOBJS = aircombat.obj askyn.obj aswplnsubs.obj attsub.obj bigmap.obj \
|
|
||||||
border.obj bsanct.obj caploss.obj chkmoney.obj cnumb.obj coastal.obj \
|
|
||||||
control.obj detonate.obj disloan.obj distrea.obj fileinit.obj fortdef.obj \
|
|
||||||
getbit.obj getele.obj land.obj landgun.obj list.obj lndsub.obj \
|
|
||||||
lostsub.obj mission.obj move.obj mslsub.obj mtch.obj natarg.obj neigh.obj \
|
|
||||||
nreport.obj nstr.obj nuke.obj nxtitem.obj nxtsct.obj paths.obj plane.obj \
|
|
||||||
plnsub.obj pr.obj radmap.obj rej.obj retreat.obj sarg.obj satmap.obj \
|
|
||||||
sect.obj ship.obj show.obj shpsub.obj snxtitem.obj \
|
|
||||||
snxtsct.obj supply.obj takeover.obj trdsub.obj trechk.obj whatitem.obj \
|
|
||||||
wu.obj
|
|
||||||
|
|
||||||
all: $(LIB)
|
|
||||||
|
|
||||||
nt: $(NTLIB)
|
|
||||||
|
|
||||||
$(NTLIB): $(NTOBJS)
|
|
||||||
-del /q $@
|
|
||||||
lib /OUT:$@ /DEBUGTYPE:CV $(NTOBJS)
|
|
||||||
|
|
||||||
$(LIB): $(OBJS)
|
|
||||||
rm -f $(LIB)
|
|
||||||
ar cq $(LIB) $(OBJS)
|
|
||||||
$(RANLIB) $(LIB)
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f $(OBJS))
|
|
||||||
-(del /q $(NTOBJS))
|
|
||||||
|
|
||||||
include ../../make.rules
|
|
||||||
include Makedepend
|
|
|
@ -1 +0,0 @@
|
||||||
Makedepend
|
|
|
@ -1,67 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
|
|
||||||
# Note that these could have been listed 1 per line, but I chose to just
|
|
||||||
# stick them all together this way to shorten the file.
|
|
||||||
|
|
||||||
include ../../../build.conf
|
|
||||||
include ../../make.src
|
|
||||||
include ../../make.defs
|
|
||||||
|
|
||||||
LIB = $(SRCDIR)/lib/libupdate.a
|
|
||||||
NTLIB = $(SRCDIR)\lib\libupdate.lib
|
|
||||||
|
|
||||||
OBJS = age.o anno.o bp.o deliver.o distribute.o finish.o human.o land.o \
|
|
||||||
main.o material.o mobility.o move_sat.o nat.o nav_ship.o nav_util.o \
|
|
||||||
nxtitemp.o plague.o plane.o populace.o prepare.o produce.o \
|
|
||||||
removewants.o revolt.o sail.o sect.o ship.o
|
|
||||||
|
|
||||||
NTOBJS = age.obj anno.obj bp.obj deliver.obj distribute.obj finish.obj \
|
|
||||||
human.obj land.obj main.obj material.obj mobility.obj move_sat.obj \
|
|
||||||
nat.obj nav_ship.obj nav_util.obj nxtitemp.obj plague.obj \
|
|
||||||
plane.obj populace.obj prepare.obj produce.obj removewants.obj \
|
|
||||||
revolt.obj sail.obj sect.obj ship.obj
|
|
||||||
|
|
||||||
all: $(LIB)
|
|
||||||
|
|
||||||
nt: $(NTLIB)
|
|
||||||
|
|
||||||
$(NTLIB): $(NTOBJS)
|
|
||||||
-del /q $@
|
|
||||||
lib /OUT:$@ /DEBUGTYPE:CV $(NTOBJS)
|
|
||||||
|
|
||||||
$(LIB): $(OBJS)
|
|
||||||
rm -f $(LIB)
|
|
||||||
ar cq $(LIB) $(OBJS)
|
|
||||||
$(RANLIB) $(LIB)
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f $(OBJS))
|
|
||||||
-(del /q $(NTOBJS))
|
|
||||||
|
|
||||||
include ../../make.rules
|
|
||||||
include Makedepend
|
|
|
@ -1,42 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# make.defs - Wolfpack, 1996
|
|
||||||
#
|
|
||||||
# Lots of definition stuff common to the makefiles can go here.
|
|
||||||
# Make sure that make.src is included before this one (both
|
|
||||||
# are in this directory, but make.src is auto-generated.)
|
|
||||||
|
|
||||||
GLOBALCFLAGS =
|
|
||||||
GLOBALLFLAGS =
|
|
||||||
GLOBALIFLAGS = -I$(SRCDIR)/include
|
|
||||||
|
|
||||||
RANLIB = ranlib
|
|
||||||
|
|
||||||
CFLAGS = $(LOCALCFLAGS) $(GLOBALCFLAGS)
|
|
||||||
IFLAGS = $(LOCALIFLAGS) $(GLOBALIFLAGS)
|
|
||||||
LFLAGS = $(LOCALLFLAGS) $(GLOBALLFLAGS)
|
|
||||||
|
|
||||||
|
|
|
@ -1,39 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# make.rules - Wolfpack, 1996
|
|
||||||
#
|
|
||||||
# Lots of rules stuff common to the makefiles can go here.
|
|
||||||
# Make sure that make.src is included before this one (both
|
|
||||||
# are in this directory, but make.src is auto-generated.)
|
|
||||||
|
|
||||||
.c.obj: ;
|
|
||||||
$(CC) -c $(IFLAGS) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
.c.o: ;
|
|
||||||
$(CC) -c $(IFLAGS) $(CFLAGS) $*.c
|
|
||||||
|
|
||||||
depend:
|
|
||||||
$(CC) -M -I../../include -I../../../include *.c > Makedepend
|
|
24
src/scripts/cvsfiles.awk
Executable file
24
src/scripts/cvsfiles.awk
Executable file
|
@ -0,0 +1,24 @@
|
||||||
|
#!/usr/bin/awk -f
|
||||||
|
# Find files under CVS control
|
||||||
|
# FIXME Ignores CVS/Entries.log
|
||||||
|
|
||||||
|
BEGIN {
|
||||||
|
FS="/";
|
||||||
|
if (ARGC == 1)
|
||||||
|
ARGV[ARGC++] = "CVS/Entries";
|
||||||
|
else {
|
||||||
|
for (i = 1; i < ARGC; i++)
|
||||||
|
ARGV[i] = ARGV[i] "/CVS/Entries";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
{ cwd = FILENAME; sub(/CVS\/Entries$/, "", cwd); }
|
||||||
|
|
||||||
|
/^\// {
|
||||||
|
if ($3 !~ /^-/)
|
||||||
|
print cwd $2;
|
||||||
|
}
|
||||||
|
|
||||||
|
/^D/ && NF > 1 {
|
||||||
|
ARGV[ARGC++] = cwd $2 "/CVS/Entries";
|
||||||
|
}
|
|
@ -1,2 +1 @@
|
||||||
Makedepend
|
|
||||||
emp_server
|
emp_server
|
||||||
|
|
|
@ -1,119 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
|
|
||||||
# Note that these could have been listed 1 per line, but I chose to just
|
|
||||||
# stick them all together this way to shorten the file.
|
|
||||||
|
|
||||||
include ../../build.conf
|
|
||||||
include ../make.src
|
|
||||||
include ../make.defs
|
|
||||||
|
|
||||||
OBJS = main.o idle.o lostitem.o marketup.o shutdown.o timestamp.o update.o
|
|
||||||
|
|
||||||
NTOBJS = main.obj idle.obj lostitem.obj marketup.obj shutdown.obj \
|
|
||||||
timestamp.obj update.obj
|
|
||||||
|
|
||||||
LIBDIR = $(SRCDIR)/lib
|
|
||||||
|
|
||||||
LIBS = $(LIBDIR)/libplayer.a \
|
|
||||||
$(LIBDIR)/libupdate.a \
|
|
||||||
$(LIBDIR)/libcommands.a \
|
|
||||||
$(LIBDIR)/libsubs.a \
|
|
||||||
$(LIBDIR)/libcommon.a \
|
|
||||||
$(LIBDIR)/libgen.a \
|
|
||||||
$(LIBDIR)/libglobal.a \
|
|
||||||
$(LIBDIR)/libas.a \
|
|
||||||
$(LIBDIR)/libempth.a \
|
|
||||||
$(LIBDIR)/liblwp.a
|
|
||||||
|
|
||||||
OSXLIBS = $(LIBDIR)/libplayer.a \
|
|
||||||
$(LIBDIR)/libupdate.a \
|
|
||||||
$(LIBDIR)/libcommands.a \
|
|
||||||
$(LIBDIR)/libsubs.a \
|
|
||||||
$(LIBDIR)/libcommon.a \
|
|
||||||
$(LIBDIR)/libgen.a \
|
|
||||||
$(LIBDIR)/libglobal.a \
|
|
||||||
$(LIBDIR)/libas.a \
|
|
||||||
$(LIBDIR)/libempth.a
|
|
||||||
|
|
||||||
NTLIBS = $(LIBDIR)\libplayer.lib \
|
|
||||||
$(LIBDIR)\libupdate.lib \
|
|
||||||
$(LIBDIR)\libcommands.lib \
|
|
||||||
$(LIBDIR)\libsubs.lib \
|
|
||||||
$(LIBDIR)\libcommon.lib \
|
|
||||||
$(LIBDIR)\libgen.lib \
|
|
||||||
$(LIBDIR)\libglobal.lib \
|
|
||||||
$(LIBDIR)\libas.lib \
|
|
||||||
$(LIBDIR)\libempth.lib
|
|
||||||
|
|
||||||
all: emp_server
|
|
||||||
|
|
||||||
osx: empX_server
|
|
||||||
|
|
||||||
nt: emp_server.exe
|
|
||||||
|
|
||||||
emp_server.exe: $(NTOBJS) $(NTLIBS)
|
|
||||||
link /OUT:emp_server.exe \
|
|
||||||
/PDB:emp_server.pdb /NOLOGO \
|
|
||||||
/NOD /DEBUG:full /DEBUGTYPE:cv /MACHINE:IX86 /NOLOGO \
|
|
||||||
$(NTOBJS) $(NTLIBS) \
|
|
||||||
kernel32.lib \
|
|
||||||
ws2_32.lib \
|
|
||||||
libcmt.lib \
|
|
||||||
oldnames.lib \
|
|
||||||
advapi32.lib
|
|
||||||
|
|
||||||
emp_server: $(OBJS) $(LIBS)
|
|
||||||
$(CC) -o emp_server $(OBJS) $(LIBS) $(LFLAGS) $(GLOBALPFLAGS) -lm -lc
|
|
||||||
|
|
||||||
empX_server: $(OBJS) $(OSXLIBS)
|
|
||||||
$(CC) -o emp_server $(OBJS) $(OSXLIBS) $(LFLAGS) $(GLOBALPFLAGS) -lm -lc
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(del /q $(NTOBJS))
|
|
||||||
-(del /q emp_server.exe)
|
|
||||||
-(del /q emp_server.ilk)
|
|
||||||
-(del /q emp_server.pdb)
|
|
||||||
-(rm -f $(OBJS))
|
|
||||||
-(rm -f emp_server)
|
|
||||||
-(rm -f $(OSXOBJS))
|
|
||||||
-(rm -f empX_server)
|
|
||||||
|
|
||||||
install:
|
|
||||||
-(mkdir $(EMPDIR)/bin)
|
|
||||||
-(cp emp_server $(EMPDIR)/bin)
|
|
||||||
|
|
||||||
OSXinstall:
|
|
||||||
-(mkdir $(EMPDIR)/bin)
|
|
||||||
-(cp empX_server $(EMPDIR)/bin)
|
|
||||||
|
|
||||||
ntinstall:
|
|
||||||
-(mkdir $(NTINSTDIR)\bin)
|
|
||||||
-(copy emp_server.exe $(NTINSTDIR)\bin)
|
|
||||||
|
|
||||||
include ../make.rules
|
|
||||||
include Makedepend
|
|
|
@ -1,4 +1,3 @@
|
||||||
Makedepend
|
|
||||||
fairland
|
fairland
|
||||||
files
|
files
|
||||||
pconfig
|
pconfig
|
||||||
|
|
|
@ -1,108 +0,0 @@
|
||||||
#
|
|
||||||
# Empire - A multi-player, client/server Internet based war game.
|
|
||||||
# Copyright (C) 1986-2005, Dave Pare, Jeff Bailey, Thomas Ruschak,
|
|
||||||
# Ken Stevens, Steve McClure
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# This program 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.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
||||||
#
|
|
||||||
# ---
|
|
||||||
#
|
|
||||||
# See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
|
|
||||||
# related information and legal notices. It is expected that any future
|
|
||||||
# projects/authors will amend these files as needed.
|
|
||||||
#
|
|
||||||
# Makefile - Wolfpack, 1996
|
|
||||||
|
|
||||||
# Note that these could have been listed 1 per line, but I chose to just
|
|
||||||
# stick them all together this way to shorten the file.
|
|
||||||
|
|
||||||
include ../../build.conf
|
|
||||||
include ../make.src
|
|
||||||
include ../make.defs
|
|
||||||
|
|
||||||
LIBDIR = $(SRCDIR)/lib
|
|
||||||
|
|
||||||
LIBS = $(LIBDIR)/libcommon.a \
|
|
||||||
$(LIBDIR)/libgen.a \
|
|
||||||
$(LIBDIR)/libglobal.a
|
|
||||||
|
|
||||||
NTLIBS = $(LIBDIR)\libcommon.lib \
|
|
||||||
$(LIBDIR)\libgen.lib \
|
|
||||||
$(LIBDIR)\libglobal.lib
|
|
||||||
|
|
||||||
OBJS = fairland.o files.o pconfig.o
|
|
||||||
|
|
||||||
NTOBJS = fairland.obj files.obj pconfig.obj
|
|
||||||
|
|
||||||
nt: ntfairland ntfiles ntpconfig
|
|
||||||
|
|
||||||
all: fairland files pconfig
|
|
||||||
|
|
||||||
osx: fairland files pconfig
|
|
||||||
|
|
||||||
ntfiles: files.obj
|
|
||||||
link /OUT:files.exe \
|
|
||||||
/NOD /DEBUG:full /DEBUGTYPE:cv /MACHINE:IX86 /NOLOGO \
|
|
||||||
files.obj $(NTLIBS) \
|
|
||||||
kernel32.lib \
|
|
||||||
wsock32.lib \
|
|
||||||
libcmt.lib \
|
|
||||||
oldnames.lib
|
|
||||||
|
|
||||||
files: files.o
|
|
||||||
$(CC) -o files $(IFLAGS) $(CFLAGS) files.o $(LIBS) $(LFLAGS) -lc
|
|
||||||
|
|
||||||
fairland: fairland.o
|
|
||||||
$(CC) -o fairland $(IFLAGS) $(CFLAGS) fairland.o $(LIBS) $(LFLAGS) -lc
|
|
||||||
|
|
||||||
ntfairland: fairland.obj
|
|
||||||
link /OUT:fairland.exe \
|
|
||||||
/NOD /DEBUG:full /DEBUGTYPE:cv /MACHINE:IX86 /NOLOGO \
|
|
||||||
fairland.obj $(NTLIBS) \
|
|
||||||
kernel32.lib \
|
|
||||||
wsock32.lib \
|
|
||||||
libcmt.lib \
|
|
||||||
oldnames.lib
|
|
||||||
|
|
||||||
pconfig: pconfig.o
|
|
||||||
$(CC) -o pconfig $(IFLAGS) $(CFLAGS) pconfig.o $(LIBS) $(LFLAGS) -lc
|
|
||||||
|
|
||||||
ntpconfig: pconfig.obj
|
|
||||||
link /OUT:pconfig.exe \
|
|
||||||
/NOD /DEBUG:full /DEBUGTYPE:cv /MACHINE:IX86 /NOLOGO \
|
|
||||||
pconfig.obj $(NTLIBS) \
|
|
||||||
kernel32.lib \
|
|
||||||
wsock32.lib \
|
|
||||||
libcmt.lib \
|
|
||||||
oldnames.lib
|
|
||||||
|
|
||||||
clean:
|
|
||||||
-(rm -f files fairland pconfig $(OBJS))
|
|
||||||
-(del /q *.exe *.pdb *.ilk $(NTOBJS))
|
|
||||||
|
|
||||||
install:
|
|
||||||
-(mkdir $(EMPDIR)/bin)
|
|
||||||
-(cp files $(EMPDIR)/bin)
|
|
||||||
-(cp fairland $(EMPDIR)/bin)
|
|
||||||
-(cp pconfig $(EMPDIR)/bin)
|
|
||||||
|
|
||||||
ntinstall:
|
|
||||||
-(mkdir $(NTINSTDIR)\bin)
|
|
||||||
-(copy files.exe $(NTINSTDIR)\bin)
|
|
||||||
-(copy fairland.exe $(NTINSTDIR)\bin)
|
|
||||||
-(copy pconfig.exe $(NTINSTDIR)\bin)
|
|
||||||
|
|
||||||
include ../make.rules
|
|
||||||
include Makedepend
|
|
Loading…
Add table
Add a link
Reference in a new issue