updated mysqldump fucntion to dump --routines for versions that support it