File: README1.5.compiling

package info (click to toggle)
xevil 1.5.1e-2.2
  • links: PTS
  • area: main
  • in suites: slink
  • size: 4,580 kB
  • ctags: 2,655
  • sloc: cpp: 17,863; makefile: 223; sh: 1
file content (149 lines) | stat: -rw-r--r-- 5,801 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
				XEvil version 1.5
				-----------------

PRECOMPILED BINARIES
	If you have one of the following machines, you do not have to do 
anything.  Just grab the appropriate binary.  
ftp://ftp.x.org/contrib/games/xevil1.5

DEC Alpha  
	[xevil1.5.alpha]
A decmips machine such as a DEC 5000, DEC 3000, DEC 2100  
	[xevil1.5.decmips]
Silicon Graphics Iris machine (Indigo, Indy, Indigo2, Reality Engine, etc.)
	[xevil1.5.iris]
Sun 4 or Sun 5 
	[xevil1.5.sun4]
386 Linux machine 
	[xevil1.5.linux]
IBM RSAIX such as a RS/6000 
	[xevil1.5.rsaix]
HP series 700 machines 
	[xevil1.5.hp700]



REQUIREMENTS FOR COMPILING
	Xlib and a C++ compiler.  XEvil has been compiled successfully with
versions of g++ and of CC (cfront).  



COMPILING
	In theory, you could just type 'make' and everything would work.
In practice you will modify the Makefile to your needs.  (Sorry no Imakefile
yet.)  I have tried to keep the Makefile as short and simple as possible.
By default the Makefile will look for the hostype or HOSTTYPE variables
and will call itself with the hosttype as an argument.  E.g. If HOSTTYPE is
decmips then typing `make` is the same as typing `make decmips`.

	You should look at the "Specific Architectures" section of the 
Makefile. Modify one of these lines to add appropriate include and libs 
directories as well as to define the compiler and compiler options.


Meanings of symbols used by the specific architectures:
------------------------------------------------------
CC		C++ compiler to use.  Probably g++ or CC.
LIBS		Libraries to use.  Usually "-lX11 -lm".  For some odd reason
		I needed to add "-ldnet_stub" for the Alpha I was using and
		"-lsocket -lnsl" for the Sun 4 machines on Project Athena.
INCL_DIRS	Where to look for the include files.
LIBS_DIRS	Where to look for the libraries.
LINK_FLAGS	Command line options for the link phase of compiling.
CFLAGS		Command line options for compiling.  You can use any flags your
		compiler understands as well as the following:


Additional options for CFLAGS.
------------------------------
-DUSE_RANDOM			Use the random() function instead of rand() to
				generate random numbers.  random() is a better
				pseudo-number generator than rand().  You will
				probably want to use this.
-DRANDOM_NEEDS_PROTOTYPES	If you are using random() and for some reason
				the prototypes for random() and srandom() do
				not appear in <math.h>, use this flag.  This
				happens on Project Athena.
-DUSE_SELECT_H			If you need <sys/select.h> for the prototypes
				for select(), use this option.
-DSELECT_NEEDS_PROTOTYPES	If the prototypes for select() still do not 
				show up, use this option.
-DXEVIL_KEYSET=<keyset-name>	You can specify the default set of keyboard
				controls for XEvil at compile-time.  Controls 
				can also be specified with the -keys command 
				line option, with X resources, or with the 
				"Learn Controls" button when the program is 
				running.  See the man pages, xevil.6, for more 
				details.
				<keyset-name> can be one of {UIsun3, UIdecmips,
				UIiris, UIncd, UItektronix, UIsun4, UIrsaix,
				UIsun4_sparc,UImac}.
-DPROTECTED_IS_PUBLIC		Some compilers have funny and non-standard 
				ideas of what "protected" means in an inherited
				class.  If you get an error like "method 
				<some method> is protected in this 
				context", try using this flag.  It
				makes all protected class members into
				public members.
-DCLOCKS_PER_SEC=<clocks-per-sec>	
				In some cases, the symbol 
				CLOCKS_PER_SEC is not defined anywhere and you
				must manually define it.  This is the 
				conversion from the unit of time given by the 
				clock() function to seconds.  If you don't 
				know what the value is for your system, use 
				-DCLOCKS_PER_SEC=1000000L  This is the most
				common value.
-DMATH_H_IS_CC			Use this if you get strange errors from the
				include file math.h.  Usually math.h is 
				written in C, so the XEvil source includes it
				as a C include file.  Sometimes, however, 
				math.h is in C++, so it should be included 
				in the normal way.
-DNO_PRAGMAS			Some compilers such as g++ take advantage of
				"#pragma interface" and 
				"#pragma implementation" compiler directives
				and others do not.  In theory, every C compiler
 				should ignore pragmas it doesn't use.  However,
 				some lame-ass compilers, such as SGI's 64 bit 
				C++ compiler, whine and give warning messages.
  				-DNO_PRAGMAS simply avoids these warning 
				messages.


INSTALLATION
1) 	Place the executable, xevil, in /usr/bin, /usr/local/bin, or wherever
you like to put your binaries. 

2) 	Put the man pages, xevil.6, in /usr/man/man6 or wherever you like your
man pages.

3) 	If desired, add lines to your .Xdefaults or .Xresources file to 
customize the keyboard controls of XEvil.  See the man pages, xevil.6, or
look at the samples in app-defaults.


8/22/95
6/1/96

-------------------------------------------------------------------------------
    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 1, 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., 675 Mass Ave, Cambridge, MA 02139, USA.

    Steve Hardt
    hardts@mit.edu (valid until Nov. 1996)
    hardts@netscape.com
    hardts@alum.mit.edu
    http://graphics.lcs.mit.edu/~hardts