2016-09-19 11:50:08 +08:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <vector>
|
|
|
|
#include <unordered_map>
|
|
|
|
|
|
|
|
namespace vcpkg
|
|
|
|
{
|
2016-11-05 16:02:15 +08:00
|
|
|
struct triplet;
|
|
|
|
|
|
|
|
struct dependency
|
|
|
|
{
|
|
|
|
std::string name;
|
|
|
|
std::string qualifier;
|
|
|
|
};
|
|
|
|
|
|
|
|
std::ostream& operator<<(std::ostream& os, const dependency& p);
|
|
|
|
|
2016-09-19 11:50:08 +08:00
|
|
|
struct SourceParagraph
|
|
|
|
{
|
|
|
|
SourceParagraph();
|
|
|
|
|
2016-11-03 11:26:52 +08:00
|
|
|
explicit SourceParagraph(std::unordered_map<std::string, std::string> fields);
|
2016-09-19 11:50:08 +08:00
|
|
|
|
|
|
|
std::string name;
|
|
|
|
std::string version;
|
|
|
|
std::string description;
|
|
|
|
std::string maintainer;
|
2016-11-05 16:02:15 +08:00
|
|
|
std::vector<dependency> depends;
|
2016-09-19 11:50:08 +08:00
|
|
|
};
|
2016-11-05 16:02:15 +08:00
|
|
|
|
|
|
|
std::vector<std::string> filter_dependencies(const std::vector<vcpkg::dependency>& deps, const triplet& t);
|
|
|
|
|
|
|
|
std::vector<vcpkg::dependency> expand_qualified_dependencies(const std::vector<std::string>& depends);
|
|
|
|
std::vector<std::string> parse_depends(const std::string& depends_string);
|
2016-09-19 11:50:08 +08:00
|
|
|
}
|