summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorMichael Weghorn <m.weghorn@posteo.de>2019-07-15 13:01:15 +0200
committerMichael Weghorn <m.weghorn@posteo.de>2019-07-15 15:47:09 +0200
commitde44936e61dbd0a0b1d397717f58319f7c0075d5 (patch)
tree00037a1a78742a691578ecb49ba110be29765d1d /bin
parent50c1032b4d292c26015d102a1aede03a9ed8e555 (diff)
qtcreator: Recursively include module's header files
Recursivley walk the include directories located inside the current module's directory, since includes are basically paths relative to the include directories and can refer to files in subdirectories of the include path, like e.g. #include <extended/AccessibleBrowseBoxBase.hxx> in 'accessibility/source/extended/AccessibleBrowseBoxBase.cxx'. This way, such header files are added to the .pro files and are thus e.g. shown in Qt Creator's project view and can be found by using 'a <FILEANME>' in the Locator. Change-Id: Id74f971b2ffee82203f74a4d444c41166c671920 Reviewed-on: https://gerrit.libreoffice.org/75628 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Diffstat (limited to 'bin')
-rwxr-xr-xbin/gbuild-to-ide9
1 files changed, 5 insertions, 4 deletions
diff --git a/bin/gbuild-to-ide b/bin/gbuild-to-ide
index bcb3ec41ba4a..f08c0fcbc2ce 100755
--- a/bin/gbuild-to-ide
+++ b/bin/gbuild-to-ide
@@ -1694,10 +1694,11 @@ class QtCreatorIntegrationGenerator(IdeIntegrationGenerator):
# List headers files from current lib
for hdir in lib.include:
if hdir.startswith(lib.location):
- for hf in os.listdir(hdir):
- if hf.endswith(('.h', '.hxx', '.hpp', '.hrc')):
- hf_lopath = lopath(os.path.join(hdir, hf))
- headers_list.append(hf_lopath)
+ for dirpath, _, files in os.walk(hdir):
+ for hf in files:
+ if hf.endswith(('.h', '.hxx', '.hpp', '.hrc')):
+ hf_lopath = lopath(os.path.join(dirpath, hf))
+ headers_list.append(hf_lopath)
# List defines
for key, value in lib.defs.items():