Skip to content

Commit

Permalink
Added comments and TODOs
Browse files Browse the repository at this point in the history
  • Loading branch information
cmaglie committed Oct 28, 2024
1 parent dba1f01 commit e26ac36
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions internal/arduino/builder/libraries.go
Original file line number Diff line number Diff line change
Expand Up @@ -161,14 +161,23 @@ func (b *Builder) compileLibrary(library *libraries.Library, includes []string)
b.logger.Info(i18n.Tr(`Compiling library "%[1]s"`, library.Name))
}

// TODO: libraries with "dot_a_linkage=true" or libraries already providing a
// precompiled lib.a needs extra boilerplate to be handled. At the moment
// they are not handled correctly.

var targetArchivedLibrary *paths.Path
if b.librariesBuildCachePath != nil {
archivedLibName := getCachedLibraryArchiveDirName(
b.buildProperties.Get("build.fqbn"),
b.buildProperties.Get("compiler.optimization_flags"),
// TODO: Add included library set here
library.InstallDir,
)

// TODO: if a single library needs a rebuild then all libraries requires a rebuild.
// This means that the `canUseArchivedLib` must be checked for all libraries
// in advance in the `compileLibraries` method.

canUseArchivedLib := func(archivedLib *paths.Path) bool {
if b.onlyUpdateCompilationDatabase || b.clean {
return false
Expand Down

0 comments on commit e26ac36

Please sign in to comment.