Skip to content

Commit e9ab86c

Browse files
Renaming SearchProperties to LinkProperties
1 parent fa4e12c commit e9ab86c

File tree

6 files changed

+25
-20
lines changed

6 files changed

+25
-20
lines changed

DefaultYAMLs/DefaultScriptInfo.yaml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,16 +50,21 @@ Dependencies:
5050
IncludePaths:
5151
- "src/include"
5252

53-
# TODO: Maybe rename to LinkSearchProperties?
5453
# (Optional if Header type) Searchable properties of the dependency
55-
SearchProperties:
54+
LinkProperties:
5655
# Properties for searching the library binary for the profile
5756
"g++":
5857
# The library name to be searched for when linking against the script
5958
SearchLibraryNames: ["lib1"]
6059

60+
# TODO(NOW): Add option to exclude names
61+
6162
# The path (relative to the dependency folder) to be searched for the dependency binaries
6263
SearchDirectories: ["./build"]
64+
65+
# TODO(NOW): Add additional link option?
66+
67+
6368

6469
# (Optional) List of setup commands for the supported platforms
6570
Setup:

DefaultYAMLs/ScriptInfoSchema.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@
137137
"items": { "type":"string" },
138138
"description": "Paths to be added to include paths"
139139
},
140-
"SearchProperties":
140+
"LinkProperties":
141141
{
142142
"type": "object",
143143
"patternProperties":
@@ -200,7 +200,7 @@
200200
"Platforms",
201201
"Source",
202202
"LibraryType",
203-
"SearchProperties"
203+
"LinkProperties"
204204
],
205205
"uniqueItems": true
206206
}

Include/runcpp2/Data/DependencyInfo.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
#include "runcpp2/Data/DependencyLibraryType.hpp"
55
#include "runcpp2/Data/DependencySource.hpp"
6-
#include "runcpp2/Data/DependencySearchProperty.hpp"
6+
#include "runcpp2/Data/DependencyLinkProperty.hpp"
77
#include "runcpp2/Data/DependencySetup.hpp"
88
#include "runcpp2/Data/ParseCommon.hpp"
99

@@ -21,7 +21,7 @@ namespace runcpp2
2121
DependencyLibraryType LibraryType;
2222
std::vector<std::string> IncludePaths;
2323
std::vector<std::string> AbsoluteIncludePaths;
24-
std::unordered_map<ProfileName, DependencySearchProperty> SearchProperties;
24+
std::unordered_map<ProfileName, DependencyLinkProperty> LinkProperties;
2525
std::unordered_map<PlatformName, DependencySetup> Setup;
2626

2727
bool ParseYAML_Node(YAML::Node& node);

Include/runcpp2/Data/DependencySearchProperty.hpp renamed to Include/runcpp2/Data/DependencyLinkProperty.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
#ifndef RUNCPP2_DATA_DEPENDENCY_SEARCH_PROPERTY_HPP
2-
#define RUNCPP2_DATA_DEPENDENCY_SEARCH_PROPERTY_HPP
1+
#ifndef RUNCPP2_DATA_DEPENDENCY_LINK_PROPERTY_HPP
2+
#define RUNCPP2_DATA_DEPENDENCY_LINK_PROPERTY_HPP
33

44
#include "yaml-cpp/yaml.h"
55
#include <string>
66

77
namespace runcpp2
88
{
9-
class DependencySearchProperty
9+
class DependencyLinkProperty
1010
{
1111
public:
1212
std::vector<std::string> SearchLibraryNames;

Src/runcpp2/Data/DependencyInfo.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ bool runcpp2::DependencyInfo::ParseYAML_Node(YAML::Node& node)
1414
NodeRequirement("Source", YAML::NodeType::Map, true, false),
1515
NodeRequirement("LibraryType", YAML::NodeType::Scalar, true, false),
1616
NodeRequirement("IncludePaths", YAML::NodeType::Sequence, false, true),
17-
NodeRequirement("SearchProperties", YAML::NodeType::Map, false, false),
17+
NodeRequirement("LinkProperties", YAML::NodeType::Map, false, false),
1818
NodeRequirement("Setup", YAML::NodeType::Map, false, true)
1919
};
2020

@@ -60,21 +60,21 @@ bool runcpp2::DependencyInfo::ParseYAML_Node(YAML::Node& node)
6060
IncludePaths.push_back(includePathsNode[i].as<std::string>());
6161
}
6262

63-
if(node["SearchProperties"])
63+
if(node["LinkProperties"])
6464
{
65-
YAML::Node searchPropertiesNode = node["SearchProperties"];
65+
YAML::Node linkPropertiesNode = node["LinkProperties"];
6666

67-
for(auto it = searchPropertiesNode.begin(); it != searchPropertiesNode.end(); ++it)
67+
for(auto it = linkPropertiesNode.begin(); it != linkPropertiesNode.end(); ++it)
6868
{
6969
ProfileName profile = it->first.as<ProfileName>();
70-
DependencySearchProperty property;
70+
DependencyLinkProperty property;
7171
if(!property.ParseYAML_Node(it->second))
7272
{
7373
ssLOG_ERROR("DependencyInfo: Failed to parse SearchProperties");
7474
return false;
7575
}
7676

77-
SearchProperties[profile] = property;
77+
LinkProperties[profile] = property;
7878
}
7979
}
8080

@@ -125,8 +125,8 @@ std::string runcpp2::DependencyInfo::ToString(std::string indentation) const
125125
for(auto it = IncludePaths.begin(); it != IncludePaths.end(); ++it)
126126
out += indentation + " - " + *it + "\n";
127127

128-
out += indentation + " SearchProperties:\n";
129-
for(auto it = SearchProperties.begin(); it != SearchProperties.end(); ++it)
128+
out += indentation + " LinkProperties:\n";
129+
for(auto it = LinkProperties.begin(); it != LinkProperties.end(); ++it)
130130
{
131131
out += indentation + " " + it->first + ":\n";
132132
out += it->second.ToString(indentation + " ");

Src/runcpp2/Data/DependencySearchProperty.cpp renamed to Src/runcpp2/Data/DependencyLinkProperty.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
#include "runcpp2/Data/DependencySearchProperty.hpp"
1+
#include "runcpp2/Data/DependencyLinkProperty.hpp"
22
#include "runcpp2/Data/ParseCommon.hpp"
33
#include "runcpp2/ParseUtil.hpp"
44
#include "ssLogger/ssLog.hpp"
55

6-
bool runcpp2::DependencySearchProperty::ParseYAML_Node(YAML::Node& node)
6+
bool runcpp2::DependencyLinkProperty::ParseYAML_Node(YAML::Node& node)
77
{
88
INTERNAL_RUNCPP2_SAFE_START();
99

@@ -36,7 +36,7 @@ bool runcpp2::DependencySearchProperty::ParseYAML_Node(YAML::Node& node)
3636
INTERNAL_RUNCPP2_SAFE_CATCH_RETURN(false);
3737
}
3838

39-
std::string runcpp2::DependencySearchProperty::ToString(std::string indentation) const
39+
std::string runcpp2::DependencyLinkProperty::ToString(std::string indentation) const
4040
{
4141
std::string out;
4242
out += indentation + "SearchLibraryName: \n";

0 commit comments

Comments
 (0)