diff options
| author | Sean Paul <seanpaul@chromium.org> | 2017-06-27 11:36:28 -0400 |
|---|---|---|
| committer | Sean Paul <seanpaul@chromium.org> | 2017-06-27 11:36:28 -0400 |
| commit | c048c984de38d906bb0df56ec2ae90eafc123d0a (patch) | |
| tree | 4e670e712aeedcaf2e2193b64f9120e03320e01c /scripts/Makefile.headersinst | |
| parent | 38cb266ad1a24e037220dc563ab46364595b17b6 (diff) | |
| parent | 6d61e70ccc21606ffb8a0a03bd3aba24f659502b (diff) | |
Merge remote-tracking branch 'airlied/drm-next' into drm-misc-next-fixes
Backmerge drm-next with rc7
Diffstat (limited to 'scripts/Makefile.headersinst')
| -rw-r--r-- | scripts/Makefile.headersinst | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/scripts/Makefile.headersinst b/scripts/Makefile.headersinst index ce753a408c56..c583a1e1bd3c 100644 --- a/scripts/Makefile.headersinst +++ b/scripts/Makefile.headersinst @@ -14,7 +14,15 @@ __headers: include scripts/Kbuild.include srcdir := $(srctree)/$(obj) -subdirs := $(patsubst $(srcdir)/%/.,%,$(wildcard $(srcdir)/*/.)) + +# When make is run under a fakechroot environment, the function +# $(wildcard $(srcdir)/*/.) doesn't only return directories, but also regular +# files. So, we are using a combination of sort/dir/wildcard which works +# with fakechroot. +subdirs := $(patsubst $(srcdir)/%/,%,\ + $(filter-out $(srcdir)/,\ + $(sort $(dir $(wildcard $(srcdir)/*/))))) + # caller may set destination dir (when installing to asm/) _dst := $(if $(dst),$(dst),$(obj)) |
