Changeset 9384


Ignore:
Timestamp:
2007-10-21T09:18:10+02:00 (10 years ago)
Author:
nbd
Message:

make aliases for package targets if the package directories are in further subdirectories
example: if there is a package/libs/foo/compile, then package/foo/compile will be an alias for it

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/subdir.mk

    r8694 r9384  
    1818endef 
    1919 
     20 
     21lastdir=$(word $(words $(subst /, ,$(1))),$(subst /, ,$(1))) 
     22diralias=$(if $(findstring $(1),$(call lastdir,$(1))),,$(call lastdir,$(1))) 
     23 
    2024# Parameters: <subdir> 
    2125define subdir 
     
    3034      # legacy targets 
    3135      $(call warn_eval,$(1)/$(bd),l,T,$(1)/$(bd)-$(target): $(1)/$(bd)/$(target)) 
     36      # aliases 
     37      $(if $(call diralias,$(bd)),$(call warn_eval,$(1)/$(bd),l,T,$(1)/$(call diralias,$(bd))/$(target): $(1)/$(bd)/$(target))) 
    3238        ) 
    3339  ) 
Note: See TracChangeset for help on using the changeset viewer.