passenger 5.0.8 → 5.0.9

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of passenger might be problematic. Click here for more details.

Files changed (168) hide show
  1. checksums.yaml +8 -8
  2. checksums.yaml.gz.asc +7 -7
  3. data.tar.gz.asc +7 -7
  4. data/.editorconfig +20 -0
  5. data/CHANGELOG +21 -0
  6. data/bin/passenger-install-apache2-module +3 -1
  7. data/build/agents.rb +7 -5
  8. data/build/basics.rb +3 -3
  9. data/build/common_library.rb +52 -30
  10. data/build/cxx_tests.rb +20 -13
  11. data/build/misc.rb +5 -5
  12. data/doc/Design and Architecture.html +1 -1
  13. data/doc/Design and Architecture.txt +1 -1
  14. data/doc/Packaging.html +4 -4
  15. data/doc/Packaging.txt.md +4 -4
  16. data/doc/Users guide Apache.html +22 -9
  17. data/doc/Users guide Apache.idmap.txt +4 -2
  18. data/doc/Users guide Apache.txt +2 -0
  19. data/doc/Users guide Nginx.html +22 -9
  20. data/doc/Users guide Nginx.idmap.txt +4 -2
  21. data/doc/Users guide Nginx.txt +2 -0
  22. data/doc/Users guide Standalone.html +14 -9
  23. data/doc/Users guide Standalone.idmap.txt +4 -2
  24. data/doc/users_guide_snippets/installation.txt +10 -6
  25. data/ext/apache2/Hooks.cpp +13 -2
  26. data/ext/common/ApplicationPool2/Pool/Inspection.h +8 -3
  27. data/ext/common/BackgroundEventLoop.cpp +249 -67
  28. data/ext/common/BackgroundEventLoop.h +5 -5
  29. data/ext/common/Constants.h +1 -1
  30. data/ext/common/InstanceDirectory.h +8 -6
  31. data/ext/common/ServerKit/Context.h +8 -2
  32. data/ext/common/ServerKit/FileBufferedChannel.h +262 -226
  33. data/ext/common/ServerKit/HeaderTable.h +28 -3
  34. data/ext/common/ServerKit/HttpHeaderParser.h +37 -13
  35. data/ext/common/ServerKit/HttpServer.h +17 -1
  36. data/ext/common/ServerKit/Implementation.cpp +2 -0
  37. data/ext/common/ServerKit/Server.h +25 -28
  38. data/ext/common/Utils/IOUtils.cpp +11 -0
  39. data/ext/common/Utils/ProcessMetricsCollector.h +4 -0
  40. data/ext/common/Utils/StrIntUtils.cpp +11 -7
  41. data/ext/common/Utils/StrIntUtils.h +1 -1
  42. data/ext/common/Utils/StrIntUtilsNoStrictAliasing.cpp +21 -16
  43. data/ext/common/agents/Base.cpp +6 -0
  44. data/ext/common/agents/Base.h +2 -0
  45. data/ext/common/agents/HelperAgent/AdminServer.h +25 -25
  46. data/ext/common/agents/HelperAgent/Main.cpp +37 -12
  47. data/ext/common/agents/HelperAgent/RequestHandler.h +18 -20
  48. data/ext/common/agents/HelperAgent/RequestHandler/AppResponse.h +4 -0
  49. data/ext/common/agents/HelperAgent/RequestHandler/ForwardResponse.cpp +10 -6
  50. data/ext/common/agents/HelperAgent/RequestHandler/Hooks.cpp +2 -0
  51. data/ext/common/agents/HelperAgent/RequestHandler/InitRequest.cpp +1 -1
  52. data/ext/common/agents/HelperAgent/RequestHandler/SendRequest.cpp +1 -1
  53. data/ext/common/agents/HelperAgent/RequestHandler/Utils.cpp +9 -2
  54. data/ext/common/agents/HelperAgent/ResponseCache.h +11 -11
  55. data/ext/common/agents/LoggingAgent/AdminServer.h +8 -8
  56. data/ext/common/agents/LoggingAgent/Main.cpp +6 -5
  57. data/ext/common/agents/Watchdog/AdminServer.h +13 -13
  58. data/ext/common/agents/Watchdog/Main.cpp +8 -3
  59. data/ext/libuv/.gitignore +72 -0
  60. data/ext/libuv/AUTHORS +199 -0
  61. data/ext/libuv/ChangeLog +2023 -0
  62. data/ext/libuv/LICENSE +46 -0
  63. data/ext/libuv/Makefile.am +336 -0
  64. data/ext/libuv/README.md +197 -0
  65. data/ext/libuv/checksparse.sh +233 -0
  66. data/ext/libuv/common.gypi +210 -0
  67. data/ext/libuv/configure.ac +67 -0
  68. data/ext/libuv/gyp_uv.py +96 -0
  69. data/ext/libuv/include/android-ifaddrs.h +54 -0
  70. data/ext/libuv/include/pthread-fixes.h +72 -0
  71. data/ext/libuv/include/tree.h +768 -0
  72. data/ext/libuv/include/uv-aix.h +32 -0
  73. data/ext/libuv/include/uv-bsd.h +34 -0
  74. data/ext/libuv/include/uv-darwin.h +61 -0
  75. data/ext/libuv/include/uv-errno.h +418 -0
  76. data/ext/libuv/include/uv-linux.h +34 -0
  77. data/ext/libuv/include/uv-sunos.h +44 -0
  78. data/ext/libuv/include/uv-threadpool.h +37 -0
  79. data/ext/libuv/include/uv-unix.h +383 -0
  80. data/ext/libuv/include/uv-version.h +39 -0
  81. data/ext/libuv/include/uv.h +1455 -0
  82. data/ext/libuv/libuv.pc.in +11 -0
  83. data/ext/libuv/m4/.gitignore +4 -0
  84. data/ext/libuv/m4/as_case.m4 +21 -0
  85. data/ext/libuv/m4/libuv-check-flags.m4 +319 -0
  86. data/ext/libuv/src/fs-poll.c +255 -0
  87. data/ext/libuv/src/heap-inl.h +245 -0
  88. data/ext/libuv/src/inet.c +313 -0
  89. data/ext/libuv/src/queue.h +92 -0
  90. data/ext/libuv/src/threadpool.c +303 -0
  91. data/ext/libuv/src/unix/aix.c +1240 -0
  92. data/ext/libuv/src/unix/android-ifaddrs.c +703 -0
  93. data/ext/libuv/src/unix/async.c +284 -0
  94. data/ext/libuv/src/unix/atomic-ops.h +60 -0
  95. data/ext/libuv/src/unix/core.c +985 -0
  96. data/ext/libuv/src/unix/darwin-proctitle.c +206 -0
  97. data/ext/libuv/src/unix/darwin.c +331 -0
  98. data/ext/libuv/src/unix/dl.c +83 -0
  99. data/ext/libuv/src/unix/freebsd.c +435 -0
  100. data/ext/libuv/src/unix/fs.c +1189 -0
  101. data/ext/libuv/src/unix/fsevents.c +899 -0
  102. data/ext/libuv/src/unix/getaddrinfo.c +202 -0
  103. data/ext/libuv/src/unix/getnameinfo.c +120 -0
  104. data/ext/libuv/src/unix/internal.h +314 -0
  105. data/ext/libuv/src/unix/kqueue.c +418 -0
  106. data/ext/libuv/src/unix/linux-core.c +876 -0
  107. data/ext/libuv/src/unix/linux-inotify.c +257 -0
  108. data/ext/libuv/src/unix/linux-syscalls.c +471 -0
  109. data/ext/libuv/src/unix/linux-syscalls.h +158 -0
  110. data/ext/libuv/src/unix/loop-watcher.c +63 -0
  111. data/ext/libuv/src/unix/loop.c +135 -0
  112. data/ext/libuv/src/unix/netbsd.c +368 -0
  113. data/ext/libuv/src/unix/openbsd.c +384 -0
  114. data/ext/libuv/src/unix/pipe.c +288 -0
  115. data/ext/libuv/src/unix/poll.c +113 -0
  116. data/ext/libuv/src/unix/process.c +551 -0
  117. data/ext/libuv/src/unix/proctitle.c +102 -0
  118. data/ext/libuv/src/unix/pthread-fixes.c +103 -0
  119. data/ext/libuv/src/unix/signal.c +465 -0
  120. data/ext/libuv/src/unix/spinlock.h +53 -0
  121. data/ext/libuv/src/unix/stream.c +1598 -0
  122. data/ext/libuv/src/unix/sunos.c +763 -0
  123. data/ext/libuv/src/unix/tcp.c +327 -0
  124. data/ext/libuv/src/unix/thread.c +519 -0
  125. data/ext/libuv/src/unix/timer.c +172 -0
  126. data/ext/libuv/src/unix/tty.c +265 -0
  127. data/ext/libuv/src/unix/udp.c +833 -0
  128. data/ext/libuv/src/uv-common.c +544 -0
  129. data/ext/libuv/src/uv-common.h +214 -0
  130. data/ext/libuv/src/version.c +49 -0
  131. data/ext/libuv/uv.gyp +487 -0
  132. data/ext/nginx/ContentHandler.c +21 -10
  133. data/ext/nginx/ngx_http_passenger_module.c +7 -0
  134. data/ext/oxt/implementation.cpp +9 -2
  135. data/ext/oxt/initialize.hpp +5 -1
  136. data/lib/phusion_passenger.rb +3 -3
  137. data/lib/phusion_passenger/admin_tools/instance.rb +10 -6
  138. data/lib/phusion_passenger/admin_tools/instance_registry.rb +6 -2
  139. data/lib/phusion_passenger/packaging.rb +3 -4
  140. data/lib/phusion_passenger/platform_info.rb +13 -1
  141. data/lib/phusion_passenger/platform_info/apache.rb +15 -4
  142. data/lib/phusion_passenger/platform_info/apache_detector.rb +5 -1
  143. data/lib/phusion_passenger/rack/thread_handler_extension.rb +184 -99
  144. data/lib/phusion_passenger/request_handler/thread_handler.rb +13 -6
  145. data/lib/phusion_passenger/standalone/start_command.rb +2 -2
  146. data/resources/templates/apache2/apache_install_broken.txt.erb +2 -1
  147. metadata +99 -22
  148. metadata.gz.asc +7 -7
  149. data/ext/libeio/Changes +0 -76
  150. data/ext/libeio/LICENSE +0 -36
  151. data/ext/libeio/Makefile.am +0 -15
  152. data/ext/libeio/Makefile.in +0 -694
  153. data/ext/libeio/aclocal.m4 +0 -9418
  154. data/ext/libeio/autogen.sh +0 -3
  155. data/ext/libeio/config.guess +0 -1540
  156. data/ext/libeio/config.h.in +0 -136
  157. data/ext/libeio/config.sub +0 -1779
  158. data/ext/libeio/configure +0 -14822
  159. data/ext/libeio/configure.ac +0 -22
  160. data/ext/libeio/demo.c +0 -194
  161. data/ext/libeio/ecb.h +0 -714
  162. data/ext/libeio/eio.c +0 -2818
  163. data/ext/libeio/eio.h +0 -414
  164. data/ext/libeio/install-sh +0 -520
  165. data/ext/libeio/libeio.m4 +0 -195
  166. data/ext/libeio/ltmain.sh +0 -9636
  167. data/ext/libeio/missing +0 -376
  168. data/ext/libeio/xthread.h +0 -166
@@ -0,0 +1,46 @@
1
+ libuv is part of the Node project: http://nodejs.org/
2
+ libuv may be distributed alone under Node's license:
3
+
4
+ ====
5
+
6
+ Copyright Joyent, Inc. and other Node contributors. All rights reserved.
7
+ Permission is hereby granted, free of charge, to any person obtaining a copy
8
+ of this software and associated documentation files (the "Software"), to
9
+ deal in the Software without restriction, including without limitation the
10
+ rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
11
+ sell copies of the Software, and to permit persons to whom the Software is
12
+ furnished to do so, subject to the following conditions:
13
+
14
+ The above copyright notice and this permission notice shall be included in
15
+ all copies or substantial portions of the Software.
16
+
17
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
22
+ FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
23
+ IN THE SOFTWARE.
24
+
25
+ ====
26
+
27
+ This license applies to all parts of libuv that are not externally
28
+ maintained libraries.
29
+
30
+ The externally maintained libraries used by libuv are:
31
+
32
+ - tree.h (from FreeBSD), copyright Niels Provos. Two clause BSD license.
33
+
34
+ - inet_pton and inet_ntop implementations, contained in src/inet.c, are
35
+ copyright the Internet Systems Consortium, Inc., and licensed under the ISC
36
+ license.
37
+
38
+ - stdint-msvc2008.h (from msinttypes), copyright Alexander Chemeris. Three
39
+ clause BSD license.
40
+
41
+ - pthread-fixes.h, pthread-fixes.c, copyright Google Inc. and Sony Mobile
42
+ Communications AB. Three clause BSD license.
43
+
44
+ - android-ifaddrs.h, android-ifaddrs.c, copyright Berkeley Software Design
45
+ Inc, Kenneth MacKay and Emergya (Cloud4all, FP7/2007-2013, grant agreement
46
+ n° 289016). Three clause BSD license.
@@ -0,0 +1,336 @@
1
+ # Copyright (c) 2013, Ben Noordhuis <info@bnoordhuis.nl>
2
+ #
3
+ # Permission to use, copy, modify, and/or distribute this software for any
4
+ # purpose with or without fee is hereby granted, provided that the above
5
+ # copyright notice and this permission notice appear in all copies.
6
+ #
7
+ # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
8
+ # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
9
+ # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
10
+ # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
11
+ # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
12
+ # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
13
+ # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
14
+
15
+ ACLOCAL_AMFLAGS = -I m4
16
+
17
+ AM_CPPFLAGS = -I$(top_srcdir)/include \
18
+ -I$(top_srcdir)/src
19
+
20
+ include_HEADERS=include/uv.h include/uv-errno.h include/uv-threadpool.h include/uv-version.h
21
+
22
+ CLEANFILES =
23
+
24
+ lib_LTLIBRARIES = libuv.la
25
+ libuv_la_CFLAGS = @CFLAGS@
26
+ libuv_la_LDFLAGS = -no-undefined -version-info 1:0:0
27
+ libuv_la_SOURCES = src/fs-poll.c \
28
+ src/heap-inl.h \
29
+ src/inet.c \
30
+ src/queue.h \
31
+ src/threadpool.c \
32
+ src/uv-common.c \
33
+ src/uv-common.h \
34
+ src/version.c
35
+
36
+ if SUNOS
37
+ # Can't be turned into a CC_CHECK_CFLAGS in configure.ac, it makes compilers
38
+ # on other platforms complain that the argument is unused during compilation.
39
+ libuv_la_CFLAGS += -pthread
40
+ endif
41
+
42
+ if WINNT
43
+
44
+ include_HEADERS += include/uv-win.h include/tree.h
45
+ AM_CPPFLAGS += -I$(top_srcdir)/src/win \
46
+ -DWIN32_LEAN_AND_MEAN \
47
+ -D_WIN32_WINNT=0x0600
48
+ LIBS += -lws2_32 -lpsapi -liphlpapi -lshell32
49
+ libuv_la_SOURCES += src/win/async.c \
50
+ src/win/atomicops-inl.h \
51
+ src/win/core.c \
52
+ src/win/dl.c \
53
+ src/win/error.c \
54
+ src/win/fs-event.c \
55
+ src/win/fs.c \
56
+ src/win/getaddrinfo.c \
57
+ src/win/getnameinfo.c \
58
+ src/win/handle.c \
59
+ src/win/handle-inl.h \
60
+ src/win/internal.h \
61
+ src/win/loop-watcher.c \
62
+ src/win/pipe.c \
63
+ src/win/poll.c \
64
+ src/win/process-stdio.c \
65
+ src/win/process.c \
66
+ src/win/req.c \
67
+ src/win/req-inl.h \
68
+ src/win/signal.c \
69
+ src/win/stream.c \
70
+ src/win/stream-inl.h \
71
+ src/win/tcp.c \
72
+ src/win/thread.c \
73
+ src/win/timer.c \
74
+ src/win/tty.c \
75
+ src/win/udp.c \
76
+ src/win/util.c \
77
+ src/win/winapi.c \
78
+ src/win/winapi.h \
79
+ src/win/winsock.c \
80
+ src/win/winsock.h
81
+
82
+ else # WINNT
83
+
84
+ include_HEADERS += include/uv-unix.h
85
+ AM_CPPFLAGS += -I$(top_srcdir)/src/unix
86
+ libuv_la_SOURCES += src/unix/async.c \
87
+ src/unix/atomic-ops.h \
88
+ src/unix/core.c \
89
+ src/unix/dl.c \
90
+ src/unix/fs.c \
91
+ src/unix/getaddrinfo.c \
92
+ src/unix/getnameinfo.c \
93
+ src/unix/internal.h \
94
+ src/unix/loop-watcher.c \
95
+ src/unix/loop.c \
96
+ src/unix/pipe.c \
97
+ src/unix/poll.c \
98
+ src/unix/process.c \
99
+ src/unix/signal.c \
100
+ src/unix/spinlock.h \
101
+ src/unix/stream.c \
102
+ src/unix/tcp.c \
103
+ src/unix/thread.c \
104
+ src/unix/timer.c \
105
+ src/unix/tty.c \
106
+ src/unix/udp.c
107
+
108
+ endif # WINNT
109
+
110
+ EXTRA_DIST = test/fixtures/empty_file \
111
+ test/fixtures/load_error.node \
112
+ include \
113
+ test \
114
+ docs \
115
+ img \
116
+ samples \
117
+ android-configure \
118
+ CONTRIBUTING.md \
119
+ LICENSE \
120
+ README.md \
121
+ checksparse.sh \
122
+ vcbuild.bat \
123
+ Makefile.mingw \
124
+ common.gypi \
125
+ gyp_uv.py \
126
+ uv.gyp
127
+
128
+
129
+
130
+ TESTS = test/run-tests
131
+ check_PROGRAMS = test/run-tests
132
+ test_run_tests_CFLAGS =
133
+ test_run_tests_SOURCES = test/blackhole-server.c \
134
+ test/dns-server.c \
135
+ test/echo-server.c \
136
+ test/run-tests.c \
137
+ test/runner.c \
138
+ test/runner.h \
139
+ test/task.h \
140
+ test/test-active.c \
141
+ test/test-async.c \
142
+ test/test-async-null-cb.c \
143
+ test/test-barrier.c \
144
+ test/test-callback-order.c \
145
+ test/test-callback-stack.c \
146
+ test/test-close-fd.c \
147
+ test/test-close-order.c \
148
+ test/test-condvar.c \
149
+ test/test-connection-fail.c \
150
+ test/test-cwd-and-chdir.c \
151
+ test/test-default-loop-close.c \
152
+ test/test-delayed-accept.c \
153
+ test/test-dlerror.c \
154
+ test/test-embed.c \
155
+ test/test-emfile.c \
156
+ test/test-error.c \
157
+ test/test-fail-always.c \
158
+ test/test-fs-event.c \
159
+ test/test-fs-poll.c \
160
+ test/test-fs.c \
161
+ test/test-get-currentexe.c \
162
+ test/test-get-loadavg.c \
163
+ test/test-get-memory.c \
164
+ test/test-getaddrinfo.c \
165
+ test/test-getnameinfo.c \
166
+ test/test-getsockname.c \
167
+ test/test-handle-fileno.c \
168
+ test/test-hrtime.c \
169
+ test/test-idle.c \
170
+ test/test-ip4-addr.c \
171
+ test/test-ip6-addr.c \
172
+ test/test-ipc-send-recv.c \
173
+ test/test-ipc.c \
174
+ test/test-list.h \
175
+ test/test-loop-handles.c \
176
+ test/test-loop-alive.c \
177
+ test/test-loop-close.c \
178
+ test/test-loop-stop.c \
179
+ test/test-loop-time.c \
180
+ test/test-loop-configure.c \
181
+ test/test-multiple-listen.c \
182
+ test/test-mutexes.c \
183
+ test/test-osx-select.c \
184
+ test/test-pass-always.c \
185
+ test/test-ping-pong.c \
186
+ test/test-pipe-bind-error.c \
187
+ test/test-pipe-connect-error.c \
188
+ test/test-pipe-getsockname.c \
189
+ test/test-pipe-sendmsg.c \
190
+ test/test-pipe-server-close.c \
191
+ test/test-pipe-close-stdout-read-stdin.c \
192
+ test/test-pipe-set-non-blocking.c \
193
+ test/test-platform-output.c \
194
+ test/test-poll-close.c \
195
+ test/test-poll-close-doesnt-corrupt-stack.c \
196
+ test/test-poll-closesocket.c \
197
+ test/test-poll.c \
198
+ test/test-process-title.c \
199
+ test/test-ref.c \
200
+ test/test-run-nowait.c \
201
+ test/test-run-once.c \
202
+ test/test-semaphore.c \
203
+ test/test-shutdown-close.c \
204
+ test/test-shutdown-eof.c \
205
+ test/test-shutdown-twice.c \
206
+ test/test-signal-multiple-loops.c \
207
+ test/test-signal.c \
208
+ test/test-socket-buffer-size.c \
209
+ test/test-spawn.c \
210
+ test/test-stdio-over-pipes.c \
211
+ test/test-tcp-bind-error.c \
212
+ test/test-tcp-bind6-error.c \
213
+ test/test-tcp-close-accept.c \
214
+ test/test-tcp-close-while-connecting.c \
215
+ test/test-tcp-close.c \
216
+ test/test-tcp-connect-error-after-write.c \
217
+ test/test-tcp-connect-error.c \
218
+ test/test-tcp-connect-timeout.c \
219
+ test/test-tcp-connect6-error.c \
220
+ test/test-tcp-flags.c \
221
+ test/test-tcp-open.c \
222
+ test/test-tcp-read-stop.c \
223
+ test/test-tcp-shutdown-after-write.c \
224
+ test/test-tcp-unexpected-read.c \
225
+ test/test-tcp-oob.c \
226
+ test/test-tcp-write-to-half-open-connection.c \
227
+ test/test-tcp-write-after-connect.c \
228
+ test/test-tcp-writealot.c \
229
+ test/test-tcp-write-fail.c \
230
+ test/test-tcp-try-write.c \
231
+ test/test-tcp-write-queue-order.c \
232
+ test/test-thread-equal.c \
233
+ test/test-thread.c \
234
+ test/test-threadpool-cancel.c \
235
+ test/test-threadpool.c \
236
+ test/test-timer-again.c \
237
+ test/test-timer-from-check.c \
238
+ test/test-timer.c \
239
+ test/test-tty.c \
240
+ test/test-udp-bind.c \
241
+ test/test-udp-dgram-too-big.c \
242
+ test/test-udp-ipv6.c \
243
+ test/test-udp-multicast-interface.c \
244
+ test/test-udp-multicast-interface6.c \
245
+ test/test-udp-multicast-join.c \
246
+ test/test-udp-multicast-join6.c \
247
+ test/test-udp-multicast-ttl.c \
248
+ test/test-udp-open.c \
249
+ test/test-udp-options.c \
250
+ test/test-udp-send-and-recv.c \
251
+ test/test-udp-send-immediate.c \
252
+ test/test-udp-send-unreachable.c \
253
+ test/test-udp-try-send.c \
254
+ test/test-walk-handles.c \
255
+ test/test-watcher-cross-stop.c
256
+ test_run_tests_LDADD = libuv.la
257
+
258
+ if WINNT
259
+ test_run_tests_SOURCES += test/runner-win.c \
260
+ test/runner-win.h
261
+ else
262
+ test_run_tests_SOURCES += test/runner-unix.c \
263
+ test/runner-unix.h
264
+ endif
265
+
266
+ if AIX
267
+ test_run_tests_CFLAGS += -D_ALL_SOURCE -D_XOPEN_SOURCE=500 -D_LINUX_SOURCE_COMPAT
268
+ endif
269
+
270
+ if SUNOS
271
+ test_run_tests_CFLAGS += -D__EXTENSIONS__ -D_XOPEN_SOURCE=500
272
+ endif
273
+
274
+
275
+ if AIX
276
+ libuv_la_CFLAGS += -D_ALL_SOURCE -D_XOPEN_SOURCE=500 -D_LINUX_SOURCE_COMPAT
277
+ libuv_la_SOURCES += src/unix/aix.c
278
+ endif
279
+
280
+ if ANDROID
281
+ include_HEADERS += include/android-ifaddrs.h \
282
+ include/pthread-fixes.h
283
+ libuv_la_SOURCES += src/unix/android-ifaddrs.c \
284
+ src/unix/pthread-fixes.c
285
+ endif
286
+
287
+ if DARWIN
288
+ include_HEADERS += include/uv-darwin.h
289
+ libuv_la_CFLAGS += -D_DARWIN_USE_64_BIT_INODE=1
290
+ libuv_la_CFLAGS += -D_DARWIN_UNLIMITED_SELECT=1
291
+ libuv_la_SOURCES += src/unix/darwin.c \
292
+ src/unix/darwin-proctitle.c \
293
+ src/unix/fsevents.c \
294
+ src/unix/kqueue.c \
295
+ src/unix/proctitle.c
296
+ endif
297
+
298
+ if DRAGONFLY
299
+ include_HEADERS += include/uv-bsd.h
300
+ endif
301
+
302
+ if FREEBSD
303
+ include_HEADERS += include/uv-bsd.h
304
+ libuv_la_SOURCES += src/unix/freebsd.c src/unix/kqueue.c
305
+ endif
306
+
307
+ if LINUX
308
+ include_HEADERS += include/uv-linux.h
309
+ libuv_la_CFLAGS += -D_GNU_SOURCE
310
+ libuv_la_SOURCES += src/unix/linux-core.c \
311
+ src/unix/linux-inotify.c \
312
+ src/unix/linux-syscalls.c \
313
+ src/unix/linux-syscalls.h \
314
+ src/unix/proctitle.c
315
+ endif
316
+
317
+ if NETBSD
318
+ include_HEADERS += include/uv-bsd.h
319
+ libuv_la_SOURCES += src/unix/kqueue.c src/unix/netbsd.c
320
+ endif
321
+
322
+ if OPENBSD
323
+ include_HEADERS += include/uv-bsd.h
324
+ libuv_la_SOURCES += src/unix/kqueue.c src/unix/openbsd.c
325
+ endif
326
+
327
+ if SUNOS
328
+ include_HEADERS += include/uv-sunos.h
329
+ libuv_la_CFLAGS += -D__EXTENSIONS__ -D_XOPEN_SOURCE=500
330
+ libuv_la_SOURCES += src/unix/sunos.c
331
+ endif
332
+
333
+ if HAVE_PKG_CONFIG
334
+ pkgconfigdir = $(libdir)/pkgconfig
335
+ pkgconfig_DATA = @PACKAGE_NAME@.pc
336
+ endif
@@ -0,0 +1,197 @@
1
+ ![libuv][libuv_banner]
2
+
3
+ ## Overview
4
+
5
+ libuv is a multi-platform support library with a focus on asynchronous I/O. It
6
+ was primarily developed for use by [Node.js](http://nodejs.org), but it's also
7
+ used by [Luvit](http://luvit.io/), [Julia](http://julialang.org/),
8
+ [pyuv](https://github.com/saghul/pyuv), and [others](https://github.com/libuv/libuv/wiki/Projects-that-use-libuv).
9
+
10
+ ## Feature highlights
11
+
12
+ * Full-featured event loop backed by epoll, kqueue, IOCP, event ports.
13
+
14
+ * Asynchronous TCP and UDP sockets
15
+
16
+ * Asynchronous DNS resolution
17
+
18
+ * Asynchronous file and file system operations
19
+
20
+ * File system events
21
+
22
+ * ANSI escape code controlled TTY
23
+
24
+ * IPC with socket sharing, using Unix domain sockets or named pipes (Windows)
25
+
26
+ * Child processes
27
+
28
+ * Thread pool
29
+
30
+ * Signal handling
31
+
32
+ * High resolution clock
33
+
34
+ * Threading and synchronization primitives
35
+
36
+ ## Versioning
37
+
38
+ Starting with version 1.0.0 libuv follows the [semantic versioning](http://semver.org/)
39
+ scheme. The API change and backwards compatibility rules are those indicated by
40
+ SemVer. libuv will keep a stable ABI across major releases.
41
+
42
+ ## Community
43
+
44
+ * [Mailing list](http://groups.google.com/group/libuv)
45
+ * [IRC chatroom (#libuv@irc.freenode.org)](http://webchat.freenode.net?channels=libuv&uio=d4)
46
+
47
+ ## Documentation
48
+
49
+ ### Official API documentation
50
+
51
+ Located in the docs/ subdirectory. It uses the [Sphinx](http://sphinx-doc.org/)
52
+ framework, which makes it possible to build the documentation in multiple
53
+ formats.
54
+
55
+ Show different supported building options:
56
+
57
+ $ make help
58
+
59
+ Build documentation as HTML:
60
+
61
+ $ make html
62
+
63
+ Build documentation as man pages:
64
+
65
+ $ make man
66
+
67
+ Build documentation as ePub:
68
+
69
+ $ make epub
70
+
71
+ NOTE: Windows users need to use make.bat instead of plain 'make'.
72
+
73
+ Documentation can be browsed online [here](http://docs.libuv.org).
74
+
75
+ The [tests and benchmarks](https://github.com/libuv/libuv/tree/master/test)
76
+ also serve as API specification and usage examples.
77
+
78
+ ### Other resources
79
+
80
+ * [An Introduction to libuv](http://nikhilm.github.com/uvbook/)
81
+ &mdash; An overview of libuv with tutorials.
82
+ * [LXJS 2012 talk](http://www.youtube.com/watch?v=nGn60vDSxQ4)
83
+ &mdash; High-level introductory talk about libuv.
84
+ * [libuv-dox](https://github.com/thlorenz/libuv-dox)
85
+ &mdash; Documenting types and methods of libuv, mostly by reading uv.h.
86
+ * [learnuv](https://github.com/thlorenz/learnuv)
87
+ &mdash; Learn uv for fun and profit, a self guided workshop to libuv.
88
+
89
+ These resources are not handled by libuv maintainers and might be out of
90
+ date. Please verify it before opening new issues.
91
+
92
+ ## Build Instructions
93
+
94
+ For GCC there are two build methods: via autotools or via [GYP][].
95
+ GYP is a meta-build system which can generate MSVS, Makefile, and XCode
96
+ backends. It is best used for integration into other projects.
97
+
98
+ To build with autotools:
99
+
100
+ $ sh autogen.sh
101
+ $ ./configure
102
+ $ make
103
+ $ make check
104
+ $ make install
105
+
106
+ ### Windows
107
+
108
+ First, [Python][] 2.6 or 2.7 must be installed as it is required by [GYP][].
109
+ If python is not in your path, set the environment variable `PYTHON` to its
110
+ location. For example: `set PYTHON=C:\Python27\python.exe`
111
+
112
+ To build with Visual Studio, launch a git shell (e.g. Cmd or PowerShell)
113
+ and run vcbuild.bat which will checkout the GYP code into build/gyp and
114
+ generate uv.sln as well as related project files.
115
+
116
+ To have GYP generate build script for another system, checkout GYP into the
117
+ project tree manually:
118
+
119
+ $ git clone https://chromium.googlesource.com/external/gyp.git build/gyp
120
+
121
+ ### Unix
122
+
123
+ Run:
124
+
125
+ $ ./gyp_uv.py -f make
126
+ $ make -C out
127
+
128
+ Run `./gyp_uv.py -f make -Dtarget_arch=x32` to build [x32][] binaries.
129
+
130
+ ### OS X
131
+
132
+ Run:
133
+
134
+ $ ./gyp_uv.py -f xcode
135
+ $ xcodebuild -ARCHS="x86_64" -project uv.xcodeproj \
136
+ -configuration Release -target All
137
+
138
+ Using Homebrew:
139
+
140
+ $ brew install --HEAD libuv
141
+
142
+ Note to OS X users:
143
+
144
+ Make sure that you specify the architecture you wish to build for in the
145
+ "ARCHS" flag. You can specify more than one by delimiting with a space
146
+ (e.g. "x86_64 i386").
147
+
148
+ ### Android
149
+
150
+ Run:
151
+
152
+ $ source ./android-configure NDK_PATH gyp
153
+ $ make -C out
154
+
155
+ Note for UNIX users: compile your project with `-D_LARGEFILE_SOURCE` and
156
+ `-D_FILE_OFFSET_BITS=64`. GYP builds take care of that automatically.
157
+
158
+ ### Using Ninja
159
+
160
+ To use ninja for build on ninja supported platforms, run:
161
+
162
+ $ ./gyp_uv.py -f ninja
163
+ $ ninja -C out/Debug #for debug build OR
164
+ $ ninja -C out/Release
165
+
166
+
167
+ ### Running tests
168
+
169
+ Run:
170
+
171
+ $ ./gyp_uv.py -f make
172
+ $ make -C out
173
+ $ ./out/Debug/run-tests
174
+
175
+ ## Supported Platforms
176
+
177
+ Microsoft Windows operating systems since Windows XP SP2. It can be built
178
+ with either Visual Studio or MinGW. Consider using
179
+ [Visual Studio Express 2010][] or later if you do not have a full Visual
180
+ Studio license.
181
+
182
+ Linux using the GCC toolchain.
183
+
184
+ OS X using the GCC or XCode toolchain.
185
+
186
+ Solaris 121 and later using GCC toolchain.
187
+
188
+ ## Patches
189
+
190
+ See the [guidelines for contributing][].
191
+
192
+ [node.js]: http://nodejs.org/
193
+ [GYP]: http://code.google.com/p/gyp/
194
+ [Python]: https://www.python.org/downloads/
195
+ [Visual Studio Express 2010]: http://www.microsoft.com/visualstudio/eng/products/visual-studio-2010-express
196
+ [guidelines for contributing]: https://github.com/libuv/libuv/blob/master/CONTRIBUTING.md
197
+ [libuv_banner]: https://raw.githubusercontent.com/libuv/libuv/master/img/banner.png