delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2005/08/15/07:49:52

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
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
Message-ID: <43008152.20500@byu.net>
Date: Mon, 15 Aug 2005 05:49:38 -0600
From: Eric Blake <ebb9 AT byu DOT net>
User-Agent: Mozilla Thunderbird 1.0.2 (Windows/20050317)
MIME-Version: 1.0
To: Michael Richardson <mcr AT sandelman DOT ottawa DOT on DOT ca>
CC: cygwin AT cygwin DOT com
Subject: Re: $OS vs `uname -s` [Attn: base-files maintainer]
References: <v0k6io1cwt DOT fsf AT marajade DOT sandelman DOT ottawa DOT on DOT ca>
In-Reply-To: <v0k6io1cwt.fsf@marajade.sandelman.ottawa.on.ca>
X-IsSubscribed: yes

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

PLEASE fix your mailer to send valid mail.  It was difficult to see what
you were asking, because your MIME settings are incorrect, and correct
mailers only saw a blank message.

According to Michael Richardson on 8/14/2005 2:28 PM:
> I noticed that my cygwin bash shell has $OS defined already, as
> "Windows_NT"
> while uname -s produces CYGWIN_NT-5.0.
>
> Normally, I expect `uname -r` to say "5.0", but it gives another number,
> presumeably a cygwin version.

Yes, uname -r is the cygwin .dll version.

>
> bash-3.00$ uname -s
> CYGWIN_NT-5.0
> bash-3.00$ echo $OS
> Windows_NT
>
> I only ask because my Makefiles from Unix would prefer to have $OS
> either not
> set, or be equal to uname -s. Is there a reason why these things differ?
> (My Makefile's will get changed to cope...)

If your setup is like mine, OS is an inherited environment variable, set
by Windows before bash is even started.  You can set it to whatever you
like.  Meanwhile, uname -s is not affected by the environment (you really
don't want an environment variable changing the uname output).  Hmm, maybe
we should update /etc/profile to do OS=`uname -s`.  Thoughts?

- --
Life is short - so eat dessert first!

Eric Blake             ebb9 AT byu DOT net
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFDAIFR84KuGfSFAYARAlhQAJ9mEPk9s9TveH7E9D3a3qzpA4uVuwCgoNGd
g1wm2bucahTaIyHir06Q4I4=
=UknZ
-----END PGP SIGNATURE-----

--
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