From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27551 invoked by alias); 17 Apr 2012 07:55:34 -0000 Received: (qmail 27543 invoked by uid 22791); 17 Apr 2012 07:55:32 -0000 X-SWARE-Spam-Status: No, hits=-4.4 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,RCVD_IN_DNSWL_HI,RCVD_IN_HOSTKARMA_W,TW_YG X-Spam-Check-By: sourceware.org Received: from david.siemens.de (HELO david.siemens.de) (192.35.17.14) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 17 Apr 2012 07:55:17 +0000 Received: from mail2.siemens.de (localhost [127.0.0.1]) by david.siemens.de (8.13.6/8.13.6) with ESMTP id q3H7tFle012445 for ; Tue, 17 Apr 2012 09:55:15 +0200 Received: from DEMCHP99ET0MSX.ww902.siemens.net (demchp99et0msx.ww902.siemens.net [139.25.131.181]) by mail2.siemens.de (8.13.6/8.13.6) with ESMTP id q3H7tEdS028786 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=FAIL) for ; Tue, 17 Apr 2012 09:55:15 +0200 Received: from DEMCHP99E84MSX.ww902.siemens.net ([169.254.1.87]) by DEMCHP99ET0MSX.ww902.siemens.net ([139.25.131.181]) with mapi; Tue, 17 Apr 2012 09:55:14 +0200 From: "Schwarz, Konrad" To: "cygwin-xfree@cygwin.com" Date: Tue, 17 Apr 2012 07:55:00 -0000 Subject: Re: "cscope -d" can't find trailer offset if path contains space (was: vim mlcscope interface issues) Message-ID: <9B10FEAACF062F48A095880A451FF0590727D95C07@DEMCHP99E84MSX.ww902.siemens.net> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Mailing-List: contact cygwin-xfree-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-xfree-owner@cygwin.com Reply-To: cygwin-xfree@cygwin.com Mail-Followup-To: cygwin-xfree@cygwin.com X-SW-Source: 2012-04/txt/msg00053.txt.bz2 Hello, an easy work around for the problem that cscope and its variant mlcscope cannot deal with paths containing spaces under Cygwin is to replace such pa= ths with their DOS short name equivalents, since these do not contain spaces. The error surfaces as the error message mlcscope: cannot read trailer offset from file ./cscope.out and in that mlcscope recreates the program database each time it is started. When starting cscope using relative paths (the most frequent case), elimina= ting spaces must be done for the current working directory. The cygpath utility comes in handy for this. E.g., invoking mlcscope as (cd $(cygpath -u $(cygpath -d "$PWD"));mlcscope -b) solves the problem. In the above line, the inner call to cygpath converts the working directory to DOS format, the outer call converts the result to Cygwin format; preserv= ing the short names of DOS, but replacing backslashes with forward slashes, for= example. Unfortunately, it is not possible to combine the -u and -d flags in a single invocation of cygpath; this would be a useful extension. Regards, Konrad Schwarz P.S.: Sorry for resurrecting an old thread from Jan 2007. However, this th= read seems to be the only place the problem was discussed. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/