Mailing-List: contact cygwin-help@sourceware.cygnus.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@sources.redhat.com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin@sources.redhat.com>
List-Help: <mailto:cygwin-help@sources.redhat.com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner@sources.redhat.com
Delivered-To: mailing list cygwin@sources.redhat.com
Date: Mon, 9 Jul 2001 22:22:26 +0200
From: Corinna Vinschen <cygwin@cygwin.com>
To: Bill Petheram <bilpet@hplb.hpl.hp.com>, Lapo Luchini <lapo@lapo.it>,
        cygwin <cygwin@cygwin.com>
Subject: Re: rsync
Message-ID: <20010709222226.A16128@cygbert.vinschen.de>
Mail-Followup-To: Bill Petheram <bilpet@hplb.hpl.hp.com>,
	Lapo Luchini <lapo@lapo.it>, cygwin <cygwin@cygwin.com>
References: <610A1F4808E9D411888F0001023F6361A2EC@MUCX> <3B46E116.20508.C8E5ACB@localhost> <20010707095422.C7298@redhat.com> <3B499BF7.6D8FCABC@hplb.hpl.hp.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
User-Agent: Mutt/1.2.5i
In-Reply-To: <3B499BF7.6D8FCABC@hplb.hpl.hp.com>; from bilpet@hplb.hpl.hp.com on Mon, Jul 09, 2001 at 12:56:39PM +0100

On Mon, Jul 09, 2001 at 12:56:39PM +0100, Bill Petheram wrote:
> I can't get rsync to work on W2K except in daemon mode. I tried to debug
> it with gdb but rsync exits on the first write statement. This means
> that I cannot step through the program.

Did you try an strace? It can be pretty helpful, at least to see
at which point in Cygwin the error occurs. Did you call gdb in
default GUI mode or in non-GUI? Mostly the non-GUI version (started
by calling gdb -nw) is a bit easier to control, especially if you're
working with more than one partition since the GUI version only
works with native paths.

> If I build cygwin from source would I be able to see where the write was
> failing?

Sure. You can build with CFLAGS=-g instead of using the default of
CFLAGS=-O2. That results in a easier source code level debugging.
When you're running that dll (which is approx. 4MB in size) you can
start rsync again under gdb control. In gdb you can load the DLL's
symbol table by calling `dll cygwin1.dll'. Set a breakpoint on rsync's
main() function and after running up to that point you can set
breakpoints to Cygwin's internal functions.

Lapo, are you already investigating into that problem as well? Since
you did the base port you have a clue what's going on, perhaps.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Developer                                mailto:cygwin@cygwin.com
Red Hat, Inc.

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

