cmExportPackageInfoGenerator: Refactor extracting requirements Refactor the helper that parses requirement lists from a lambda to a freestanding member function. This will enable its use in other code.