Skip to content

Commit 37434d1

Browse files
authored
Print "multiple libraries found for header.h" message only when it really happens. (#478)
1 parent bc6c823 commit 37434d1

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Diff for: legacy/builder/print_used_and_not_used_libraries.go

+3
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,9 @@ func (s *PrintUsedAndNotUsedLibraries) Run(ctx *types.Context) error {
5858
libraryResolutionResults := ctx.LibrariesResolutionResults
5959

6060
for header, libResResult := range libraryResolutionResults {
61+
if len(libResResult.NotUsedLibraries) == 0 {
62+
continue
63+
}
6164
logger.Fprintln(os.Stdout, logLevel, constants.MSG_LIBRARIES_MULTIPLE_LIBS_FOUND_FOR, header)
6265
logger.Fprintln(os.Stdout, logLevel, constants.MSG_LIBRARIES_USED, libResResult.Library.InstallDir)
6366
for _, notUsedLibrary := range libResResult.NotUsedLibraries {

0 commit comments

Comments
 (0)