zeromq/libzmq — pull request #1136 by ewen-naos-nz (2014-07-22 05:18:10+00:00)
Title: z/OS UNIX System Services port

Creates builds/zos directory with preconfigured "platform.hpp" for z/OS UNIX System Services, as well as build scripts to build libzmq as static and dynamic library. Also includes "buildtests" and "runtests" to build and run the test suite in tests/. All source is built with the IBM XL C/C++ compiler.

builds/zos/README.md describes building the ZeroMQ library on z/OS UNIX System Services, as well as basic usage and porting notes. As z/OS UNIX System Services does not have a port of libsodium, CURVE security is automatically disabled, and libpgm is not used either (as also has not been ported).

On z/OS UNIX System Services all but two of the basic tests pass (aside from the CURVE test which does nothing because libsodium is not installed):

[....]
Assertion failed: rc == 0, file: ./test_abstract_ipc.cpp, line: 31
CEE5207E The signal SIGABRT was received.
XFAIL: test_abstract_ipc
[....]
(./thread.cpp:91)
CEE5207E The signal SIGABRT was received.
CEE5214S The signal SIGALRM was received.
XFAIL: test_fork
======================================================
All 43 tests behaved as expected (2 expected failures)
======================================================

test_abstract_ipc is known to only work on Linux. test_fork relies on the ability to use pthread_create() both before and after fork(), which is not portable (further detail is provided in README.md).

An updated test_fork.cpp is provided in this directory (which is used on z/OS by the build scripts provided), which adds an alarm() call to terminate the test_fork test run if it is not successful in 5 seconds; otherwise the test run will never complete on platforms for which test_fork fails. (It may be appropriate to put this updated test in the man tests/* directory, but that is not done in this pull request.)

Tested compiled and run in ILP32 (amode=31) and LP64 (amode=64), as both static library and dynamic library.