-
Notifications
You must be signed in to change notification settings - Fork 70
/
BUILDING.txt
279 lines (195 loc) · 11 KB
/
BUILDING.txt
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
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
-----------------------------------------------------------------------
Building Hercules
Copyright 2016 by Stephen R. Orso. This work is licensed under the Creative
Commons Attribution-ShareAlike 4.0 International License. To view a copy of
this license, visit http://creativecommons.org/licenses/by-sa/4.0/ or send
a letter to Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
To build Hercules from source, perform the following steps:
1. Ensure your computer has the required versions of the software
packages needed to build Hercules.
2. Install any of the optional packages you wish to use with Hercules.
3. Obtain a copy of Hercules sources.
4. Build the recommended directory structure for a Hercules build
5. Obtain SoftFloat 3a For Hercules and build it using the instructions
included with that package. A pre-built set of binaries exists for
Windows.
6. Obtain and build Hercules using the README specific to your
platform.
Steps 4, 5, and 6 will can be performed by using the 1Stop shell script
or command included in the Hercules sources. 1Stop is described in the
host platform-specific readme file, README.BuildUNIX.txt or
README.BuildWIN.txt.
Please Note: UNIX-like operating systems, including descendants of
AT&T System V UNIX, GNU/Linux, BSD, and OS/X, are collectively referred
in these readme files as "UNIX." While The Open Group owns the
trademark to UNIX and has several pages describing how that trademark
may be used, it would be wise of The Open Group to remember two words:
kleenex and ketchup.
REQUIRED SOFTWARE PACKAGES
The required packages vary by host system type, UNIX or Windows.
UNIX: You will need the packages required to configure, compile,
link, and install a C application. Either gcc or clang may be
used. You will also need automake, autoconf, and a few other
utilities. README.BuildUNIX provides details about the packages
and versions required. Most required packages are available with
many UNIX distributions, but you may need to build from source to
get the version you require.
Windows: You will need Visual Studio 2015 Community Edition, an
appropriate Windows Software Development Kit (SDK), a git client,
and the file win32.mak from the Windows 7.1 SDK. README.BuildWIN.txt
hase specifics, URLs to obtain the needed software, and instructions
for installing win32.mak.
Both UNIX and Windows: You will need CMake to build Softfloat 3a For
Hercules, and Windows builders will need it to build the PCRE
package. Version 3.2.0 or higher is required.
OPTIONAL SOFTWARE PACKAGES
Note that for all of the optional packages, you must install the
development libraries to integrate the package into Hercules. To
use runtest and/or make check, you will need the run-time binaries
for one or both REXX interpreters.
REXX interpreters (at least one is recommended)
You must install a REXX interpreter if you plan to do any of the
following:
- Use runtest - to run one or more Hercules test scripts from
the tests directory.
- (UNIX) perform a "make check" after the build.
- Use REXX program files in RC scripts, on the Hercules console,
or in the configuration file. All of these are described
in chapter 14 of the Hercules - User Reference Guide for
Version 4.00.
If you are not sure, install one or both REXX interpreters if your
host system does not have one of them installed already. Your
choices are:
- ooRexx: Open Object REXX, an open source derivative of a subset
of the IBM program product Object REXX. Find it at:
http://ooRexx.org
- Regina Rexx, an open source REXX interpreter that may be found
here:
http://regina-rexx.sourceforge.net/index.html
Source and installable executables are available for Windows and
many UNIX distributions.
Disk and Tape Compression Libraries (recommended)
While disk and tape compression libraries are, strictly speaking,
option, and Hercules will build and run correctly without them,
may pre-built operating system distributions use compressed disks
and tapes.
To reduce storage requirements, emulated disk and tape volumes may
compressed on the fly. Compression has its own disk space versus
system performance trade-off, and you are in the best position to
decide whether to compress volumes.
For file and volume interchange purposes, it is recommended that
you instal both compression libraries and enable their use when
building Hercules. Even if you do not compress the volumes you
use with Hercules, having the capability lets you work with a
compressed voluem you may have received from someone else.
Note that tape volume compression is specified in the HETINIT host
command that creates the emulated tape, and the compression type,
bzip2 or zlib, is specified in the Hercules command devinit or
attach. Disk volume compression is specified exclusively in the
DASDINIT host command that initialized the emulated disk.
Note also that a few of the test scripts specifically test
compression, so a Hercules built without compression will cause
those tests to fail.
Either or both of of the following compression libraries can be
used with Hercules.
- zlib: Can be used by Hercules to compress both disk and tape
volumes. Available in the software repositories for many
UNIX distributions. Obtain source at:
http://www.zlib.net
- libbz2 Can be used by Hercules to compress both disk and tape
volumes. Available in the software repositories for many
UNIX distributions. Obtain source at:
http://www.bzip.org/
(Windows only) Perl Compatible Regular Expression Support
If you are building on Windows and plan to use the Hercules
Automated Operator (HAO) capability, you must install the PCRE
package to provide regular expression support for HAO.
On UNIX systems, the Hercules Automated Operator uses the regular
expression support built into the host system.
You can obtain PCRE here:
http://www.airesoft.co.uk/pcre
Download version 8.20.
Stand Alone Tool Kit (SATK)
If you plan to develop Hercules further, SATK provides a very
functional mainframe assembler that runs on your workstation.
SATK generates object code in .core file format, which can be
used when developing test cases for any changes you may make
to Hercules.
Find SATK and its documentation here:
https://github.com/s390guy/satk
SATK requires Python, which may be found here:
https://www.python.org/
RECOMMENDED DIRECTORY STRUCTURE
The following recommended directory structure is used for an
out-of-source build for UNIX. (Windows is built in-source, but
all build activities are in directories separate from the Hercules
source and distribution materials.)
<topdir>/hyperion/ # Hyperion source (see Note 1.)
/winbuild/ # Windows-only: support packages
/SoftFloat-3a # SoftFloat 3a For Hercules source
/<arch>/hyperion/ # Hyperion build/install directory
/<arch>/s3fh # S3FH install dir
# ..includes copyright notices
/<arch>/s3fh/lib # contains S3FH s3fhFloat.lib
/<arch>/s3fh/include # contains S3FH public headers
/<arch>/s3fh.release # S3FH Release build dir
/<arch>/s3fh.debug # S3FH Debug build dir
Two notes for for UNIX users:
1) If you wish to use a structure other than the above to store the
packages required to build Hercules, use symbolic links to map
your actual structure into the structure detailed above.
2) If, after having built Hercules, you elect to move the directory
structure, in other words, change <topdir>, delete the contents
of the build directories and rebuild Hercules. Configure
populates the .deps directory of the build directory with full
path names and does not change them if the directory moves.
Windows users will need to turn the slashes the other way.
The winbuild directory is the top of a tree containing three packages
commonly available in UNIX but which must be installed for Hercules
on Windows.
<topdir> can be anything you wish, but Hercules is suggested. This
directory can be placed anywhere you have read-write permissions,
consistent with common sense and the requirements of your host
system.
Replace <arch> as follows:
- Windows: You must use the value of the %PROCESSOR-ARCHITECTURE%
environment variable. If you do not, you will need to follow
the instructions in README.BuildWIN.txt to point the build process
at the SoftFloat 3a For Hercules Library.
- UNIX: It is recommended but not required to use the value returned
by uname -m.
Other directory structures might be used, but you are on your
own. The above structure is the supported structure.
BUILD SOFTFLOAT 3A FOR HERCULES
Windows users who wish to avoid building SoftFloat 3a For Hercules
may instead download an installable file containing binaries and
public headers in the correct directory structure from here:
https://github.com/hercules-390/SoftFloat-3a/releases/download/v1.0.1/SF3a4Herc.exe
You can find source for SoftFloat 3a For Hercules here:
https://github.com/hercules-390/SoftFloat-3a/releases/latest
The document BUILDING.txt in that repository has detailed build
instructions.
To build SoftFloat on UNIX using the default directory structure and
configuration options, change directory to the SoftFloat source
directory and issue the command "1Stop".
You only need to build SoftFloat 3a For Hercules once, even if you
build Hercules multiple times. A rebuild of SoftFloat 3a For
Hercules is required only if you are recreating the entire build
directory structure, are developing SoftFloat 3a For Hercules, or
need an updated version of the package.
Note that while SoftFloat 3a For Hercules is based on John Hauser's
SoftFloat package, version 3a, it is not the same as that package.
it has been modified as needed to implement the specifics of IBM's
implementation of binary floating point arithmetic based on the
IEEE 754 standard. (Note that IBM implements elements of both the
1985 and 2008 versions of IEEE 754.)
BUILD HERCULES FOR YOUR HOST PLATFORM
Instructions for this can be found in the following host platform
specific README files:
For UNIX:
README.BuildUNIX.txt - For all UNIX-like platforms, including OS/X
For Windows:
README.BuildWIN.txt - For all supported versions of Windows, both
32-bit and 64-bit.
Rewritten by Stephen Orso, stephen.orso@yahoo.com, late 2016.
-----------------------------------------------------------------------