Ignore:
Timestamp:
Oct 26, 2008, 5:15:46 AM (17 years ago)
Author:
bird
Message:

kmk: Fixed CONFIG_WITH_LAZY_DEPS_VARS bug. Files with multiple double colon rules cannot be handled lazily in any easy way.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kmk/commands.c

    r1942 r1948  
    183183#endif /* CONFIG_WITH_RDONLY_VARIABLE_VALUE */
    184184
    185 #ifndef CONFIG_WITH_LAZY_DEPS_VARS
    186185  /* Compute the values for $^, $+, $?, and $|.  */
    187 
     186#ifdef CONFIG_WITH_LAZY_DEPS_VARS
     187  if (   file->double_colon
     188      && (   file->double_colon != file
     189          || file->last != file))
     190#endif
    188191  {
    189192    static char *plus_value=0, *bar_value=0, *qmark_value=0;
     
    325328    DEFINE_VARIABLE ("|", 1, bar_value);
    326329  }
    327 
    328 #else  /* CONFIG_WITH_LAZY_DEPS_VARS */
    329 
    330   /* Make a copy of the current dependency chain for later use in
    331      potential $(dep-pluss $@) calls.  Then drop duplicate deps.  */
    332 
    333   /* assert (file->org_deps == NULL); - FIXME? */
    334   free_dep_chain (file->org_deps);
    335   file->org_deps = copy_dep_chain (file->deps);
    336 
    337   uniquize_deps (file->deps);
    338 
     330#ifdef CONFIG_WITH_LAZY_DEPS_VARS
     331  else
     332    {
     333      /* Make a copy of the current dependency chain for later use in
     334         potential $(dep-pluss $@) calls.  Then drop duplicate deps.  */
     335
     336      /* assert (file->org_deps == NULL); - FIXME? */
     337      free_dep_chain (file->org_deps);
     338      file->org_deps = copy_dep_chain (file->deps);
     339
     340      uniquize_deps (file->deps);
     341   }
    339342#endif /* CONFIG_WITH_LAZY_DEPS_VARS */
    340343#undef  DEFINE_VARIABLE
Note: See TracChangeset for help on using the changeset viewer.