hercules-390 / hyperion

Hercules 390
Other
246 stars 69 forks source link

Unable to build Hercules on Solaris 11 #230

Closed srorso closed 6 years ago

srorso commented 7 years ago

Minor issues prevent building Hercules on Solaris. Specifically:

When the above issues are patched, Hercules builds cleanly (using CMake) and can IPL DOS/360.

srorso commented 7 years ago

The last item above, "... runtest script is unable to find ...," is due to the Solaris Bourne Shell /bin/sh not supporting the -n option of the echo command. The runtest script uses echo -n to determine whether command line arguments should be interpreted as positional or as labeled (-) flags. See the following:

srorso@solaris113:~$ echo $SHELL
/usr/bin/bash
srorso@solaris113:~$ type echo
echo is a shell builtin
srorso@solaris113:~$ echo -n sample!
sample!srorso@solaris113:~$ /bin/sh
srorso@solaris113:~$ type echo
echo is a shell builtin
srorso@solaris113:~$ echo -n sample!                                                                              
-n sample!
srorso@solaris113:~$

The FreeBSD 11 Bourne Shell echo builtin does support -n, e.g.,

login as: srorso
Using keyboard-interactive authentication.
Password for srorso@FreeBSD11:
Last login: Thu Jul 13 11:06:45 2017
FreeBSD 11.0-RELEASE-p9 (GENERIC) #0: Tue Apr 11 08:48:40 UTC 2017

Welcome to FreeBSD!
$ echo -n sample
sample$ type echo
echo is a shell builtin
$ echo $SHELL
/bin/sh
$

Removing -n from the echo command restores runtest functionality on Solaris. Testing of -n removal is needed on other platforms.

srorso commented 6 years ago

Addressed in d05c651.