(PUP-3604) Rework handling of :ensure with a version

If use_version is empty and flavor is set, then we need a double hyphen.