[BACK]Return to targ.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / make

Diff for /src/usr.bin/make/targ.c between version 1.40 and 1.41

version 1.40, 2006/01/20 23:10:19 version 1.41, 2007/09/16 12:09:36
Line 397 
Line 397 
   
 /*-  /*-
  *-----------------------------------------------------------------------   *-----------------------------------------------------------------------
  * Targ_FmtTime --  
  *      Format a modification time in some reasonable way and return it.  
  *  
  * Results:  
  *      The time reformatted.  
  *  
  * Side Effects:  
  *      The time is placed in a static area, so it is overwritten  
  *      with each call.  
  *-----------------------------------------------------------------------  
  */  
 char *  
 Targ_FmtTime(TIMESTAMP time)  
 {  
     struct tm           *parts;  
     static char         buf[128];  
     time_t t;  
   
     t = timestamp2time_t(time);  
   
     parts = localtime(&t);  
     strftime(buf, sizeof buf, "%H:%M:%S %b %d, %Y", parts);  
     buf[sizeof(buf) - 1] = '\0';  
     return buf;  
 }  
   
 /*-  
  *-----------------------------------------------------------------------  
  * Targ_PrintType --   * Targ_PrintType --
  *      Print out a type field giving only those attributes the user can   *      Print out a type field giving only those attributes the user can
  *      set.   *      set.
Line 486 
Line 458 
             if (! (gn->type & (OP_JOIN|OP_USE|OP_EXEC))) {              if (! (gn->type & (OP_JOIN|OP_USE|OP_EXEC))) {
                 if (!is_out_of_date(gn->mtime)) {                  if (!is_out_of_date(gn->mtime)) {
                     printf("# last modified %s: %s\n",                      printf("# last modified %s: %s\n",
                               Targ_FmtTime(gn->mtime),                                time_to_string(gn->mtime),
                               (gn->made == UNMADE ? "unmade" :                                (gn->made == UNMADE ? "unmade" :
                                (gn->made == MADE ? "made" :                                 (gn->made == MADE ? "made" :
                                 (gn->made == UPTODATE ? "up-to-date" :                                  (gn->made == UPTODATE ? "up-to-date" :

Legend:
Removed from v.1.40  
changed lines
  Added in v.1.41