0005-build-ensure-target-directory-for-modules-exists.patch 1.1 KB

1234567891011121314151617181920212223242526272829303132
  1. From 933b2554a40f932571bdbdbb5217cda3e35fd61f Mon Sep 17 00:00:00 2001
  2. From: "Yann E. MORIN" <yann.morin.1998@free.fr>
  3. Date: Mon, 27 Nov 2017 12:52:52 +0100
  4. Subject: [PATCH] build: ensure target directory for modules exists
  5. Currently, in highly-parallel builds, it is possible that installing
  6. modules fails because the target directory does not exist yet.
  7. We fix that by instructing $(INSTALL) to create the destination directory
  8. first.
  9. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
  10. ---
  11. Makefile.moddir_rules | 2 +-
  12. 1 file changed, 1 insertion(+), 1 deletion(-)
  13. diff --git a/Makefile.moddir_rules b/Makefile.moddir_rules
  14. index 59190bece9..b73153a9a5 100644
  15. --- a/Makefile.moddir_rules
  16. +++ b/Makefile.moddir_rules
  17. @@ -110,7 +110,7 @@ clean::
  18. install:: all
  19. @echo "Installing modules from `basename $(CURDIR)`..."
  20. - @for x in $(LOADABLE_MODS:%=%.so); do $(INSTALL) -m 755 $$x "$(DESTDIR)$(ASTMODDIR)" ; done
  21. + @for x in $(LOADABLE_MODS:%=%.so); do $(INSTALL) -D -m 755 $$x "$(DESTDIR)$(ASTMODDIR)" ; done
  22. ifneq ($(findstring :,$(XMLSTARLET)$(BASH)),:)
  23. @if [ -f .moduleinfo ] ; then \
  24. declare -A DISABLED_MODS ;\
  25. --
  26. 2.11.0