delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2006/04/16/21:23:59

X-Spam-Check-By: sourceware.org
To: cygwin AT cygwin DOT com
From: Steven Brown <swbrown AT ucsd DOT edu>
Subject: Re: Fixing the state of C++ in Cygwin
Date: Sun, 16 Apr 2006 18:23:39 -0700
Lines: 45
Message-ID: <e1uqml$530$1@sea.gmane.org>
References: <e1huo3$i3v$1 AT sea DOT gmane DOT org> <20060412045300 DOT GB7046 AT trixie DOT casa DOT cgf DOT cx> <443C91B0 DOT 1020806 AT ucsd DOT edu> <20060412103121 DOT GA12493 AT calimero DOT vinschen DOT de>
Mime-Version: 1.0
User-Agent: Thunderbird 1.5 (Windows/20051201)
In-Reply-To: <20060412103121.GA12493@calimero.vinschen.de>
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

Corinna Vinschen wrote:
> On Apr 11 22:35, Steven Brown wrote:

>> I can look into the problem with sed 4.1.5 as well,
[...]
So the question is this:
> 
> Is it a textmode/binmode issue and if so, why are the files created with
> CRLF line endings at all?  If they are not created with CRLF line
> endings on Linux, then there's no reason to create them with CRLF on
> Cygwin.  As a first local solution, don't use textmode mounts.

The problem appears to be with 'cat << EOF' notation - the result winds 
up CRLF and this causes issues with the now binary mode sed 4.1.5 in 
libtool (more on that later).  It was rather unexpected to me that this 
is CRLF (standard UNIX-style install, binmode mount):

Steven Brown AT FICTITION ~/src
$ cat << EOF | file -
 > foo
 > EOF
/dev/stdin: ASCII text, with CRLF line terminators

But this is not:

Steven Brown AT FICTITION ~/src
$ cat | file -
foo
/dev/stdin: ASCII text

Is this by design or a bug?  It seems like the wrong thing for it to be 
doing.

As for why it causes libtool to fail, the configuration sections of 
libtool are built via a '<< EOF' style mechanism during configure so 
leaves them CRLF terminated.  libtool attempts to extract those 
configuration sections like so:

eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### 
END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`"

However, the BEGIN line has a \r that won't match the above, so it fails 
to eval:

# ### BEGIN LIBTOOL TAG CONFIG: CXX^M


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019