@@ -342,7 +342,7 @@ func findIncludesUntilDone(ctx *types.Context, cache *includeCache, sourceFileQu
342
342
343
343
first := true
344
344
for {
345
- var include string
345
+ var missingIncludeH string
346
346
cache .ExpectFile (sourcePath )
347
347
348
348
includeFolders := ctx .IncludeFolders
@@ -365,7 +365,7 @@ func findIncludesUntilDone(ctx *types.Context, cache *includeCache, sourceFileQu
365
365
var preprocStderr []byte
366
366
367
367
if unchanged && cache .valid {
368
- include = cache .Next ().Include
368
+ missingIncludeH = cache .Next ().Include
369
369
if first && ctx .Verbose {
370
370
ctx .Info (tr ("Using cached library dependencies for file: %[1]s" , sourcePath ))
371
371
}
@@ -380,27 +380,27 @@ func findIncludesUntilDone(ctx *types.Context, cache *includeCache, sourceFileQu
380
380
_ , isExitErr := errors .Cause (preprocErr ).(* exec.ExitError )
381
381
if preprocErr == nil {
382
382
// Preprocessor successful, done
383
- include = ""
383
+ missingIncludeH = ""
384
384
} else if ! isExitErr || preprocStderr == nil {
385
385
// Ignore ExitErrors (e.g. gcc returning
386
386
// non-zero status), but bail out on
387
387
// other errors
388
388
return errors .WithStack (preprocErr )
389
389
} else {
390
- include = IncludesFinderWithRegExp (string (preprocStderr ))
391
- if include == "" && ctx .Verbose {
390
+ missingIncludeH = IncludesFinderWithRegExp (string (preprocStderr ))
391
+ if missingIncludeH == "" && ctx .Verbose {
392
392
ctx .Info (tr ("Error while detecting libraries included by %[1]s" , sourcePath ))
393
393
}
394
394
}
395
395
}
396
396
397
- if include == "" {
397
+ if missingIncludeH == "" {
398
398
// No missing includes found, we're done
399
399
cache .ExpectEntry (sourcePath , "" , nil )
400
400
return nil
401
401
}
402
402
403
- library := ResolveLibrary (ctx , include )
403
+ library := ResolveLibrary (ctx , missingIncludeH )
404
404
if library == nil {
405
405
// Library could not be resolved, show error
406
406
if preprocErr == nil || preprocStderr == nil {
@@ -426,7 +426,7 @@ func findIncludesUntilDone(ctx *types.Context, cache *includeCache, sourceFileQu
426
426
// include path and queue its source files for further
427
427
// include scanning
428
428
ctx .ImportedLibraries = append (ctx .ImportedLibraries , library )
429
- appendIncludeFolder (ctx , cache , sourcePath , include , library .SourceDir )
429
+ appendIncludeFolder (ctx , cache , sourcePath , missingIncludeH , library .SourceDir )
430
430
sourceDirs := library .SourceDirs ()
431
431
for _ , sourceDir := range sourceDirs {
432
432
queueSourceFilesFromFolder (ctx , sourceFileQueue , library , sourceDir .Dir , sourceDir .Recurse )
0 commit comments