MacPorts installation guide literally tells you to install XCode Commandline Tools before even using them: https://guide.macports.org/#installing
The question of "why the he'll do I need to download 670 MB of unknown junk before installing tools that are not even Apple's" remains