When there is a need for clearing out old packages can this report be created.

It lists all packages and task sequences not being referenced from any advertisment.

Create a report with the following query:

select  v_Package.PackageID, v_Package.Name,v_Package.SourceVersion,v_Package.SourceDate 
from dbo.v_package 
Where 
packageID not in (select PackageID from dbo.v_Advertisement)and 
PackageID not in (SELECT ReferencePackageID FROM v_TaskSequenceReferencesInfo) and 
v_Package.name not like '%deploy%' and (V_package.PackageType ='0' or V_package.PackageType ='4')

group by v_Package.PackageID, v_Package.Name,v_Package.SourceVersion,v_Package.SourceDate

order by v_Package.Name