OSX/Pkg packages
From Sidvind
First, find package in /Library/Receipts and find the bom-file: /Library/Receipts/<PACKAGE>/Contents/Archive.bom. The bom-file contains information about the packages installed files. OSX ships with two tools to handle bom-files, mkbom and lsbom. To uninstall a .pkg package you can use lsbom to list all files installed and batch remove them by piping to xargs rm or similar.
lsbom Archive.bom -f -l -s Archive.bom
lsbom -f -l -s -pf Archive.bom | (cd /; xargs -n 1 rm)