A critical point approach to boundary value problems on the real line. (February 2018)