X-Spam-Check-By: sourceware.org Date: Thu, 16 Nov 2006 11:45:38 +0100 From: Corinna Vinschen To: cygwin AT cygwin DOT com Subject: Re: request for /dev/stdin and friends Message-ID: <20061116104538.GK11304@calimero.vinschen.de> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <455B18D9 DOT 30504 AT byu DOT net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <455B18D9.30504@byu.net> User-Agent: Mutt/1.4.2i Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Unsubscribe: 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 On Nov 15 06:40, Eric Blake wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > I know it is possible to create /dev/std{in,out,err} myself, simply making > symlinks to /proc/self/fd/{0,1,2}, once I create an underlying physical > /dev directory. But by doing so, I have made it so that the version of > bash that I compile detects their existence, and assumes it can use > /dev/stdin without problems, and then running that version of bash on > other machines fails because /dev/stdin is not standard in cygwin. I > suppose I could try to make the bash postinstall script create a physical > /dev/ drive, and populate it with std{in,out,err}, but it seems like it > might be nicer if cygwin/devices.in were to provide them natively for all > users. Dunno about that. On Linux, /dev/std{in,out,err} are just symbolic links to fd/{0,1,2} and fd is just a symlink to /proc/self/fd. So what we should do here IMO is to augment the base-files package to create a /dev directory and create a couple of standard symlinks in it, which are not covered automatically by the Cygwin DLL. For a start: fd -> /proc/self/fd stdin -> fd/0 stdout -> fd/1 stderr -> fd/2 dvd -> scd0 cdrom -> scd0 rmt0 -> st0 nrmt0 -> nst0 tape -> nst0 Corinna -- Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Project Co-Leader cygwin AT cygwin DOT com Red Hat -- 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/