Re: [ANNOUNCEMENT] Updated: bash-3.2.3-5
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 According to SungHyun Nam on 11/14/2006 10:54 PM: Hello, No need to double post. I cannot use /dev/stdout with a bash-3.2.3-5. For example, 'echo hi /dev/stdout' failed. It works fine after I reverted to bash-3.1-6. Hmm, it does indeed seem to be a regression from 3.2-4. I'll look into it, especially now that upstream bash has moved on to 3.2.5. - -- Life is short - so eat dessert first! Eric Blake [EMAIL PROTECTED] -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.5 (Cygwin) Comment: Public key at home.comcast.net/~ericblake/eblake.gpg Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFFWxAp84KuGfSFAYARArSPAKCjVNAkT8J+xKFhcO0kX4HRhmXD2gCfR5ob 2U+jNQH9IL8K/X4VHWfQ3C4= =oT8s -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/
Re: [ANNOUNCEMENT] Updated: bash-3.2.3-5
I saw a couple of posts mentioning a problem with /bin/sh not being updated and replaced with a copy of /bin/bash. I had the same problem here yesterday/today, when I discovered that none of my #!/bin/sh scripts was working. In fact, they did nothing! I tried re-installing bash-3.2.3-5, I tried removing it (while ignoring all warnings about dependencies) and installing (keeping) it, but /bin/sh continued to be the same version from when I installed Cygwin back in February 2006: C:\cygwin\bin dir bash.exe sh.exe Volymen i enhet C har ingen etikett. Volymens serienummer är 141C-8ED0 Innehåll i katalogen C:\cygwin\bin 2006-11-03 04:22 467 968 bash.exe Innehåll i katalogen C:\cygwin\bin 2006-02-08 19:03 451 072 sh.exe 2 fil(er) 919 040 byte 0 katalog(er) 22 278 008 832 byte ledigt I had a look at the /etc/postinstall/00bash.sh.done and 01bash.sh.done scripts and saw that they did some magic before calling /etc/profile.d/00bash.sh. I saw that the /etc/profile.d/00bash.sh tried to get the version from /bin/sh, and tried that by hand by my CMD.EXE: \cygwin\bin\sh.exe --version C:\cygwin\etc\profile.d \cygwin\bin\cygcheck.exe /bin/sh.exe C:/cygwin/bin/sh.exe C:/cygwin/bin\cygwin1.dll C:\WINDOWS\system32\ADVAPI32.DLL C:\WINDOWS\system32\ntdll.dll C:\WINDOWS\system32\KERNEL32.dll C:\WINDOWS\system32\RPCRT4.dll C:/cygwin/bin\cygintl-3.dll C:/cygwin/bin\cygiconv-2.dll C:/cygwin/bin\cygreadline6.dll C:/cygwin/bin\cygncurses-8.dll C:\WINDOWS\system32\USER32.dll C:\WINDOWS\system32\GDI32.dll Not being much wiser, I started a /bin/bash process, cd'ed to /etc/profile.d and attempted to execute /etc/profile.d/00bash.sh: $ cd /etc/profile.d/ [502] jba @ HERMETRIX /etc/profile.d $ ll *bash* -rwxr-x---+ 1 jba 839 Nov 3 04:22 00bash.csh -rwxr-x---+ 1 jba 1942 Nov 3 04:22 00bash.sh [503] jba @ HERMETRIX /etc/profile.d $ /bin/bash -x ./00bash.sh + /bin/test /bin/sh.exe -ot /bin/bash.exe ++ cat /proc/2516/exename + /bin/test /bin/sh.exe -ef /usr/bin/bash.exe + test -f /bin/sh.exe + case `(cygcheck /bin/sh.exe) 21` in + case `(/bin/sh.exe --version) 21` in + return 0 ./00bash.sh: line 29: return: can only `return' from a function or sourced scrip t ++ date '+%Y/%m/%d %T' + echo '2006/11/14 13:07:42 /etc/profile.d/00bash.sh:' 'Attempting to update /bi n/sh.exe' + /bin/cp -fpuv /bin/bash.exe /bin/sh.exe [504] jba @ HERMETRIX /etc/profile.d The copy succeded and I got my updated /bin/sh.exe: $ cd /bin [505] jba @ HERMETRIX /bin $ ll bash.exe sh.exe -rwxr-x---+ 1 jba 467968 Nov 3 04:22 bash.exe -rwxr-x---+ 1 jba 467968 Nov 3 04:22 sh.exe I don't know if this helps anyone understanding why the bash postinstall scripts did not succeed in updating /bin/sh. -- Jan Bruun Andersen -- 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/
Re: [ANNOUNCEMENT] Updated: bash-3.2.3-5
Hello, I cannot use /dev/stdout with a bash-3.2.3-5. For example, 'echo hi /dev/stdout' failed. It works fine after I reverted to bash-3.1-6. Thanks. namsh -- 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/
Re: [ANNOUNCEMENT] Updated: bash-3.2.3-5
Eric Blake ebb9 at byu.net writes: Evil. /bin/sh is supposed to be at the same version of bash, if you installed things correctly. It sounds like your postinstall scripts did not run correctly (perhaps you had bash or sh open when you ran setup.exe?). What are the timestamps on those files ('ls -l /bin/{ba,}sh')? At any rate, the fix is to rerun the postinstall scripts, or more quickly, 'cp /bin/bash /bin/sh'. Several machines at my site have turned up with the sh vs bash issue above, so I think something might be amiss with the installation scripts. The workaround of copying /bin/bash to /bin/sh works of course. -- 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/
[ANNOUNCEMENT] Updated: bash-3.2.3-5
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 A new release of bash, 3.2.3-5, has been promoted to current. This leaves 3.1-6 as the previous version (and not 3.1-9, since only 3.1-6 will work if you downgrade cygwin). NEWS: = This is a new upstream release, including several official upstream patches. More details of the upstream changes are attached below; see also /usr/share/doc/bash-3.2.3/. There are a few things you should be aware of before using this version: 1. When using binary mounts, cygwin programs try to emulate Linux. Bash on Linux does not understand \r\n line endings, but interprets the \r literally, which leads to syntax errors or odd variable assignments. Therefore, you will get the same behavior on Cygwin binary mounts by default. 2. d2u is your friend. You can use it to convert any problematic script into binary line endings. 3. Cygwin text mounts automatically work with either line ending style, because the \r is stripped before bash reads the file. If you absolutely must use files with \r\n line endings, consider mounting the directory where those files live as a text mount. However, text mounts are not as well tested or supported on the cygwin mailing list, so you may encounter other problems with other cygwin tools in those directories. 4. This version of bash has a cygwin-specific shell option, named igncr to force bash to ignore \r, independently of cygwin's mount style. As of bash-3.2.3-5, it controls regular scripts, command substitution, and sourced files. I hope to convince the upstream bash maintainer to accept this patch into the future bash 4.0 even on Linux, rather than keeping it a cygwin-specific patch, but only time will tell. There are several ways to activate this option: 4a. For a single affected script, add this line just after the she-bang: (set -o igncr) 2/dev/null set -o igncr; # comment is needed 4b. For a single script, invoke bash explicitly with the shopt, as in 'bash -o igncr ./myscript' rather than the simpler './myscript'. 4c. To affect all scripts, export the environment variable BASH_ENV, pointing to a file that sets the shell option as desired. Bash will source this file on startup for every script. 4d. Added in the bash-3.2-2 release: export the environment variable SHELLOPTS with igncr included in it. It is read-only from within bash, but you can set it before invoking bash; once in bash, it auto-tracks the current state of 'set -o igncr' or 'shopt -s igncr'. If exported, then all bash child processes inherit the same option settings. 5. You can also experiment with the IFS variable for controlling how bash will treat \r during variable expansion. 6. Normally, cygwin treats DOS-style paths as binary only. This release of bash includes a hack to check the underlying mount point of files, even when passed as DOS style paths, but other cygwin tools do not. You are better off learning how to use POSIX-style paths. 7. There are varying levels of speed at which bash operates. The fastest is on a binary mount with igncr disabled (the default behavior). Next would be text mounts with igncr disabled and no \r in the underlying file. Next would be binary mounts with igncr enabled. And the slowest that bash will operate is on text mounts with igncr enabled. 8. If you don't like how bash behaves, then propose a patch, rather than proposing idle ideas. This turn of events has already been talked to death on the mailing lists by people with many ideas, but few patches. 9. If you forget to read this release announcement, the best you can expect when you complain to the list is a link back to this email. Remember, you must not have any bash or /bin/sh instances running when you upgrade the bash package. This release will work with cygwin-1.5.21-1 or later; and it requires libreadline6-5.2-3. DESCRIPTION: Bash is an sh-compatible shell that incorporates useful features from the Korn shell (ksh) and C shell (csh). It is intended to conform to the IEEE POSIX P1003.2/ISO 9945.2 Shell and Tools standard. It offers functional improvements over sh for both programming and interactive use. In addition, most sh scripts can be run by Bash without modification. As of the bash 3.0 series, cygwin /bin/sh defaults to bash, not ash, similar to Linux distributions. UPDATE: === To update your installation, click on the Install Cygwin now link on the http://cygwin.com/ web page. This downloads setup.exe to your system. Save it and run setup, answer the questions and pick up 'bash' in the 'Base' category (it should already be selected). DOWNLOAD: = Note that downloads from sources.redhat.com (aka cygwin.com) aren't allowed due to bandwidth limitations. This means that you will need to find a mirror which has this update, please choose the one nearest to you: http://cygwin.com/mirrors.html QUESTIONS: == If you want to make a point or ask a question the Cygwin mailing list is the appropriate place. - -- Eric Blake
Re: [ANNOUNCEMENT] Updated: bash-3.2.3-5
Eric Blake ebb9 at byu.net writes: A new release of bash, 3.2.3-5, has been promoted to current. This leaves 3.1-6 as the previous version (and not 3.1-9, since only 3.1-6 will work if you downgrade cygwin). complete release message deleted. I've adopted 3.2.3-5 (after previously reverting to 3.1-6) on my test box; since I am trapped in a world where people demand to run scripts with evil DOS line endings on them. I exported SHELLOPTS=igncr in the Windows environment. Big honking hairy underfunded build runs great until it hits a call to /bin/sh, at which point the igncr functionality no longer holds causing a tremendous gnashing of metal reminiscent of the roar of Godzilla. Details: bash --version 3.2.3(5)-release sh --version 3.1.17(9)-release sh sh: igncr: invalid option name Is this by design or unintended? -bret -- 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/
Re: [ANNOUNCEMENT] Updated: bash-3.2.3-5
Bret Weinraub bretweinraub at yahoo.com writes: Details: bash --version 3.2.3(5)-release sh --version 3.1.17(9)-release Evil. /bin/sh is supposed to be at the same version of bash, if you installed things correctly. It sounds like your postinstall scripts did not run correctly (perhaps you had bash or sh open when you ran setup.exe?). What are the timestamps on those files ('ls -l /bin/{ba,}sh')? At any rate, the fix is to rerun the postinstall scripts, or more quickly, 'cp /bin/bash /bin/sh'. -- Eric Blake volunteer cygwin bash maintainer -- 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/
Re: [ANNOUNCEMENT] Updated: bash-3.2.3-5
Eric Blake ebb9 at byu.net writes: Bret Weinraub bretweinraub at yahoo.com writes: Details: bash --version 3.2.3(5)-release sh --version 3.1.17(9)-release Evil. /bin/sh is supposed to be at the same version of bash, if you installed things correctly. It sounds like your postinstall scripts did not run correctly (perhaps you had bash or sh open when you ran setup.exe?). What are the timestamps on those files ('ls -l /bin/{ba,}sh')? At any rate, the fix is to rerun the postinstall scripts, or more quickly, 'cp /bin/bash /bin/sh'. $ ls -l /bin/{ba,}sh -rwxr-x---+ 1 NotTheRealUser Users 467968 Nov 2 19:22 /bin/bash -rwxr-x---+ 1 NotTheRealUser Users 461824 Nov 7 16:20 /bin/sh Next step - found bash/sh processes running under other sessions (logged in via RDP) - terminated with extreme prejudice. Re-installed via the CYGWIN installer (selected keep - told bash 3.2.3-5 to reinstall) everything looked to be ok. $ bash --version GNU bash, version 3.2.3(5)-release (i686-pc-cygwin) Copyright (C) 2005 Free Software Foundation, Inc. $ sh --version GNU bash, version 3.1.17(9)-release (i686-pc-cygwin) Copyright (C) 2005 Free Software Foundation, Inc. So maybe the post-install script has an issue Took your recommended approach (with the copy). igncr complaint went away ... but something else seems amiss from 3.1.17(6) - will investigate when I can steal more time away from my real job. -- 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/