Changeset 055e668 in rtems for depcomp


Ignore:
Timestamp:
12/13/11 04:59:22 (11 years ago)
Author:
Ralf Corsepius <ralf.corsepius@…>
Branches:
4.11, 5, master
Children:
6649644
Parents:
c444d1e
Message:

2011-12-13 Ralf Corsépius <ralf.corsepius@…>

  • compile, depcomp, mdate-sh, texinfo.tex: Update from automake-1.11.1b.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • depcomp

    rc444d1e r055e668  
    22# depcomp - compile a program generating dependencies as side-effects
    33
    4 scriptversion=2009-04-28.21; # UTC
    5 
    6 # Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009 Free
    7 # Software Foundation, Inc.
     4scriptversion=2011-12-04.11; # UTC
     5
     6# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009, 2010,
     7# 2011 Free Software Foundation, Inc.
    88
    99# This program is free software; you can redistribute it and/or modify
     
    4545  DEPDIR      directory where to store dependencies.
    4646  depfile     Dependency file to output.
    47   tmpdepfile  Temporary file to use when outputing dependencies.
     47  tmpdepfile  Temporary file to use when outputting dependencies.
    4848  libtool     Whether libtool is used (yes/no).
    4949
     
    9191   # Just convert the backslash-escaped backslashes to single forward
    9292   # slashes to satisfy depend.m4
    93    cygpath_u="sed s,\\\\\\\\,/,g"
     93   cygpath_u='sed s,\\\\,/,g'
    9494   depmode=msvisualcpp
     95fi
     96
     97if test "$depmode" = msvc7msys; then
     98   # This is just like msvc7 but w/o cygpath translation.
     99   # Just convert the backslash-escaped backslashes to single forward
     100   # slashes to satisfy depend.m4
     101   cygpath_u='sed s,\\\\,/,g'
     102   depmode=msvc7
    95103fi
    96104
     
    159167## Some versions of gcc put a space before the `:'.  On the theory
    160168## that the space means something, we add a space to the output as
    161 ## well.
     169## well.  hp depmode also adds that space, but also prefixes the VPATH
     170## to the object.  Take care to not repeat it in the output.
    162171## Some versions of the HPUX 10.20 sed can't process this invocation
    163172## correctly.  Breaking it into two sed invocations is a workaround.
    164     sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
     173    sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \
     174      | sed -e 's/$/ :/' >> "$depfile"
    165175  rm -f "$tmpdepfile"
    166176  ;;
     
    406416   ;;
    407417
     418msvc7)
     419  if test "$libtool" = yes; then
     420    showIncludes=-Wc,-showIncludes
     421  else
     422    showIncludes=-showIncludes
     423  fi
     424  "$@" $showIncludes > "$tmpdepfile"
     425  stat=$?
     426  grep -v '^Note: including file: ' "$tmpdepfile"
     427  if test "$stat" = 0; then :
     428  else
     429    rm -f "$tmpdepfile"
     430    exit $stat
     431  fi
     432  rm -f "$depfile"
     433  echo "$object : \\" > "$depfile"
     434  # The first sed program below extracts the file names and escapes
     435  # backslashes for cygpath.  The second sed program outputs the file
     436  # name when reading, but also accumulates all include files in the
     437  # hold buffer in order to output them again at the end.  This only
     438  # works with sed implementations that can handle large buffers.
     439  sed < "$tmpdepfile" -n '
     440/^Note: including file:  *\(.*\)/ {
     441  s//\1/
     442  s/\\/\\\\/g
     443  p
     444}' | $cygpath_u | sort -u | sed -n '
     445s/ /\\ /g
     446s/\(.*\)/       \1 \\/p
     447s/.\(.*\) \\/\1:/
     448H
     449$ {
     450  s/.*/ /
     451  G
     452  p
     453}' >> "$depfile"
     454  rm -f "$tmpdepfile"
     455  ;;
     456
     457msvc7msys)
     458  # This case exists only to let depend.m4 do its work.  It works by
     459  # looking at the text of this script.  This case will never be run,
     460  # since it is checked for above.
     461  exit 1
     462  ;;
     463
    408464#nosideeffect)
    409465  # This comment above is used by automake to tell side-effect
     
    504560  ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
    505561  rm -f "$depfile"
    506   cat < "$tmpdepfile" > "$depfile"
     562  # makedepend may prepend the VPATH from the source file name to the object.
     563  # No need to regex-escape $object, excess matching of '.' is harmless.
     564  sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile"
    507565  sed '1,2d' "$tmpdepfile" | tr ' ' '
    508566' | \
Note: See TracChangeset for help on using the changeset viewer.