# z/OS: the BPX environment variables that steer spawn() must reach the # child untouched; zash adds no policy of its own. _BPX_SHAREAS=YES; export _BPX_SHAREAS /bin/sh -c 'echo "shareas=$_BPX_SHAREAS"' _BPX_SHAREAS=NO /bin/sh -c 'echo "shareas=$_BPX_SHAREAS"' /bin/sh -c 'echo "shareas=$_BPX_SHAREAS"' unset _BPX_SHAREAS /bin/sh -c 'echo "shareas=[${_BPX_SHAREAS-unset}]"' _BPX_SPAWN_SCRIPT=YES; export _BPX_SPAWN_SCRIPT printf '#!/bin/sh\necho "spawned script $1"\n' >s1; chmod +x s1; ./s1 arg printf 'echo "no magic $1"\n' >s2; chmod +x s2; ./s2 arg unset _BPX_SPAWN_SCRIPT ./s1 again; ./s2 again _BPX_BATCH_SPAWN=x /bin/sh -c 'echo "[$_BPX_BATCH_SPAWN]"' STEPLIB=none /bin/sh -c 'echo "steplib=$STEPLIB"'