Re: [Mingw-w64-public] [PATCH v11] crt: Recognize cygwin ptys in isatty

2017-01-22 Thread Mihail Konev
On Thu, Jan 19, 2017 at 12:54:33AM +0500, Mihail Konev wrote: > On Sat, Jan 07, 2017 at 10:52:40AM +0500, Mihail Konev wrote: > > Signed-off-by: Mihail Konev <k@ya.ru> > > Moved-from: https://github.com/Alexpux/mingw-w64/pull/3 > > Reference: https://cygwin.com/m

Re: [Mingw-w64-public] [PATCH v11] crt: Recognize cygwin ptys in isatty

2017-01-18 Thread Mihail Konev
On Sat, Jan 07, 2017 at 10:52:40AM +0500, Mihail Konev wrote: > Signed-off-by: Mihail Konev <k@ya.ru> > Moved-from: https://github.com/Alexpux/mingw-w64/pull/3 > Reference: https://cygwin.com/ml/cygwin-developers/2016-11/msg2.html > --- > v11: const the exported isatt

[Mingw-w64-public] [PATCH v11] crt: Recognize cygwin ptys in isatty

2017-01-06 Thread Mihail Konev
Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/Alexpux/mingw-w64/pull/3 Reference: https://cygwin.com/ml/cygwin-developers/2016-11/msg2.html --- v11: const the exported isatty mingw-w64-crt/Makefile.am | 1 + mingw-w64-crt/def-include/

Re: [Mingw-w64-public] [PATCH v10] crt: Recognize cygwin ptys in isatty

2017-01-06 Thread Mihail Konev
On Sat, Dec 10, 2016 at 05:30:32AM +0500, Mihail Konev wrote: > > mingw-w64-crt/Makefile.am | 1 + > mingw-w64-crt/def-include/msvcrt-common.def.in | 2 +- > mingw-w64-crt/lib64/moldname-msvcrt.def| 2 +- > mingw-w64-crt/stdio/isatty.c

[Mingw-w64-public] [PATCH v10] crt: Recognize cygwin ptys in isatty

2016-12-09 Thread Mihail Konev
Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/Alexpux/mingw-w64/pull/3 Reference: https://cygwin.com/ml/cygwin-developers/2016-11/msg2.html --- v8-v10: Change comment-outs in def files. Error-check GetModuleHandle. Edit description. mingw-w64-crt/Makef

[Mingw-w64-public] [PATCH] Fix typos for -DCOMPILE_MULTIMON_STUBS

2016-11-23 Thread Mihail Konev
>From 6918551906f65025b008e17398982e0352038a84 Mon Sep 17 00:00:00 2001 From: Mario Kleiner <mario.kleiner...@gmail.com> Date: Tue, 22 Nov 2016 03:35:56 +0100 Subject: [PATCH] Fix typos for -DCOMPILE_MULTIMON_STUBS Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://git

[Mingw-w64-public] [PATCH v9] Make isatty Cygwin-compatible

2016-11-19 Thread Mihail Konev
Before, isatty() was an alias for WinAPI _isatty(). This resulted in wrong result for mintty. Implement pipe name check in crt isatty(). Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/Alexpux/mingw-w64/pull/3 Reference: https://cygwin.com/ml/cygwin-developers/2

[Mingw-w64-public] [PATCH v8] Make isatty Cygwin-compatible

2016-11-18 Thread Mihail Konev
Before, isatty() was an alias for WinAPI _isatty(). This resulted in wrong result for mintty. Implement pipe name check in crt isatty(). Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/Alexpux/mingw-w64/pull/3 Reference: https://cygwin.com/ml/cygwin-developers/2

[Mingw-w64-public] [PATCH v7] Make isatty Cygwin-compatible

2016-11-18 Thread Mihail Konev
Before, isatty() was an alias for WinAPI _isatty(). This resulted in wrong result for mintty. Implement pipe name check in crt isatty(). Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/Alexpux/mingw-w64/pull/3 Reference: https://cygwin.com/ml/cygwin-developers/2

Re: [Mingw-w64-public] [PATCH v6] Make isatty Cygwin-compatible

2016-11-17 Thread Mihail Konev
On Fri, Nov 18, 2016 at 08:37:33AM +0500, Mihail Konev wrote: > > all: test > > a.exe: main.c > $(CC) -Wall -Wextra main.c > > test: a.exe > @echo > @echo " -- Test not a tty --" > @echo Sorry, forgot 'all: clean

[Mingw-w64-public] [PATCH v6] Make isatty Cygwin-compatible

2016-11-17 Thread Mihail Konev
Before, isatty() was an alias for WinAPI _isatty(). This resulted in wrong result for mintty. Implement pipe name check in crt isatty(). Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/Alexpux/mingw-w64/pull/3 Reference: https://cygwin.com/ml/cygwin-developers/2

Re: [Mingw-w64-public] [PATCH v4] Make isatty Cygwin-compatible

2016-11-15 Thread Mihail Konev
& make install' must be performed. Should be a makefile bug. This gives undefined reference to 'isatty' when compiling hello-isatty program: Commenting all _isatty-s except ADD_UNDERSCORE one gives msvcrt _isatty being called. commit a0e3a797e29638803a8ff9b621e9ba5f6f12c1b8 Author: Mihail Konev <k...

[Mingw-w64-public] [PATCH v4] Make isatty Cygwin-compatible

2016-11-14 Thread Mihail Konev
Before, isatty() was an alias for WinAPI _isatty(). This resulted in wrong result for mintty. Implement a pipe name check in a static isatty(). This makes io.h include NT and Windows APIs. The change isn't strictly standard, as it adds 'static' to the isatty() signature. Signed-off-by: Mihail

Re: [Mingw-w64-public] [PATCH v3] Make isatty Cygwin-compatible

2016-11-13 Thread Mihail Konev
On Sun, Nov 13, 2016 at 09:44:49PM +0100, Corinna Vinschen wrote: > On Nov 14 00:31, Mihail Konev wrote: > > I'm opposed to checking the pipes for *-msys-* additionally to > *-cygwin-* for no good reason. You're adding just another test to the > checking code and potentially

[Mingw-w64-public] [PATCH v3] Make isatty Cygwin-compatible

2016-11-13 Thread Mihail Konev
Before, isatty() was an alias for WinAPI _isatty(). This resulted in wrong result for mintty. Implement a pipe name check in a static isatty(). This makes io.h include NT and Windows APIs. The change isn't strictly standard, as it adds 'static' to the isatty() signature. Signed-off-by: Mihail

[Mingw-w64-public] [PATCH v2] Make isatty Cygwin-compatible

2016-11-13 Thread Mihail Konev
Before, isatty() was an alias for WinAPI _isatty(). This resulted in wrong result for mintty. Implement a pipe name check in a static isatty(). This makes io.h include NT and Windows APIs. The change isn't strictly standard, as it adds 'static' to the isatty() signature. Signed-off-by: Mihail

[Mingw-w64-public] [PATCH] Make isatty Cygwin-compatible

2016-11-13 Thread Mihail Konev
Before, isatty() was an alias for WinAPI _isatty(). This resulted in wrong result for mintty. Implement a pipe name check in a static isatty(). This makes io.h include wchar.h, errno.h, io.h, winternl.h, and windows.h. Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://gith

Re: [Mingw-w64-public] [PATCH v7] Add include/iscygtty.c

2016-11-12 Thread Mihail Konev
On Sun, Nov 13, 2016 at 07:16:01AM +0100, Vincent Torri wrote: > i still don't understand why not using GetConsoleMode() and see if it > fails or not. > > if it fails : redirection is done with named pipes Redirection is then done, but is it a file or mintty stdin ? > if not : it's standard

[Mingw-w64-public] [PATCH v7] Add include/iscygtty.c

2016-11-12 Thread Mihail Konev
Applications now could call iscygtty(STDIN_FILENO) in order to detect whether they are running from Cygwin/MSys terminal. Without that, they have no choice but to think that stdin is redirected from a named pipe. Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/A

Re: [Mingw-w64-public] [PATCH v2] Add include/iscygtty.c

2016-11-11 Thread Mihail Konev
On Sat, Nov 12, 2016 at 12:06:02PM +0500, Mihail Konev wrote: > > Doing it through shared memory should be depenedent on cygwin headers > (if reliable at all for not-a-cygwin-process-child). > Oh. We *are* cygwin-fork()-ed if running from a mintty ;) But still this should be

[Mingw-w64-public] [PATCH v6] Add include/iscygtty.c

2016-11-11 Thread Mihail Konev
Applications now could call iscygtty(STDIN_FILENO) in order to detect whether they are running from Cygwin/MSys terminal. Without that, they have no choice but to think that stdin is redirected from a named pipe. Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/A

Re: [Mingw-w64-public] [PATCH v2] Add include/iscygtty.c

2016-11-11 Thread Mihail Konev
On Sat, Nov 12, 2016 at 06:34:54AM +0500, Mihail Konev wrote: > On Fri, Nov 11, 2016 at 11:19:45AM -0500, Earnie wrote: > > On 11/10/2016 5:43 PM, Mihail Konev wrote: > > > Applications now could call iscygtty(STDIN_FILENO) > > > in order to detect whether they are run

[Mingw-w64-public] [PATCH v5] Add include/iscygtty.c

2016-11-11 Thread Mihail Konev
Applications now could call iscygtty(STDIN_FILENO) in order to detect whether they are running from Cygwin/MSys terminal. Without that, they have no choice but to think that stdin is redirected from a named pipe. Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/A

[Mingw-w64-public] [PATCH v4] Add include/iscygtty.c

2016-11-11 Thread Mihail Konev
Applications now could call iscygtty(STDIN_FILENO) in order to detect whether they are running from Cygwin/MSys terminal. Without that, they have no choice but to think that stdin is redirected from a named pipe. Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/A

[Mingw-w64-public] [PATCH v3] Add include/iscygtty.c

2016-11-11 Thread Mihail Konev
Applications now could call iscygtty(STDIN_FILENO) in order to detect whether they are running from Cygwin/MSys terminal. Without that, they have no choice but to think that stdin is redirected from a named pipe. Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/A

Re: [Mingw-w64-public] [PATCH v2] Add include/iscygtty.c

2016-11-11 Thread Mihail Konev
On Fri, Nov 11, 2016 at 11:19:45AM -0500, Earnie wrote: > On 11/10/2016 5:43 PM, Mihail Konev wrote: > > Applications now could call iscygtty(STDIN_FILENO) > > in order to detect whether they are running from > > Cygwin/MSys terminal. > > > > Should this be sha

[Mingw-w64-public] [PATCH v2] Add include/iscygtty.c

2016-11-10 Thread Mihail Konev
Applications now could call iscygtty(STDIN_FILENO) in order to detect whether they are running from Cygwin/MSys terminal. Without that, they have no choice but to think that stdin is redirected from a named pipe. Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/A

Re: [Mingw-w64-public] [PATCH mingw-w64] Add include/iscygtty.c

2016-11-10 Thread Mihail Konev
There are files that were catenated. Running curses in conemu should be possible with https://conemu.github.io/en/CygwinMsysConnector.html But even then, the iscygtty() is supposed to check whether it is present with a mintty-like stdin, and nothing else. all: test a.exe: main.c $(CC)

[Mingw-w64-public] [k....@ya.ru: Re: [PATCH mingw-w64] Add include/iscygtty.c]

2016-11-10 Thread Mihail Konev
Wrong destination address :) I didn't tried ConEmu. Is it possible to run cygwin curses app in it, like a text editor, btw? But with msys mintty and standard Console results do differ. - Forwarded message from Mihail Konev <k@ya.ru> - From: Mihail Konev <k@ya.ru>

[Mingw-w64-public] [k....@ya.ru: Re: Fwd: [PATCH mingw-w64] Add include/iscygtty.c]

2016-11-10 Thread Mihail Konev
- Forwarded message from Mihail Konev <k@ya.ru> - From: Mihail Konev <k@ya.ru> To: David Wohlferd <d...@limegreensocks.com> Date: Thu, 10 Nov 2016 23:22:48 +0500 Subject: Re: Fwd: [Mingw-w64-public] [PATCH mingw-w64] Add include/iscygtty.c On Wed, Nov 09, 2016 a

[Mingw-w64-public] [PATCH mingw-w64] Add include/iscygtty.c

2016-11-09 Thread Mihail Konev
Applications now could call iscygtty(STDIN_FILENO) in order to detect whether they are running from Cygwin/MSys terminal. Without that, they have no choice but to think that stdin is redirected from a named pipe. Signed-off-by: Mihail Konev <k@ya.ru> Moved-from: https://github.com/A