mirror of
https://github.com/cemu-project/vcpkg.git
synced 2025-02-23 11:07:10 +01:00
[vcpkg] Fix build command for packages that depend of features
Signed-off-by: Squareys <squareys@googlemail.com>
This commit is contained in:
parent
16faed6785
commit
f1ce125a28
@ -104,11 +104,11 @@ namespace vcpkg::Build
|
|||||||
struct ExtendedBuildResult
|
struct ExtendedBuildResult
|
||||||
{
|
{
|
||||||
ExtendedBuildResult(BuildResult code);
|
ExtendedBuildResult(BuildResult code);
|
||||||
ExtendedBuildResult(BuildResult code, std::vector<PackageSpec>&& unmet_deps);
|
ExtendedBuildResult(BuildResult code, std::vector<FeatureSpec>&& unmet_deps);
|
||||||
ExtendedBuildResult(BuildResult code, std::unique_ptr<BinaryControlFile>&& bcf);
|
ExtendedBuildResult(BuildResult code, std::unique_ptr<BinaryControlFile>&& bcf);
|
||||||
|
|
||||||
BuildResult code;
|
BuildResult code;
|
||||||
std::vector<PackageSpec> unmet_dependencies;
|
std::vector<FeatureSpec> unmet_dependencies;
|
||||||
std::unique_ptr<BinaryControlFile> binary_control_file;
|
std::unique_ptr<BinaryControlFile> binary_control_file;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -267,13 +267,16 @@ namespace vcpkg::Build
|
|||||||
|
|
||||||
const Triplet& triplet = config.triplet;
|
const Triplet& triplet = config.triplet;
|
||||||
{
|
{
|
||||||
std::vector<PackageSpec> missing_specs;
|
std::vector<FeatureSpec> missing_specs;
|
||||||
for (auto&& dep : filter_dependencies(config.scf.core_paragraph->depends, triplet))
|
for (auto&& dep : filter_dependencies(config.scf.core_paragraph->depends, triplet))
|
||||||
{
|
{
|
||||||
auto dep_spec = PackageSpec::from_name_and_triplet(dep, triplet).value_or_exit(VCPKG_LINE_INFO);
|
auto dep_specs = FeatureSpec::from_strings_and_triplet({dep}, triplet);
|
||||||
if (!status_db.is_installed(dep_spec))
|
for (auto&& feature : dep_specs)
|
||||||
{
|
{
|
||||||
missing_specs.push_back(std::move(dep_spec));
|
if (!status_db.is_installed(feature))
|
||||||
|
{
|
||||||
|
missing_specs.push_back(std::move(feature));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Fail the build if any dependencies were missing
|
// Fail the build if any dependencies were missing
|
||||||
@ -600,7 +603,7 @@ namespace vcpkg::Build
|
|||||||
: code(code), binary_control_file(std::move(bcf))
|
: code(code), binary_control_file(std::move(bcf))
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
ExtendedBuildResult::ExtendedBuildResult(BuildResult code, std::vector<PackageSpec>&& unmet_deps)
|
ExtendedBuildResult::ExtendedBuildResult(BuildResult code, std::vector<FeatureSpec>&& unmet_deps)
|
||||||
: code(code), unmet_dependencies(std::move(unmet_deps))
|
: code(code), unmet_dependencies(std::move(unmet_deps))
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user