Add a method for generating pagination meta links.

Backport of https://github.com/cakephp/cakephp/pull/5046 for 2.6