Files
harbour-core/harbour/config/dos/dir.cf
Viktor Szakats 02b2a299bf 2009-07-14 20:52 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)
* config/dos/dir.cf
  * config/win/dir.cf
  * config/linux/dir.cf
  * config/os2/dir.cf
  * config/wce/dir.cf
    * DIR_LIST -> DIRS_OS
    * DIR_MAKE -> MK_OS
2009-07-14 18:52:49 +00:00

42 lines
781 B
CFEngine3

#
# $Id$
#
ifeq ($(PM),) # Only traverse directories if not compiling a specific module
ifeq ($(DIRS),) # Empty directory list
DIR_RULE = @echo Done
else
ifeq ($(SHLVL),) # non-bash
# We have to use script to overcome the DOS limit of max 128 characters
# NOTE: The empty line directly before 'endef' HAVE TO exist!
# It causes that every commands will be separated by LF
define dir_mk
$(MK_OS) -C $(file) $@
endef
DIRS_OS = $(subst /,\,$(DIRS))
MK_OS = $(subst /,\,$(MK))
DIR_RULE = $(foreach file, $(DIRS_OS), $(dir_mk))
else # bash
DIRS_OS = $(subst \,/,$(DIRS))
DIR_RULE =\
@for d in $(DIRS_OS); do \
if [ -d $$d ]; then \
$(MAKE) -C $$d $@; \
fi \
done
endif # ! non-bash
endif # ! Empty directory list
endif # ! compiling a specific program module