Why does p mean −log(x)?
According to the international standard ISO 80000 Quantities and units – Part 9: Physical chemistry and molecular physics, the symbol $\mathrm p$ is interpreted as an operator $(\mathrm px=-\lg x)$. It is used in particular (but not only) in the definition of the quantity $\mathrm{pH}$:

$$\mathrm{pH}=\mathrm pa_{\ce{H+}}=-\lg\left( a_{\ce{H+}}\right)=-\lg\left(m_{\ce{H+}}\gamma_{\mathrm m,\ce{H+}}/m^\circ\right).$$

where $a_{\ce{H+}}$ is the activity of $\ce{H+}$ in solution and $\gamma_{\mathrm m,\ce{H+}}$ is the activity coefficient of $\ce{H+}$ on the molality basis at molality $m_{\ce{H+}}$. The standard molality $m^\circ$ is chosen to be equal to $1\ \mathrm{mol\cdot kg^{-1}}$.

The definition of $\mathrm p$ (and $\mathrm{pH}$) given by ISO is actually quoted from IUPAC Quantities, Units and Symbols in Physical Chemistry (Green Book).

In its current form, this definition can be traced back to a recommendation given in
  R. G. Bates and E. A. Guggenheim
  Report on the standardization of pH and related terminology
  Pure Appl. Chem., 1960, Vol. 1, No. 1, pp. 163–168
  http://dx.doi.org/10.1351/pac196001010163
which reads


  There already exists international agreement that $\mathrm{pH}$ should be written and printed on line in roman type. We recommend that, with the unique exception of $\mathrm{pH}$, the operator $\mathrm p$ (printed in roman) should denote $-\log_{10}$.
  For example
  $\mathrm p m_\mathrm H$ means $-\log_{10}m_\mathrm H$
  (…)
  where $m$ denotes molality (…)