Good way is check /var/log/dpkg.log when something already goes wrong.
Also:
man dpkg
say:
-Doctal, --debug=octal
Switch debugging on. octal is formed by bitwise-oring desired
values together from the list below (note that these values may
change in future releases). -Dh or --debug=help display these
debugging values.
Number Description
1 Generally helpful progress information
2 Invocation and status of maintainer scripts
10 Output for each file processed
100 Lots of output for each file processed
20 Output for each configuration file
200 Lots of output for each configuration file
40 Dependencies and conflicts
400 Lots of dependencies/conflicts output
10000 Trigger activation and processing
20000 Lots of output regarding triggers
40000 Silly amounts of output regarding triggers
1000 Lots of drivel about e.g. the dpkg/info dir
2000 Insane amounts of drivel