Okay. I should have done this earlier. I googled the error message and learned to clean...
[chiplocal-3...\ ~]$ sudo port clean --dist expat
Password:
---> Cleaning expat
[chiplocal-3...\ ~]$
[chiplocal-3...\ ~]$ sudo port install gd2
---> Computing dependencies for gd2
---> Fetching expat
---> Attempting to fetch expat-2.0.1.tar.gz from
http://internap.dl.sourceforge.net/expat
---> Verifying checksum(s) for expat
---> Extracting expat
---> Configuring expat
---> Building expat
and so on through the build.
What seems to have happened before was that the fetch of expat was interrupted - it went through 3 different sites before it tried the checksum. I'll bet it really never fetched the tarball at all and the checksum failed because it was never downloaded or partially so. The clean command made it go back to fetch again, whereas some condition before was satisfied even with the failed fetch and successive attempts didn't try to do that.
So. gd2 is installed and I'll mess with it some more tomorrow.
thanks!