Package.compress_package: fix for files, period in name

* If a period is in the name of a directory package that is being
  compressed, os.path.splitext() splits the name of the directory
  as though it were a file extension.
* If full_path was a file and not a directory, the rsplit and subsequent
  join produces incorrect results, e.g. for /path/to/aip/name.7z:
  /path/to/aip/.7z instead of /path/to/aip/

Refs #7102.
This won't work as expected if ```full_path = '/path/to/aip/aip-uuid/'``` (trailing /).  However, the old code won't work properly in that case either (```os.path.basename``` returns ''), so we'll just have to ensure directories *don't* end with /.