2016-09-19 11:50:08 +08:00
|
|
|
#include "SourceParagraph.h"
|
|
|
|
#include "vcpkglib_helpers.h"
|
|
|
|
|
|
|
|
using namespace vcpkg::details;
|
|
|
|
|
|
|
|
vcpkg::SourceParagraph::SourceParagraph() = default;
|
|
|
|
|
2016-09-27 12:12:04 +08:00
|
|
|
vcpkg::SourceParagraph::SourceParagraph(const std::unordered_map<std::string, std::string>& fields):
|
|
|
|
name(required_field(fields, "Source")),
|
|
|
|
version(required_field(fields, "Version")),
|
|
|
|
description(optional_field(fields, "Description")),
|
|
|
|
maintainer(optional_field(fields, "Maintainer"))
|
2016-09-19 11:50:08 +08:00
|
|
|
{
|
2016-09-27 12:12:04 +08:00
|
|
|
std::string deps = optional_field(fields, "Build-Depends");
|
2016-11-03 10:39:45 +08:00
|
|
|
this->depends = parse_depends(deps);
|
2016-09-19 11:50:08 +08:00
|
|
|
}
|