PETSc options can be set on the command line (you'll need to add a few lines to parse them), or you can use, for example:
PETScOptions.set("mat_mumps_icntl_14", 40.0)
The above is for Python. From the C++ interface:
PETScOptions::set("mat_mumps_icntl_14", 40.0);