mirror of
https://github.com/mappu/miqt.git
synced 2024-12-22 08:58:37 +00:00
genbindings/main: support parsing a single header instead of a directory
This commit is contained in:
parent
5afa94f2cc
commit
20f6d7878b
@ -130,8 +130,12 @@ func generate(packageName string, srcDirs []string, clangBin string, cflags []st
|
||||
|
||||
var includeFiles []string
|
||||
for _, srcDir := range srcDirs {
|
||||
if strings.HasSuffix(srcDir, `.h`) {
|
||||
includeFiles = append(includeFiles, srcDir) // single .h
|
||||
} else {
|
||||
includeFiles = append(includeFiles, findHeadersInDir(srcDir)...)
|
||||
}
|
||||
}
|
||||
|
||||
log.Printf("Found %d header files to process.", len(includeFiles))
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user