If you don't want the automatic spacing inserted by align, you should have a look at alignat. (Others have done a better job than I can explaining how to use it, so I will just include an example below of what I think has relatively pleasant spacing.)
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{alignat}{10}
&\text{minimize} &S(f) &=\int_{-\infty}^{\infty} f^{\prime\prime}(x)^2 \, \text{d}x \label{eq:min-energy} \\
&\text{subject~to}\; &f(x_i) &= y_i, \enspace \text{for} \; i=1,\ldots,m \label{eq:interp-cond} \\
& &f^{\prime\prime}(x_1) &= f^{\prime\prime}(x_m)=0 \label{eq:natural-bc} \\
& &f &\in C^2(-\infty,\infty). \label{eq:C2-constraint}
\end{alignat}
\end{document}
Notes:
- After
\text{subject~to} I inserted \;. Because of the f'' on the next line, I find that without the extra space it looks a bit cramped. You may decide otherwise.
- I specified
10 as the mandatory argument for alignat because I am lazy; see the link for explanation.
My personal opinion, however, is that it is better in this case not to align at the equality signs. I think something like
\begin{alignat}{10}
&\text{minimize} &&S(f) =\int_{-\infty}^{\infty} f^{\prime\prime}(x)^2 \, \text{d}x \label{eq:min-energy} \\
& &&f(x_i) = y_i, \enspace \text{for} \; i=1,\ldots,m \label{eq:interp-cond} \\
&\text{subject to}\, \smash{\left\lbrace\vphantom{\begin{array}{l} f \\ f \\ f\end{array}} \right.} &&f^{\prime\prime}(x_1) = f^{\prime\prime}(x_m)=0 \label{eq:natural-bc} \\
& &&f \in C^2(-\infty,\infty). \label{eq:C2-constraint}
\end{alignat}
looks better.

(There are other methods of getting a large brace spanning multiple lines in an alignat, the one given above is a bit of a hack that nonetheless doesn't require any additional packages. If you are willing to be less lazy, the \vphantom{\begin{array}... \end{array}} can be replaced with \rule{0pt}{<height>} with a well-chosen height; 5.5ex for the height seems to work ok.)