Ignore:
Timestamp:
Jan 28, 2015, 7:25:31 PM (10 years ago)
Author:
bird
Message:

subheader/footer.kmk: No need to redefine def_subfooter/def_subheader all the time; moved them to header.kmk and merged them (identical) into a single define.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/kBuild/subheader.kmk

    r2755 r2763  
    55
    66#
    7 # Copyright (c) 2006-2014 knut st. osmundsen <bird-kBuild-spam-xiv@anduin.net>
     7# Copyright (c) 2006-2015 knut st. osmundsen <bird-kBuild-spam-xiv@anduin.net>
    88#
    99# This file is part of kBuild.
     
    5353 # Set the default path and makefile for all new targets.
    5454 #
    55  define def_subfooter
    56   ifndef $(target)_PATH
    57    ifndef $(target)_DEFPATH
    58     $(target)_DEFPATH := $(PATH_SUB_CURRENT)
    59    endif
    60    $(call KB_FN_ASSIGN_DEPRECATED,$(target)_PATH,$($(target)_DEFPATH), $(target)_DEFPATH)
    61   else ifndef $(target)_DEFPATH
    62    $(target)_DEFPATH := $($(target)_PATH)
    63   endif
    64   ifndef $(target)_MAKEFILE
    65    $(target)_MAKEFILE := $(MAKEFILE_CURRENT)
    66   endif
    67   ifndef $(target)_0_OUTDIR
    68    $(target)_0_OUTDIR := $(call TARGET_PATH,$(target))
    69    $(call KB_FN_ASSIGN_DEPRECATED,PATH_$(target),$($(target)_0_OUTDIR), $(target)_0_OUTDIR)
    70   endif
    71  endef
    72 
    73  # TODO: Wish there was an easy way of only enumerating only new targets...
     55 ## @todo Wish there was an easy way of only enumerating only new targets...
    7456 $(foreach target,\
    7557        $(ALL_TARGETS) \
     
    8567        $(INSTALLS)    $(INSTALLS.$(KBUILD_TARGET))     $(INSTALLS.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH))    $(INSTALLS.$(KBUILD_TARGET_ARCH))    $(INSTALLS.$(KBUILD_TARGET_CPU))    $(INSTALLS.$(KBUILD_TYPE))    \
    8668        $(OTHERS)      $(OTHERS.$(KBUILD_TARGET))       $(OTHERS.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH))      $(OTHERS.$(KBUILD_TARGET_ARCH))      $(OTHERS.$(KBUILD_TARGET_CPU))      $(OTHERS.$(KBUILD_TYPE))      \
    87  ,$(if-expr defined($(target)_0_OUTDIR),,$(evalval def_subfooter)))
     69 ,$(if-expr defined($(target)_0_OUTDIR),,$(evalval def_subfooter_header_target_pass)))
    8870
    8971
Note: See TracChangeset for help on using the changeset viewer.