Configure compiler environment for MacPorts boost.

If we are running on Mac OS X if C++ compiler cannot see boost headers,
while MacPorts boost is installed, adjust CPATH and LIBRARY_PATH to
find MacPorts boost.  We cannot possibly handle all MacPorts
misconfigurations, but this should catch the most common failure.
Add macports installation command.
Factor installation of pth and scripts to shell functions.

Do not prompt for the script path if there are no scripts to install.