0003-build-ensure-target-directory-for-modules-exists.patch 1.2 KB

12345678910111213141516171819202122232425262728293031323334
  1. From 93edc41d3ae60e6ee9b9bbb7cdcc592133521fa3 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: Julien Olivain <ju.o@free.fr>
  10. [Julien: rebase patch on tag 20.7.0]
  11. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
  12. ---
  13. Makefile.moddir_rules | 2 +-
  14. 1 file changed, 1 insertion(+), 1 deletion(-)
  15. diff --git a/Makefile.moddir_rules b/Makefile.moddir_rules
  16. index 795b32c716..7d5e5d241a 100644
  17. --- a/Makefile.moddir_rules
  18. +++ b/Makefile.moddir_rules
  19. @@ -106,7 +106,7 @@ clean::
  20. install:: all
  21. @echo "Installing modules from `basename $(CURDIR)`..."
  22. - @for x in $(LOADABLE_MODS:%=%.so); do $(INSTALL) -m 755 $$x "$(DESTDIR)$(ASTMODDIR)" ; done
  23. + @for x in $(LOADABLE_MODS:%=%.so); do $(INSTALL) -D -m 755 $$x "$(DESTDIR)$(ASTMODDIR)" ; done
  24. ifneq ($(findstring :,$(XMLSTARLET)$(BASH)),:)
  25. @if [ -f .moduleinfo ] ; then \
  26. declare -A DISABLED_MODS ;\
  27. --
  28. 2.45.2