1
- From d9b4e1decb9999a9e1577eafeea8ae337d44924b Mon Sep 17 00:00:00 2001
1
+ From 50d9d80db4a6a941a03d99d82afb760c4ab4101f Mon Sep 17 00:00:00 2001
2
2
From: =?UTF-8?q?=D0=90=D0=BB=D0=B5=D0=BA=D1=81=D0=B5=D0=B8=CC=86=20=D0=9F?=
3
3
=?UTF-8?q?=D0=B0=D0=B2=D0=BB=D0=BE=D0=B2?= <
[email protected] >
4
4
Date: Sun, 14 Apr 2019 21:09:17 +0300
5
- Subject: [PATCH 03 /N] Rename dll from cygwin to msys
5
+ Subject: [PATCH 02 /N] Rename dll from cygwin to msys
6
6
7
7
---
8
8
winsup/cygserver/transport_pipes.h | 4 +++
@@ -16,7 +16,7 @@ Subject: [PATCH 03/N] Rename dll from cygwin to msys
16
16
winsup/cygwin/dtable.cc | 6 +++++
17
17
winsup/cygwin/exceptions.cc | 4 +--
18
18
winsup/cygwin/fhandler/pipe.cc | 4 +++
19
- winsup/cygwin/fhandler/pty.cc | 20 ++++++++++++++
19
+ winsup/cygwin/fhandler/pty.cc | 26 ++++ ++++++++++++++
20
20
winsup/cygwin/hookapi.cc | 4 +++
21
21
winsup/cygwin/include/cygwin/cygwin_dll.h | 10 +++----
22
22
winsup/cygwin/include/cygwin/version.h | 8 ++++++
@@ -38,7 +38,7 @@ Subject: [PATCH 03/N] Rename dll from cygwin to msys
38
38
winsup/utils/mingw/strace.cc | 9 +++----
39
39
winsup/utils/path.cc | 12 ++++-----
40
40
winsup/utils/ssp.c | 8 +++---
41
- 33 files changed, 174 insertions(+), 72 deletions(-)
41
+ 33 files changed, 180 insertions(+), 72 deletions(-)
42
42
43
43
diff --git a/winsup/cygserver/transport_pipes.h b/winsup/cygserver/transport_pipes.h
44
44
index e101623..66272bc 100644
@@ -57,7 +57,7 @@ index e101623..66272bc 100644
57
57
58
58
/* Named pipes based transport, for security on NT */
59
59
diff --git a/winsup/cygwin/Makefile.am b/winsup/cygwin/Makefile.am
60
- index d47a1a2..c1f9921 100644
60
+ index 383f4f3..981877d 100644
61
61
--- a/winsup/cygwin/Makefile.am
62
62
+++ b/winsup/cygwin/Makefile.am
63
63
@@ -37,12 +37,12 @@ newlib_build=$(target_builddir)/newlib
@@ -78,7 +78,7 @@ index d47a1a2..c1f9921 100644
78
78
79
79
#
80
80
# sources
81
- @@ -587 ,16 +587 ,16 @@ LIBSERVER = $(cygserver_blddir)/libcygserver.a
81
+ @@ -589 ,16 +589 ,16 @@ LIBSERVER = $(cygserver_blddir)/libcygserver.a
82
82
$(LIBSERVER):
83
83
$(MAKE) -C $(cygserver_blddir) libcygserver.a
84
84
@@ -98,7 +98,7 @@ index d47a1a2..c1f9921 100644
98
98
# Set PE and export table header timestamps to zero for reproducible builds.
99
99
$(NEW_DLL_NAME): $(LDSCRIPT) libdll.a $(VERSION_OFILES) $(LIBSERVER)\
100
100
$(newlib_build)/libm.a $(newlib_build)/libc.a
101
- @@ -605 ,18 +605 ,18 @@ $(NEW_DLL_NAME): $(LDSCRIPT) libdll.a $(VERSION_OFILES) $(LIBSERVER)\
101
+ @@ -607 ,18 +607 ,18 @@ $(NEW_DLL_NAME): $(LDSCRIPT) libdll.a $(VERSION_OFILES) $(LIBSERVER)\
102
102
-Wl,--gc-sections -nostdlib -Wl,-T$(LDSCRIPT) \
103
103
-Wl,--dynamicbase -static \
104
104
$${SOURCE_DATE_EPOCH:+-Wl,--no-insert-timestamp} \
@@ -120,7 +120,7 @@ index d47a1a2..c1f9921 100644
120
120
toolopts=--cpu=@target_cpu@ --ar=@AR@ --as=@AS@ --nm=@NM@ --objcopy=@OBJCOPY@
121
121
122
122
$(DEF_FILE): scripts/gendef cygwin.din
123
- @@ -629 ,13 +629 ,14 @@ sigfe.s: $(DEF_FILE) tlsoffsets
123
+ @@ -631 ,13 +631 ,14 @@ sigfe.s: $(DEF_FILE) tlsoffsets
124
124
125
125
LIBCOS=$(addsuffix .o,$(basename $(LIB_FILES)))
126
126
$(LIB_NAME): $(DEF_FILE) $(LIBCOS) | $(NEW_DLL_NAME)
@@ -136,7 +136,7 @@ index d47a1a2..c1f9921 100644
136
136
--exclude='(?i:dll)' \
137
137
--exclude='reloc' \
138
138
--exclude='^main$$' \
139
- @@ -685 ,7 +686 ,7 @@ all-local: $(LIB_NAME) $(SUBLIBS)
139
+ @@ -687 ,7 +688 ,7 @@ all-local: $(LIB_NAME) $(SUBLIBS)
140
140
clean-local:
141
141
-rm -f $(BUILT_SOURCES)
142
142
-rm -f $(DEF_FILE) sigfe.s
@@ -223,10 +223,10 @@ index f4c09be..e19b7d3 100644
223
223
static int _fmode;
224
224
225
225
diff --git a/winsup/cygwin/dlfcn.cc b/winsup/cygwin/dlfcn.cc
226
- index 9b6bb55..2d0bae5 100644
226
+ index e06616d..40d99dd 100644
227
227
--- a/winsup/cygwin/dlfcn.cc
228
228
+++ b/winsup/cygwin/dlfcn.cc
229
- @@ -147 ,8 +147 ,13 @@ collect_basenames (pathfinder::basenamelist & basenames,
229
+ @@ -148 ,8 +148 ,13 @@ collect_basenames (pathfinder::basenamelist & basenames,
230
230
/* If the basename starts with "lib", ... */
231
231
if (!strncmp (basename, "lib", 3))
232
232
{
@@ -277,7 +277,7 @@ index 7303f7e..6ccc19a 100644
277
277
w32len = cygheap->installation_key.Length / sizeof (WCHAR);
278
278
if (w32len
279
279
diff --git a/winsup/cygwin/exceptions.cc b/winsup/cygwin/exceptions.cc
280
- index 876b79e..466abdd 100644
280
+ index f79978f..e724e37 100644
281
281
--- a/winsup/cygwin/exceptions.cc
282
282
+++ b/winsup/cygwin/exceptions.cc
283
283
@@ -528,14 +528,14 @@ int exec_prepared_command (PWCHAR command)
@@ -298,10 +298,10 @@ index 876b79e..466abdd 100644
298
298
break;
299
299
}
300
300
diff --git a/winsup/cygwin/fhandler/pipe.cc b/winsup/cygwin/fhandler/pipe.cc
301
- index e35d523..506dd09 100644
301
+ index 2ff5dfa..11ef78c 100644
302
302
--- a/winsup/cygwin/fhandler/pipe.cc
303
303
+++ b/winsup/cygwin/fhandler/pipe.cc
304
- @@ -790 ,7 +790 ,11 @@ fhandler_pipe::close (int flag)
304
+ @@ -798 ,7 +798 ,11 @@ fhandler_pipe::close (int flag)
305
305
return ret;
306
306
}
307
307
@@ -314,10 +314,10 @@ index e35d523..506dd09 100644
314
314
/* Create a pipe, and return handles to the read and write ends,
315
315
just like CreatePipe, but ensure that the write end permits
316
316
diff --git a/winsup/cygwin/fhandler/pty.cc b/winsup/cygwin/fhandler/pty.cc
317
- index 3128b92..0969b2f 100644
317
+ index 36fddbb..8154fcc 100644
318
318
--- a/winsup/cygwin/fhandler/pty.cc
319
319
+++ b/winsup/cygwin/fhandler/pty.cc
320
- @@ -875 ,7 +875 ,11 @@ fhandler_pty_slave::open (int flags, mode_t)
320
+ @@ -882 ,7 +882 ,11 @@ fhandler_pty_slave::open (int flags, mode_t)
321
321
pipe_reply repl;
322
322
DWORD len;
323
323
@@ -329,7 +329,7 @@ index 3128b92..0969b2f 100644
329
329
&cygheap->installation_key, get_minor ());
330
330
termios_printf ("dup handles via master control pipe %s", buf);
331
331
if (!CallNamedPipe (buf, &req, sizeof req, &repl, sizeof repl,
332
- @@ -1137 ,7 +1141 ,11 @@ fhandler_pty_slave::reset_switch_to_nat_pipe (void)
332
+ @@ -1144 ,7 +1148 ,11 @@ fhandler_pty_slave::reset_switch_to_nat_pipe (void)
333
333
{
334
334
char pipe[MAX_PATH];
335
335
__small_sprintf (pipe,
@@ -339,9 +339,25 @@ index 3128b92..0969b2f 100644
339
339
"\\\\.\\pipe\\cygwin-%S-pty%d-master-ctl",
340
340
+ #endif
341
341
&cygheap->installation_key, get_minor ());
342
- pipe_request req = { GetCurrentProcessId () };
342
+ pipe_request req = { GET_HANDLES, GetCurrentProcessId () };
343
343
pipe_reply repl;
344
- @@ -2024,7 +2032,11 @@ fhandler_pty_master::close (int flag)
344
+ @@ -1605,9 +1613,15 @@ fhandler_pty_slave::tcflush (int queue)
345
+ if (queue == TCIFLUSH || queue == TCIOFLUSH)
346
+ {
347
+ char pipe[MAX_PATH];
348
+ + #ifdef __MSYS__
349
+ + __small_sprintf (pipe,
350
+ + "\\\\.\\pipe\\msys-%S-pty%d-master-ctl",
351
+ + &cygheap->installation_key, get_minor ());
352
+ + #else
353
+ __small_sprintf (pipe,
354
+ "\\\\.\\pipe\\cygwin-%S-pty%d-master-ctl",
355
+ &cygheap->installation_key, get_minor ());
356
+ + #endif
357
+ pipe_request req = { FLUSH_INPUT, GetCurrentProcessId () };
358
+ pipe_reply repl;
359
+ DWORD n;
360
+ @@ -2039,7 +2053,11 @@ fhandler_pty_master::close (int flag)
345
361
pipe_reply repl;
346
362
DWORD len;
347
363
@@ -353,7 +369,7 @@ index 3128b92..0969b2f 100644
353
369
&cygheap->installation_key, get_minor ());
354
370
acquire_output_mutex (mutex_timeout);
355
371
if (master_ctl)
356
- @@ -2930 ,7 +2942 ,11 @@ fhandler_pty_master::setup ()
372
+ @@ -2950 ,7 +2968 ,11 @@ fhandler_pty_master::setup ()
357
373
358
374
/* Create master control pipe which allows the master to duplicate
359
375
the pty pipe handles to processes which deserve it. */
@@ -365,7 +381,7 @@ index 3128b92..0969b2f 100644
365
381
&cygheap->installation_key, unit);
366
382
master_ctl = CreateNamedPipe (buf, PIPE_ACCESS_DUPLEX
367
383
| FILE_FLAG_FIRST_PIPE_INSTANCE,
368
- @@ -3819 ,7 +3835 ,11 @@ fhandler_pty_slave::transfer_input (tty::xfer_dir dir, HANDLE from, tty *ttyp,
384
+ @@ -3840 ,7 +3862 ,11 @@ fhandler_pty_slave::transfer_input (tty::xfer_dir dir, HANDLE from, tty *ttyp,
369
385
{
370
386
char pipe[MAX_PATH];
371
387
__small_sprintf (pipe,
@@ -375,7 +391,7 @@ index 3128b92..0969b2f 100644
375
391
"\\\\.\\pipe\\cygwin-%S-pty%d-master-ctl",
376
392
+ #endif
377
393
&cygheap->installation_key, ttyp->get_minor ());
378
- pipe_request req = { GetCurrentProcessId () };
394
+ pipe_request req = { GET_HANDLES, GetCurrentProcessId () };
379
395
pipe_reply repl;
380
396
diff --git a/winsup/cygwin/hookapi.cc b/winsup/cygwin/hookapi.cc
381
397
index ee2edba..9f31a71 100644
@@ -436,7 +452,7 @@ index 1e4cf98..b77598b 100644
436
452
} \
437
453
} \
438
454
diff --git a/winsup/cygwin/include/cygwin/version.h b/winsup/cygwin/include/cygwin/version.h
439
- index 961a98c..aafb811 100644
455
+ index 89c1e1f..b85e8c3 100644
440
456
--- a/winsup/cygwin/include/cygwin/version.h
441
457
+++ b/winsup/cygwin/include/cygwin/version.h
442
458
@@ -510,7 +510,11 @@ details. */
0 commit comments