Implement alternate chmod_if_needed for SmartOS to work around
bug in bash / test for executable bit when run as root.