- add `--interaction=batchmode` to pdflatex call

avoids waiting for input

- use sphinx.package_dir to find texinputs

this can vary, e.g. for debian installs it is /usr/share/sphinx

closes #3894