Skip to content

Commit 505cc4a

Browse files
committed
Introduce explicit PropertiesMap type
This simplify the use of map[string]string in most cases and remove redundant utility functions. Signed-off-by: Cristian Maglie <[email protected]>
1 parent 583aab1 commit 505cc4a

29 files changed

+177
-149
lines changed

src/arduino.cc/builder/add_missing_build_properties_from_parent_platform_txt_files.go

+6-4
Original file line numberDiff line numberDiff line change
@@ -31,20 +31,22 @@ package builder
3131

3232
import (
3333
"arduino.cc/builder/constants"
34+
"arduino.cc/builder/props"
3435
"arduino.cc/builder/types"
35-
"arduino.cc/builder/utils"
3636
)
3737

3838
type AddMissingBuildPropertiesFromParentPlatformTxtFiles struct{}
3939

4040
func (s *AddMissingBuildPropertiesFromParentPlatformTxtFiles) Run(context map[string]interface{}) error {
4141
packages := context[constants.CTX_HARDWARE].(*types.Packages)
4242
targetPackage := context[constants.CTX_TARGET_PACKAGE].(*types.Package)
43-
buildProperties := context[constants.CTX_BUILD_PROPERTIES].(map[string]string)
43+
buildProperties := context[constants.CTX_BUILD_PROPERTIES].(props.PropertiesMap)
4444

45-
buildProperties = utils.MergeMapsOfStrings(make(map[string]string), packages.Properties, targetPackage.Properties, buildProperties)
45+
newBuildProperties := packages.Properties.Clone()
46+
newBuildProperties.Merge(targetPackage.Properties)
47+
newBuildProperties.Merge(buildProperties)
4648

47-
context[constants.CTX_BUILD_PROPERTIES] = buildProperties
49+
context[constants.CTX_BUILD_PROPERTIES] = newBuildProperties
4850

4951
return nil
5052
}

src/arduino.cc/builder/builder_utils/utils.go

+13-13
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ import (
4242
"strings"
4343
)
4444

45-
func CompileFilesRecursive(objectFiles []string, sourcePath string, buildPath string, buildProperties map[string]string, includes []string, verbose bool, warningsLevel string, logger i18n.Logger) ([]string, error) {
45+
func CompileFilesRecursive(objectFiles []string, sourcePath string, buildPath string, buildProperties props.PropertiesMap, includes []string, verbose bool, warningsLevel string, logger i18n.Logger) ([]string, error) {
4646
objectFiles, err := CompileFiles(objectFiles, sourcePath, false, buildPath, buildProperties, includes, verbose, warningsLevel, logger)
4747
if err != nil {
4848
return nil, utils.WrapError(err)
@@ -63,7 +63,7 @@ func CompileFilesRecursive(objectFiles []string, sourcePath string, buildPath st
6363
return objectFiles, nil
6464
}
6565

66-
func CompileFiles(objectFiles []string, sourcePath string, recurse bool, buildPath string, buildProperties map[string]string, includes []string, verbose bool, warningsLevel string, logger i18n.Logger) ([]string, error) {
66+
func CompileFiles(objectFiles []string, sourcePath string, recurse bool, buildPath string, buildProperties props.PropertiesMap, includes []string, verbose bool, warningsLevel string, logger i18n.Logger) ([]string, error) {
6767
objectFiles, err := compileFilesWithExtensionWithRecipe(objectFiles, sourcePath, recurse, buildPath, buildProperties, includes, ".S", constants.RECIPE_S_PATTERN, verbose, warningsLevel, logger)
6868
if err != nil {
6969
return nil, utils.WrapError(err)
@@ -79,7 +79,7 @@ func CompileFiles(objectFiles []string, sourcePath string, recurse bool, buildPa
7979
return objectFiles, nil
8080
}
8181

82-
func compileFilesWithExtensionWithRecipe(objectFiles []string, sourcePath string, recurse bool, buildPath string, buildProperties map[string]string, includes []string, extension string, recipe string, verbose bool, warningsLevel string, logger i18n.Logger) ([]string, error) {
82+
func compileFilesWithExtensionWithRecipe(objectFiles []string, sourcePath string, recurse bool, buildPath string, buildProperties props.PropertiesMap, includes []string, extension string, recipe string, verbose bool, warningsLevel string, logger i18n.Logger) ([]string, error) {
8383
sources, err := findFilesInFolder(sourcePath, extension, recurse)
8484
if err != nil {
8585
return nil, utils.WrapError(err)
@@ -115,7 +115,7 @@ func findFilesInFolder(sourcePath string, extension string, recurse bool) ([]str
115115
return sources, nil
116116
}
117117

118-
func compileFilesWithRecipe(objectFiles []string, sourcePath string, sources []string, buildPath string, buildProperties map[string]string, includes []string, recipe string, verbose bool, warningsLevel string, logger i18n.Logger) ([]string, error) {
118+
func compileFilesWithRecipe(objectFiles []string, sourcePath string, sources []string, buildPath string, buildProperties props.PropertiesMap, includes []string, recipe string, verbose bool, warningsLevel string, logger i18n.Logger) ([]string, error) {
119119
for _, source := range sources {
120120
objectFile, err := compileFileWithRecipe(sourcePath, source, buildPath, buildProperties, includes, recipe, verbose, warningsLevel, logger)
121121
if err != nil {
@@ -127,8 +127,8 @@ func compileFilesWithRecipe(objectFiles []string, sourcePath string, sources []s
127127
return objectFiles, nil
128128
}
129129

130-
func compileFileWithRecipe(sourcePath string, source string, buildPath string, buildProperties map[string]string, includes []string, recipe string, verbose bool, warningsLevel string, logger i18n.Logger) (string, error) {
131-
properties := utils.MergeMapsOfStrings(make(map[string]string), buildProperties)
130+
func compileFileWithRecipe(sourcePath string, source string, buildPath string, buildProperties props.PropertiesMap, includes []string, recipe string, verbose bool, warningsLevel string, logger i18n.Logger) (string, error) {
131+
properties := buildProperties.Clone()
132132
properties[constants.BUILD_PROPERTIES_COMPILER_WARNING_FLAGS] = properties[constants.BUILD_PROPERTIES_COMPILER_WARNING_FLAGS+"."+warningsLevel]
133133
properties[constants.BUILD_PROPERTIES_INCLUDES] = strings.Join(includes, constants.SPACE)
134134
properties[constants.BUILD_PROPERTIES_SOURCE_FILE] = source
@@ -255,7 +255,7 @@ func nonEmptyString(s string) bool {
255255
return s != constants.EMPTY_STRING
256256
}
257257

258-
func ArchiveCompiledFiles(buildPath string, archiveFile string, objectFiles []string, buildProperties map[string]string, verbose bool, logger i18n.Logger) (string, error) {
258+
func ArchiveCompiledFiles(buildPath string, archiveFile string, objectFiles []string, buildProperties props.PropertiesMap, verbose bool, logger i18n.Logger) (string, error) {
259259
archiveFilePath := filepath.Join(buildPath, archiveFile)
260260
if _, err := os.Stat(archiveFilePath); err == nil {
261261
err = os.Remove(archiveFilePath)
@@ -265,7 +265,7 @@ func ArchiveCompiledFiles(buildPath string, archiveFile string, objectFiles []st
265265
}
266266

267267
for _, objectFile := range objectFiles {
268-
properties := utils.MergeMapsOfStrings(make(map[string]string), buildProperties)
268+
properties := buildProperties.Clone()
269269
properties[constants.BUILD_PROPERTIES_ARCHIVE_FILE] = filepath.Base(archiveFilePath)
270270
properties[constants.BUILD_PROPERTIES_ARCHIVE_FILE_PATH] = archiveFilePath
271271
properties[constants.BUILD_PROPERTIES_OBJECT_FILE] = objectFile
@@ -279,7 +279,7 @@ func ArchiveCompiledFiles(buildPath string, archiveFile string, objectFiles []st
279279
return archiveFilePath, nil
280280
}
281281

282-
func ExecRecipe(properties map[string]string, recipe string, removeUnsetProperties bool, echoCommandLine bool, echoOutput bool, logger i18n.Logger) ([]byte, error) {
282+
func ExecRecipe(properties props.PropertiesMap, recipe string, removeUnsetProperties bool, echoCommandLine bool, echoOutput bool, logger i18n.Logger) ([]byte, error) {
283283
command, err := PrepareCommandForRecipe(properties, recipe, removeUnsetProperties, echoCommandLine, echoOutput, logger)
284284
if err != nil {
285285
return nil, utils.WrapError(err)
@@ -300,14 +300,14 @@ func ExecRecipe(properties map[string]string, recipe string, removeUnsetProperti
300300
return bytes, utils.WrapError(err)
301301
}
302302

303-
func PrepareCommandForRecipe(properties map[string]string, recipe string, removeUnsetProperties bool, echoCommandLine bool, echoOutput bool, logger i18n.Logger) (*exec.Cmd, error) {
303+
func PrepareCommandForRecipe(properties props.PropertiesMap, recipe string, removeUnsetProperties bool, echoCommandLine bool, echoOutput bool, logger i18n.Logger) (*exec.Cmd, error) {
304304
pattern := properties[recipe]
305305
if pattern == constants.EMPTY_STRING {
306306
return nil, utils.ErrorfWithLogger(logger, constants.MSG_PATTERN_MISSING, recipe)
307307
}
308308

309309
var err error
310-
commandLine := props.ExpandPropsInString(properties, pattern)
310+
commandLine := properties.ExpandPropsInString(pattern)
311311
if removeUnsetProperties {
312312
commandLine, err = props.DeleteUnexpandedPropsFromString(commandLine)
313313
if err != nil {
@@ -327,7 +327,7 @@ func PrepareCommandForRecipe(properties map[string]string, recipe string, remove
327327
return command, nil
328328
}
329329

330-
func ExecRecipeCollectStdErr(properties map[string]string, recipe string, removeUnsetProperties bool, echoCommandLine bool, echoOutput bool, logger i18n.Logger) (string, error) {
330+
func ExecRecipeCollectStdErr(properties props.PropertiesMap, recipe string, removeUnsetProperties bool, echoCommandLine bool, echoOutput bool, logger i18n.Logger) (string, error) {
331331
command, err := PrepareCommandForRecipe(properties, recipe, removeUnsetProperties, echoCommandLine, echoOutput, logger)
332332
if err != nil {
333333
return "", utils.WrapError(err)
@@ -339,6 +339,6 @@ func ExecRecipeCollectStdErr(properties map[string]string, recipe string, remove
339339
return string(buffer.Bytes()), nil
340340
}
341341

342-
func RemoveHyphenMDDFlagFromGCCCommandLine(properties map[string]string) {
342+
func RemoveHyphenMDDFlagFromGCCCommandLine(properties props.PropertiesMap) {
343343
properties[constants.BUILD_PROPERTIES_COMPILER_CPP_FLAGS] = strings.Replace(properties[constants.BUILD_PROPERTIES_COMPILER_CPP_FLAGS], "-MMD", "", -1)
344344
}

src/arduino.cc/builder/coan_runner.go

+4-3
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,9 @@ func (s *CoanRunner) Run(context map[string]interface{}) error {
6060
return utils.WrapError(err)
6161
}
6262

63-
buildProperties := context[constants.CTX_BUILD_PROPERTIES].(map[string]string)
64-
properties := utils.MergeMapsOfStrings(make(map[string]string), buildProperties, props.SubTree(props.SubTree(buildProperties, constants.BUILD_PROPERTIES_TOOLS_KEY), constants.COAN))
63+
buildProperties := context[constants.CTX_BUILD_PROPERTIES].(props.PropertiesMap)
64+
properties := buildProperties.Clone()
65+
properties.Merge(buildProperties.SubTree(constants.BUILD_PROPERTIES_TOOLS_KEY).SubTree(constants.COAN))
6566
properties[constants.BUILD_PROPERTIES_SOURCE_FILE] = coanTargetFileName
6667

6768
pattern := properties[constants.BUILD_PROPERTIES_PATTERN]
@@ -70,7 +71,7 @@ func (s *CoanRunner) Run(context map[string]interface{}) error {
7071
}
7172

7273
logger := context[constants.CTX_LOGGER].(i18n.Logger)
73-
commandLine := props.ExpandPropsInString(properties, pattern)
74+
commandLine := properties.ExpandPropsInString(pattern)
7475
command, err := utils.PrepareCommandFilteredArgs(commandLine, filterAllowedArg, logger)
7576

7677
if verbose {

src/arduino.cc/builder/container_find_includes.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ func (s *ContainerFindIncludes) Run(context map[string]interface{}) error {
5555
foldersWithSources.Push(types.SourceFolder{Folder: context[constants.CTX_SKETCH_BUILD_PATH].(string), Recurse: true})
5656
if utils.MapHas(context, constants.CTX_IMPORTED_LIBRARIES) {
5757
for _, library := range context[constants.CTX_IMPORTED_LIBRARIES].([]*types.Library) {
58-
sourceFolders := utils.LibraryToSourceFolder(library)
58+
sourceFolders := types.LibraryToSourceFolder(library)
5959
for _, sourceFolder := range sourceFolders {
6060
foldersWithSources.Push(sourceFolder)
6161
}

src/arduino.cc/builder/ctags/ctags_runner.go

+4-3
Original file line numberDiff line numberDiff line change
@@ -40,19 +40,20 @@ import (
4040
type CTagsRunner struct{}
4141

4242
func (s *CTagsRunner) Run(context map[string]interface{}) error {
43-
buildProperties := context[constants.CTX_BUILD_PROPERTIES].(map[string]string)
43+
buildProperties := context[constants.CTX_BUILD_PROPERTIES].(props.PropertiesMap)
4444
ctagsTargetFilePath := context[constants.CTX_CTAGS_TEMP_FILE_PATH].(string)
4545
logger := context[constants.CTX_LOGGER].(i18n.Logger)
4646

47-
properties := utils.MergeMapsOfStrings(make(map[string]string), buildProperties, props.SubTree(props.SubTree(buildProperties, constants.BUILD_PROPERTIES_TOOLS_KEY), constants.CTAGS))
47+
properties := buildProperties.Clone()
48+
properties.Merge(buildProperties.SubTree(constants.BUILD_PROPERTIES_TOOLS_KEY).SubTree(constants.CTAGS))
4849
properties[constants.BUILD_PROPERTIES_SOURCE_FILE] = ctagsTargetFilePath
4950

5051
pattern := properties[constants.BUILD_PROPERTIES_PATTERN]
5152
if pattern == constants.EMPTY_STRING {
5253
return utils.Errorf(context, constants.MSG_PATTERN_MISSING, constants.CTAGS)
5354
}
5455

55-
commandLine := props.ExpandPropsInString(properties, pattern)
56+
commandLine := properties.ExpandPropsInString(pattern)
5657
command, err := utils.PrepareCommand(commandLine, logger)
5758
if err != nil {
5859
return utils.WrapError(err)

src/arduino.cc/builder/dump_build_properties.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ package builder
3131

3232
import (
3333
"arduino.cc/builder/constants"
34+
"arduino.cc/builder/props"
3435
"arduino.cc/builder/utils"
3536
"fmt"
3637
"sort"
@@ -39,7 +40,7 @@ import (
3940
type DumpBuildProperties struct{}
4041

4142
func (s *DumpBuildProperties) Run(context map[string]interface{}) error {
42-
buildProperties := context[constants.CTX_BUILD_PROPERTIES].(map[string]string)
43+
buildProperties := context[constants.CTX_BUILD_PROPERTIES].(props.PropertiesMap)
4344

4445
keys := utils.KeysOfMapOfString(buildProperties)
4546
sort.Strings(keys)

src/arduino.cc/builder/gcc_preproc_runner.go

+6-3
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ import (
3333
"arduino.cc/builder/builder_utils"
3434
"arduino.cc/builder/constants"
3535
"arduino.cc/builder/i18n"
36+
"arduino.cc/builder/props"
3637
"arduino.cc/builder/types"
3738
"arduino.cc/builder/utils"
3839
"path/filepath"
@@ -86,7 +87,7 @@ func (s *GCCPreprocRunnerForDiscoveringIncludes) Run(context map[string]interfac
8687
return nil
8788
}
8889

89-
func prepareGCCPreprocRecipeProperties(context map[string]interface{}, sourceFilePath string, targetFilePath string) (map[string]string, string, error) {
90+
func prepareGCCPreprocRecipeProperties(context map[string]interface{}, sourceFilePath string, targetFilePath string) (props.PropertiesMap, string, error) {
9091
if targetFilePath != utils.NULLFile() {
9192
preprocPath := context[constants.CTX_PREPROC_PATH].(string)
9293
err := utils.EnsureFolderExists(preprocPath)
@@ -96,8 +97,10 @@ func prepareGCCPreprocRecipeProperties(context map[string]interface{}, sourceFil
9697
targetFilePath = filepath.Join(preprocPath, targetFilePath)
9798
}
9899

99-
buildProperties := utils.GetMapStringStringOrDefault(context, constants.CTX_BUILD_PROPERTIES)
100-
properties := utils.MergeMapsOfStrings(make(map[string]string), buildProperties)
100+
properties := make(props.PropertiesMap)
101+
if p, ok := context[constants.CTX_BUILD_PROPERTIES]; ok {
102+
properties = p.(props.PropertiesMap).Clone()
103+
}
101104

102105
properties[constants.BUILD_PROPERTIES_SOURCE_FILE] = sourceFilePath
103106
properties[constants.BUILD_PROPERTIES_PREPROCESSED_FILE_PATH] = targetFilePath

src/arduino.cc/builder/hardware_loader.go

+11-9
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ func (s *HardwareLoader) Run(context map[string]interface{}) error {
6767
if err != nil {
6868
return utils.WrapError(err)
6969
}
70-
packages.Properties = utils.MergeMapsOfStrings(packages.Properties, hardwarePlatformTxt)
70+
packages.Properties.Merge(hardwarePlatformTxt)
7171

7272
subfolders, err := utils.ReadDirFiltered(folder, utils.FilterDirs)
7373
if err != nil {
@@ -115,7 +115,7 @@ func loadPackage(targetPackage *types.Package, folder string, logger i18n.Logger
115115
if err != nil {
116116
return utils.WrapError(err)
117117
}
118-
targetPackage.Properties = utils.MergeMapsOfStrings(targetPackage.Properties, packagePlatformTxt)
118+
targetPackage.Properties.Merge(packagePlatformTxt)
119119

120120
subfolders, err := utils.ReadDirFiltered(folder, utils.FilterDirs)
121121
if err != nil {
@@ -161,7 +161,7 @@ func getOrCreatePlatform(platforms map[string]*types.Platform, platformId string
161161
targetPlatform.PlatformId = platformId
162162
targetPlatform.Boards = make(map[string]*types.Board)
163163
targetPlatform.Properties = make(map[string]string)
164-
targetPlatform.Programmers = make(map[string]map[string]string)
164+
targetPlatform.Programmers = make(map[string]props.PropertiesMap)
165165

166166
return &targetPlatform
167167
}
@@ -195,13 +195,15 @@ func loadPlatform(targetPlatform *types.Platform, packageId string, folder strin
195195
return utils.WrapError(err)
196196
}
197197

198-
targetPlatform.Properties = utils.MergeMapsOfStrings(make(map[string]string), targetPlatform.Properties, platformTxt, localPlatformProperties)
198+
targetPlatform.Properties = targetPlatform.Properties.Clone()
199+
targetPlatform.Properties.Merge(platformTxt)
200+
targetPlatform.Properties.Merge(localPlatformProperties)
199201

200202
programmersProperties, err := props.SafeLoad(filepath.Join(folder, constants.FILE_PROGRAMMERS_TXT), logger)
201203
if err != nil {
202204
return utils.WrapError(err)
203205
}
204-
targetPlatform.Programmers = utils.MergeMapsOfMapsOfStrings(make(map[string]map[string]string), targetPlatform.Programmers, props.FirstLevelOf(programmersProperties))
206+
targetPlatform.Programmers = props.MergeMapsOfProperties(make(map[string]props.PropertiesMap), targetPlatform.Programmers, programmersProperties.FirstLevelOf())
205207

206208
return nil
207209
}
@@ -227,15 +229,15 @@ func loadBoards(boards map[string]*types.Board, packageId string, platformId str
227229
return utils.WrapError(err)
228230
}
229231

230-
properties = utils.MergeMapsOfStrings(properties, localProperties)
232+
properties = properties.Merge(localProperties)
231233

232-
propertiesByBoardId := props.FirstLevelOf(properties)
234+
propertiesByBoardId := properties.FirstLevelOf()
233235
delete(propertiesByBoardId, constants.BOARD_PROPERTIES_MENU)
234236

235237
for boardId, properties := range propertiesByBoardId {
236238
properties[constants.ID] = boardId
237239
board := getOrCreateBoard(boards, boardId)
238-
board.Properties = utils.MergeMapsOfStrings(board.Properties, properties)
240+
board.Properties.Merge(properties)
239241
boards[boardId] = board
240242
}
241243

@@ -249,7 +251,7 @@ func getOrCreateBoard(boards map[string]*types.Board, boardId string) *types.Boa
249251

250252
board := types.Board{}
251253
board.BoardId = boardId
252-
board.Properties = make(map[string]string)
254+
board.Properties = make(props.PropertiesMap)
253255

254256
return &board
255257
}

src/arduino.cc/builder/includes_finder_with_gcc.go

+6-2
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ import (
3333
"arduino.cc/builder/builder_utils"
3434
"arduino.cc/builder/constants"
3535
"arduino.cc/builder/i18n"
36+
"arduino.cc/builder/props"
3637
"arduino.cc/builder/utils"
3738
"strings"
3839
)
@@ -42,7 +43,10 @@ type IncludesFinderWithGCC struct {
4243
}
4344

4445
func (s *IncludesFinderWithGCC) Run(context map[string]interface{}) error {
45-
buildProperties := utils.GetMapStringStringOrDefault(context, constants.CTX_BUILD_PROPERTIES)
46+
buildProperties := make(props.PropertiesMap)
47+
if p, ok := context[constants.CTX_BUILD_PROPERTIES]; ok {
48+
buildProperties = p.(props.PropertiesMap).Clone()
49+
}
4650
verbose := context[constants.CTX_VERBOSE].(bool)
4751
logger := context[constants.CTX_LOGGER].(i18n.Logger)
4852

@@ -53,7 +57,7 @@ func (s *IncludesFinderWithGCC) Run(context map[string]interface{}) error {
5357
includesParams = strings.Join(includes, " ")
5458
}
5559

56-
properties := utils.MergeMapsOfStrings(make(map[string]string), buildProperties)
60+
properties := buildProperties.Clone()
5761
properties[constants.BUILD_PROPERTIES_SOURCE_FILE] = s.SourceFile
5862
properties[constants.BUILD_PROPERTIES_INCLUDES] = includesParams
5963
builder_utils.RemoveHyphenMDDFlagFromGCCCommandLine(properties)

src/arduino.cc/builder/includes_to_include_folders.go

+4-3
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ package builder
3131

3232
import (
3333
"arduino.cc/builder/constants"
34+
"arduino.cc/builder/props"
3435
"arduino.cc/builder/types"
3536
"arduino.cc/builder/utils"
3637
"path/filepath"
@@ -67,7 +68,7 @@ func (s *IncludesToIncludeFolders) Run(context map[string]interface{}) error {
6768
for _, newlyImportedLibrary := range newlyImportedLibraries {
6869
if !sliceContainsLibrary(importedLibraries, newlyImportedLibrary) {
6970
importedLibraries = append(importedLibraries, newlyImportedLibrary)
70-
sourceFolders := utils.LibraryToSourceFolder(newlyImportedLibrary)
71+
sourceFolders := types.LibraryToSourceFolder(newlyImportedLibrary)
7172
for _, sourceFolder := range sourceFolders {
7273
foldersWithSources.Push(sourceFolder)
7374
}
@@ -76,15 +77,15 @@ func (s *IncludesToIncludeFolders) Run(context map[string]interface{}) error {
7677

7778
context[constants.CTX_IMPORTED_LIBRARIES] = importedLibraries
7879

79-
buildProperties := context[constants.CTX_BUILD_PROPERTIES].(map[string]string)
80+
buildProperties := context[constants.CTX_BUILD_PROPERTIES].(props.PropertiesMap)
8081
verbose := context[constants.CTX_VERBOSE].(bool)
8182
includeFolders := resolveIncludeFolders(newlyImportedLibraries, buildProperties, verbose)
8283
context[constants.CTX_INCLUDE_FOLDERS] = includeFolders
8384

8485
return nil
8586
}
8687

87-
func resolveIncludeFolders(importedLibraries []*types.Library, buildProperties map[string]string, verbose bool) []string {
88+
func resolveIncludeFolders(importedLibraries []*types.Library, buildProperties props.PropertiesMap, verbose bool) []string {
8889
var includeFolders []string
8990
includeFolders = append(includeFolders, buildProperties[constants.BUILD_PROPERTIES_BUILD_CORE_PATH])
9091
if buildProperties[constants.BUILD_PROPERTIES_BUILD_VARIANT_PATH] != constants.EMPTY_STRING {

0 commit comments

Comments
 (0)