$ sudo port install [any-package] Error: Unable to execute port: invalid command name "configure.cppflags"
I did some searching around and found the Portfile was setting the CPPFLAGS incorrectly. The fix was to edit this file (split the long file name):
/opt/local/var/db/dports/sources/ \ rsync.rsync.darwinports.org_dpupdate_dports/ \ devel/gettext/Portfile # find this line. # configure.cppflags -no-cpp-precomp # and replace it with this line. # configure.env CPPFLAGS="-no-cpp-precomp"