Factor out new 'P' module with promise-related helper code.

Change-Id: Ifebaa58a0c3f7b074f3a3571500356107edd2067
Convert SVGs to PDFs with inkscape, and include them in the output.
Add workaround for RGBA SVGs.

Change-Id: Ief87b07d93eb1168f02aee81af2c73bd9a30744d