mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-18 11:24:01 +00:00
Makefile.rules: Let OPTIONAL_PARALLEL_DIRS accept out-of-tree absolute path.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142101 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -806,7 +806,7 @@ endif
|
|||||||
# Handle the OPTIONAL_PARALLEL_DIRS options for optional parallel construction
|
# Handle the OPTIONAL_PARALLEL_DIRS options for optional parallel construction
|
||||||
#-----------------------------------------------------------
|
#-----------------------------------------------------------
|
||||||
ifdef OPTIONAL_PARALLEL_DIRS
|
ifdef OPTIONAL_PARALLEL_DIRS
|
||||||
PARALLEL_DIRS += $(foreach T,$(OPTIONAL_PARALLEL_DIRS),$(shell test -d $(PROJ_SRC_DIR)/$(T) && echo "$(T)"))
|
PARALLEL_DIRS += $(foreach T,$(OPTIONAL_PARALLEL_DIRS),$(shell test -d $(PROJ_SRC_DIR)/$(T) -o -f $(T)/Makefile && echo "$(T)"))
|
||||||
endif
|
endif
|
||||||
|
|
||||||
#-----------------------------------------------------------
|
#-----------------------------------------------------------
|
||||||
@ -828,13 +828,20 @@ unitcheck:: $(addsuffix /.makeunitcheck,$(PARALLEL_DIRS))
|
|||||||
ParallelTargets := $(foreach T,$(RecursiveTargets),%/.make$(T))
|
ParallelTargets := $(foreach T,$(RecursiveTargets),%/.make$(T))
|
||||||
|
|
||||||
$(ParallelTargets) :
|
$(ParallelTargets) :
|
||||||
$(Verb) if ([ ! -f $(@D)/Makefile ] || \
|
$(Verb) \
|
||||||
command test $(@D)/Makefile -ot \
|
SD=$(PROJ_SRC_DIR)/$(@D); \
|
||||||
$(PROJ_SRC_DIR)/$(@D)/Makefile ); then \
|
DD=$(@D); \
|
||||||
$(MKDIR) $(@D); \
|
if [ ! -f $$SD/Makefile ]; then \
|
||||||
$(CP) $(PROJ_SRC_DIR)/$(@D)/Makefile $(@D)/Makefile; \
|
SD=$(@D); \
|
||||||
|
DD=$(notdir $(@D)); \
|
||||||
fi; \
|
fi; \
|
||||||
$(MAKE) -C $(@D) $(subst $(@D)/.make,,$@)
|
if ([ ! -f $$DD/Makefile ] || \
|
||||||
|
command test $$DD/Makefile -ot \
|
||||||
|
$$SD/Makefile ); then \
|
||||||
|
$(MKDIR) $$DD; \
|
||||||
|
$(CP) $$SD/Makefile $$DD/Makefile; \
|
||||||
|
fi; \
|
||||||
|
$(MAKE) -C $$DD $(subst $(@D)/.make,,$@)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
#---------------------------------------------------------
|
#---------------------------------------------------------
|
||||||
|
Reference in New Issue
Block a user