From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22481 invoked by alias); 11 Jul 2003 18:18:56 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 22474 invoked from network); 11 Jul 2003 18:18:56 -0000 Received: from unknown (HELO planck.amplepower.com) (216.39.162.139) by sources.redhat.com with SMTP; 11 Jul 2003 18:18:56 -0000 Received: from [192.168.8.30] (helo=knuth.amplepower.com ident=roth) by planck.amplepower.com with esmtp (Exim 3.36 #1 (Debian)) id 19b2E3-0001p8-00; Fri, 11 Jul 2003 11:02:31 -0700 Date: Fri, 11 Jul 2003 18:18:00 -0000 From: "Theodore A. Roth" X-X-Sender: roth@knuth.amplepower.com To: Daniel Jacobowitz cc: gdb-patches@sources.redhat.com Subject: Re: [RFA] sed bug in Makefile.in In-Reply-To: <20030711173849.GA29103@nevyn.them.org> Message-ID: References: <20030711173849.GA29103@nevyn.them.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-SW-Source: 2003-07/txt/msg00248.txt.bz2 On Fri, 11 Jul 2003, Daniel Jacobowitz wrote: > On Fri, Jul 11, 2003 at 10:14:01AM -0700, Theodore A. Roth wrote: > > Hi, > > > > I just tried to configure and build gdb with: > > > > ../configure --prefix=$HOME/local/avr --program-suffix=-6.0 --target=avr --enable-gdb-build-warnings=,-Werror > > ../configure --prefix=$HOME/local/avr --program-suffix=-6.0 --program-prefix=avr- --target=avr --enable-gdb-build-warnings=,-Werror > > > > Both failed to install avr-gdb-6.0 which I expected. > > > > The failure (on 'make install') is this: > > > > make[1]: Leaving directory > > `/home/roth/dev/tools/gdb-6.0-cvs/obj-avr/gdb' > > transformed_name=`t='s,$,-6.0,; s,^,avr-,; '; \ > > echo gdb | sed -e $t` ; \ > > if test "x$transformed_name" = x; then \ > > transformed_name=gdb ; \ > > else \ > > true ; \ > > fi ; \ > > /bin/sh ../../gdb/../mkinstalldirs /home/roth/local/avr/bin ; \ > > /usr/bin/install -c gdb \ > > /home/roth/local/avr/bin/$transformed_name ; \ > > /bin/sh ../../gdb/../mkinstalldirs \ > > /home/roth/local/avr/man/man1 ; \ > > /usr/bin/install -c -m 644 ../../gdb/gdb.1 \ > > /home/roth/local/avr/man/man1/$transformed_name.1 > > sed: can't read s,^,avr-,;: No such file or directory > > > > > > The attached patch seems to fix this. > > > > Ok to commit? Should probably go on both head and branch. > > Yes, this is fine. Thanks. This only fixes the case when both --program-prefix and --program-suffix are specified. There still seems to be a problem with the case where --target and --program-suffix are specified. The result with just --target=avr is the installed program being named avr-gdb, but when using --target and --program-suffix, the avr- prefix is lost. This seems to caused by this code in configure: 1148 test "$host_alias" != "$target_alias" && 1149 test "$program_prefix$program_suffix$program_transform_name" = \ 1150 NONENONEs,x,x, && 1151 program_prefix=${target_alias}- So, it may not be fixable (or need to be fixed). I guess the behavior just surprised me. Ted Roth