Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com X-Authentication-Warning: arachnion.cs.Virginia.EDU: nc2y owned process doing -bs Date: Thu, 6 Feb 2003 11:51:39 -0500 (EST) From: Nicolas Christin X-X-Sender: nc2y AT arachnion DOT cs DOT Virginia DOT EDU To: cygwin AT cygwin DOT com Subject: Re: Detecting text type in a shell script In-Reply-To: <00ed01c2cdfc$8b6cc810$78d96f83@pomello> Message-ID: References: <00e101c2cdf8$79490fd0$78d96f83 AT pomello> <00ed01c2cdfc$8b6cc810$78d96f83 AT pomello> Organization: University of Virginia - CS Dept. X-No-Archive: no MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Thu, 6 Feb 2003, Max Bowsher wrote: > Have you tried linking you app with -lbinmode ? That should force all > file access to be binary, whatever the mount. No - but that's a very good point - worth trying out. Thanks a bunch. On Thu, 6 Feb 2003, David Robinow wrote: > Has it occurred to you that a better solution might be to fix your > software so that it works properly with text mounts? "No can do." Our software does, but third-party software it relies on and it is distributed with apparently does not. I already have about 20 lines of shell with gory sed's and the like to patch the source code of those third-party packages in case Cygwin is detected (I can't assume "patch" is available), and I am *not* going to go through the source code of a bunch of external packages to fix all the possible problems there can be with text mounts. And before you ask, no, the people who develop those third-party packages won't fix them. It is much easier for me to tell people at installation time "DOS type detected, which is unsuitable, compile at your own risk" or to use Max's suggestion and try to write a kludge that forces -lbinmode everywhere if Cygwin is detected. Note that this stuff isn't even *supposed* to run under Windows, thank God (or to the Cygwin developers in that case) for small miracles. Anyway, thanks again for the tips, Max. Highly appreciated. -- Nicolas -- 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/