From e78436cf58d37d8471da0101407ff71d4fdee901 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Sat, 16 Apr 2011 11:55:46 +0200 Subject: [PATCH] depcomp: correct invalid sed invocation * lib/depcomp: Insert missing -e before '/:$/d'. Otherwise, that use of sed would treat '/:$/d' as a file name. Signed-off-by: Ralf Wildenhues --- ChangeLog | 8 +++++++- lib/depcomp | 4 ++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 20862eace..78514938d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2011-04-16 Jim Meyering + + depcomp: correct invalid sed invocation + * lib/depcomp: Insert missing -e before '/:$/d'. + Otherwise, that use of sed would treat '/:$/d' as a file name. + 2011-04-11 Stefano Lattarini depcomp: fix bugs in tests and in the depcomp script @@ -2488,7 +2494,7 @@ ----- -Copyright (C) 2010 Free Software Foundation, Inc. +Copyright (C) 2010, 2011 Free Software Foundation, Inc. Copying and distribution of this file, with or without modification, are permitted provided the copyright notice and this notice are preserved. diff --git a/lib/depcomp b/lib/depcomp index 82ebc751f..2fe40a94b 100755 --- a/lib/depcomp +++ b/lib/depcomp @@ -1,7 +1,7 @@ #! /bin/sh # depcomp - compile a program generating dependencies as side-effects -scriptversion=2011-04-11-10; # UTC +scriptversion=2011-04-16.09; # UTC # Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009, 2011, # Free Software Foundation, Inc. @@ -162,7 +162,7 @@ gcc) ## to the object. Take care to not repeat it in the output. ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. - sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" '/:$/d' \ + sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \ | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; -- 2.47.2