Return empty dict for list_pkgs(purge_desired=True) with macports

This fixes #16828 and is based on the implementation from brew.py