A compilation is a file in the XML format, which contains a list of tracks with their cue points. Each track refers to an external media resource, either via a file path on the local file system or to an online resource via an URL. The content of the media file is not part of the compilation.
XML Compilation files are small in size and avoid any issues with possible copyright infringements. The recipient of an XML compilation will need provide or download the media files themselves.
A package, also known as ZIP compilation, is a ZIP archive (a single file), containing an XML compilation, plus the referenced media files. This allows distributing ready-to-use compilations as a single file.
A package can grow large, depending on the media files used. You might want to convert the media files to a suitable format beforehand. Also, when distributing, you are responsible for observing any licenses of the included media files.