usb 2.12.1 → 2.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (228) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/README.md +11 -1
  3. package/dist/index.js +6 -2
  4. package/dist/index.js.map +1 -1
  5. package/dist/usb/bindings.d.ts +0 -1
  6. package/dist/usb/bindings.js +1 -1
  7. package/dist/usb/bindings.js.map +1 -1
  8. package/dist/usb/capability.d.ts +0 -1
  9. package/dist/usb/capability.js.map +1 -1
  10. package/dist/usb/descriptors.d.ts +0 -1
  11. package/dist/usb/device.d.ts +0 -1
  12. package/dist/usb/device.js.map +1 -1
  13. package/dist/usb/endpoint.d.ts +0 -1
  14. package/dist/usb/endpoint.js +2 -2
  15. package/dist/usb/endpoint.js.map +1 -1
  16. package/dist/usb/index.js.map +1 -1
  17. package/dist/usb/interface.js +2 -2
  18. package/dist/usb/interface.js.map +1 -1
  19. package/dist/webusb/index.d.ts +1 -3
  20. package/dist/webusb/index.js.map +1 -1
  21. package/dist/webusb/webusb-device.d.ts +0 -1
  22. package/dist/webusb/webusb-device.js +10 -10
  23. package/dist/webusb/webusb-device.js.map +1 -1
  24. package/libusb/.codespellrc +3 -0
  25. package/libusb/.private/appveyor_build.sh +5 -1
  26. package/libusb/.private/ci-build.sh +26 -1
  27. package/libusb/.private/ci-container-build.sh +2 -5
  28. package/libusb/.private/wbs.txt +5 -8
  29. package/libusb/AUTHORS +22 -0
  30. package/libusb/ChangeLog +19 -2
  31. package/libusb/HACKING +25 -0
  32. package/libusb/INSTALL_WIN.txt +11 -10
  33. package/libusb/NEWS +2 -2
  34. package/libusb/README +3 -2
  35. package/libusb/README.git +1 -1
  36. package/libusb/Xcode/common.xcconfig +8 -1
  37. package/libusb/Xcode/config.h +0 -6
  38. package/libusb/Xcode/debug.xcconfig +4 -1
  39. package/libusb/Xcode/libusb.xcconfig +1 -1
  40. package/libusb/Xcode/libusb.xcodeproj/project.pbxproj +60 -30
  41. package/libusb/Xcode/libusb_debug.xcconfig +1 -1
  42. package/libusb/Xcode/libusb_release.xcconfig +1 -1
  43. package/libusb/Xcode/release.xcconfig +1 -1
  44. package/libusb/appveyor.yml +33 -9
  45. package/libusb/configure.ac +68 -37
  46. package/libusb/examples/dpfp.c +2 -2
  47. package/libusb/examples/fxload.c +2 -2
  48. package/libusb/examples/hotplugtest.c +28 -13
  49. package/libusb/examples/listdevs.c +1 -1
  50. package/libusb/examples/sam3u_benchmark.c +1 -1
  51. package/libusb/examples/testlibusb.c +1 -1
  52. package/libusb/examples/xusb.c +74 -19
  53. package/libusb/libusb/Makefile.am +11 -1
  54. package/libusb/libusb/core.c +364 -186
  55. package/libusb/libusb/descriptor.c +276 -16
  56. package/libusb/libusb/hotplug.c +5 -4
  57. package/libusb/libusb/io.c +72 -61
  58. package/libusb/libusb/libusb-1.0.def +14 -1
  59. package/libusb/libusb/libusb.h +245 -76
  60. package/libusb/libusb/libusbi.h +35 -13
  61. package/libusb/libusb/os/darwin_usb.c +542 -279
  62. package/libusb/libusb/os/darwin_usb.h +44 -115
  63. package/libusb/libusb/os/emscripten_webusb.cpp +870 -0
  64. package/libusb/libusb/os/events_posix.c +40 -0
  65. package/libusb/libusb/os/events_posix.h +3 -0
  66. package/libusb/libusb/os/linux_usbfs.c +27 -16
  67. package/libusb/libusb/os/netbsd_usb.c +36 -36
  68. package/libusb/libusb/os/openbsd_usb.c +34 -34
  69. package/libusb/libusb/os/sunos_usb.c +25 -15
  70. package/libusb/libusb/os/threads_posix.c +1 -5
  71. package/libusb/libusb/os/windows_common.c +13 -5
  72. package/libusb/libusb/os/windows_common.h +8 -0
  73. package/libusb/libusb/os/windows_winusb.c +366 -174
  74. package/libusb/libusb/os/windows_winusb.h +13 -9
  75. package/libusb/libusb/strerror.c +5 -5
  76. package/libusb/libusb/sync.c +24 -19
  77. package/libusb/libusb/version.h +1 -1
  78. package/libusb/libusb/version_nano.h +1 -1
  79. package/libusb/msvc/Base.props +60 -0
  80. package/libusb/msvc/Configuration.Application.props +7 -0
  81. package/libusb/msvc/Configuration.Base.props +47 -0
  82. package/libusb/msvc/Configuration.DynamicLibrary.props +21 -0
  83. package/libusb/msvc/Configuration.StaticLibrary.props +7 -0
  84. package/libusb/msvc/ProjectConfigurations.Base.props +69 -0
  85. package/libusb/msvc/build_all.ps1 +17 -0
  86. package/libusb/msvc/config.h +2 -2
  87. package/libusb/msvc/dpfp.vcxproj +33 -0
  88. package/libusb/msvc/dpfp_threaded.vcxproj +38 -0
  89. package/libusb/msvc/fxload.vcxproj +46 -0
  90. package/libusb/msvc/getopt.vcxproj +33 -0
  91. package/libusb/msvc/hotplugtest.vcxproj +32 -0
  92. package/libusb/msvc/init_context.vcxproj +35 -0
  93. package/libusb/msvc/libusb.sln +542 -0
  94. package/libusb/msvc/libusb_dll.vcxproj +61 -0
  95. package/libusb/msvc/libusb_static.vcxproj +49 -0
  96. package/libusb/msvc/listdevs.vcxproj +32 -0
  97. package/libusb/msvc/sam3u_benchmark.vcxproj +33 -0
  98. package/libusb/msvc/set_option.vcxproj +35 -0
  99. package/libusb/msvc/stress.vcxproj +35 -0
  100. package/libusb/msvc/stress_mt.vcxproj +33 -0
  101. package/libusb/msvc/testlibusb.vcxproj +32 -0
  102. package/libusb/msvc/xusb.vcxproj +38 -0
  103. package/libusb/tests/Makefile.am +25 -3
  104. package/libusb/tests/init_context.c +153 -0
  105. package/libusb/tests/macos.c +130 -0
  106. package/libusb/tests/set_option.c +253 -0
  107. package/libusb/tests/stress.c +17 -14
  108. package/libusb/tests/stress_mt.c +265 -0
  109. package/libusb/tests/testlib.c +1 -1
  110. package/libusb/tests/umockdev.c +9 -9
  111. package/libusb/tests/webusb-test-shim/index.js +12 -0
  112. package/libusb/tests/webusb-test-shim/package-lock.json +50 -0
  113. package/libusb/tests/webusb-test-shim/package.json +10 -0
  114. package/package.json +8 -8
  115. package/prebuilds/android-arm/node.napi.armv7.node +0 -0
  116. package/prebuilds/android-arm64/node.napi.armv8.node +0 -0
  117. package/prebuilds/darwin-x64+arm64/node.napi.node +0 -0
  118. package/prebuilds/linux-arm/node.napi.armv6.node +0 -0
  119. package/prebuilds/linux-arm/node.napi.armv7.node +0 -0
  120. package/prebuilds/linux-arm64/node.napi.armv8.node +0 -0
  121. package/prebuilds/linux-ia32/node.napi.node +0 -0
  122. package/prebuilds/linux-x64/node.napi.glibc.node +0 -0
  123. package/prebuilds/linux-x64/node.napi.musl.node +0 -0
  124. package/prebuilds/win32-arm64/node.napi.node +0 -0
  125. package/prebuilds/win32-ia32/node.napi.node +0 -0
  126. package/prebuilds/win32-x64/node.napi.node +0 -0
  127. package/src/device.cc +16 -6
  128. package/src/transfer.cc +1 -1
  129. package/libusb/msvc/dpfp_2013.vcxproj +0 -87
  130. package/libusb/msvc/dpfp_2013.vcxproj.filters +0 -26
  131. package/libusb/msvc/dpfp_2015.vcxproj +0 -87
  132. package/libusb/msvc/dpfp_2015.vcxproj.filters +0 -26
  133. package/libusb/msvc/dpfp_2017.vcxproj +0 -106
  134. package/libusb/msvc/dpfp_2017.vcxproj.filters +0 -26
  135. package/libusb/msvc/dpfp_2019.vcxproj +0 -106
  136. package/libusb/msvc/dpfp_2019.vcxproj.filters +0 -26
  137. package/libusb/msvc/dpfp_threaded_2013.vcxproj +0 -87
  138. package/libusb/msvc/dpfp_threaded_2013.vcxproj.filters +0 -26
  139. package/libusb/msvc/dpfp_threaded_2015.vcxproj +0 -87
  140. package/libusb/msvc/dpfp_threaded_2015.vcxproj.filters +0 -26
  141. package/libusb/msvc/dpfp_threaded_2017.vcxproj +0 -106
  142. package/libusb/msvc/dpfp_threaded_2017.vcxproj.filters +0 -26
  143. package/libusb/msvc/dpfp_threaded_2019.vcxproj +0 -106
  144. package/libusb/msvc/dpfp_threaded_2019.vcxproj.filters +0 -26
  145. package/libusb/msvc/fxload_2013.vcxproj +0 -94
  146. package/libusb/msvc/fxload_2013.vcxproj.filters +0 -35
  147. package/libusb/msvc/fxload_2015.vcxproj +0 -94
  148. package/libusb/msvc/fxload_2015.vcxproj.filters +0 -35
  149. package/libusb/msvc/fxload_2017.vcxproj +0 -113
  150. package/libusb/msvc/fxload_2017.vcxproj.filters +0 -35
  151. package/libusb/msvc/fxload_2019.vcxproj +0 -113
  152. package/libusb/msvc/fxload_2019.vcxproj.filters +0 -35
  153. package/libusb/msvc/getopt_2013.vcxproj +0 -72
  154. package/libusb/msvc/getopt_2013.vcxproj.filters +0 -26
  155. package/libusb/msvc/getopt_2015.vcxproj +0 -73
  156. package/libusb/msvc/getopt_2015.vcxproj.filters +0 -26
  157. package/libusb/msvc/getopt_2017.vcxproj +0 -92
  158. package/libusb/msvc/getopt_2017.vcxproj.filters +0 -26
  159. package/libusb/msvc/getopt_2019.vcxproj +0 -92
  160. package/libusb/msvc/getopt_2019.vcxproj.filters +0 -26
  161. package/libusb/msvc/hotplugtest_2013.vcxproj +0 -86
  162. package/libusb/msvc/hotplugtest_2013.vcxproj.filters +0 -23
  163. package/libusb/msvc/hotplugtest_2015.vcxproj +0 -86
  164. package/libusb/msvc/hotplugtest_2015.vcxproj.filters +0 -23
  165. package/libusb/msvc/hotplugtest_2017.vcxproj +0 -105
  166. package/libusb/msvc/hotplugtest_2017.vcxproj.filters +0 -23
  167. package/libusb/msvc/hotplugtest_2019.vcxproj +0 -105
  168. package/libusb/msvc/hotplugtest_2019.vcxproj.filters +0 -23
  169. package/libusb/msvc/libusb_2013.sln +0 -137
  170. package/libusb/msvc/libusb_2015.sln +0 -137
  171. package/libusb/msvc/libusb_2017.sln +0 -240
  172. package/libusb/msvc/libusb_2019.sln +0 -240
  173. package/libusb/msvc/libusb_dll_2013.vcxproj +0 -104
  174. package/libusb/msvc/libusb_dll_2013.vcxproj.filters +0 -94
  175. package/libusb/msvc/libusb_dll_2015.vcxproj +0 -105
  176. package/libusb/msvc/libusb_dll_2015.vcxproj.filters +0 -94
  177. package/libusb/msvc/libusb_dll_2017.vcxproj +0 -124
  178. package/libusb/msvc/libusb_dll_2017.vcxproj.filters +0 -94
  179. package/libusb/msvc/libusb_dll_2019.vcxproj +0 -124
  180. package/libusb/msvc/libusb_dll_2019.vcxproj.filters +0 -94
  181. package/libusb/msvc/libusb_static_2013.vcxproj +0 -94
  182. package/libusb/msvc/libusb_static_2013.vcxproj.filters +0 -80
  183. package/libusb/msvc/libusb_static_2015.vcxproj +0 -95
  184. package/libusb/msvc/libusb_static_2015.vcxproj.filters +0 -80
  185. package/libusb/msvc/libusb_static_2017.vcxproj +0 -114
  186. package/libusb/msvc/libusb_static_2017.vcxproj.filters +0 -80
  187. package/libusb/msvc/libusb_static_2019.vcxproj +0 -114
  188. package/libusb/msvc/libusb_static_2019.vcxproj.filters +0 -80
  189. package/libusb/msvc/listdevs_2013.vcxproj +0 -86
  190. package/libusb/msvc/listdevs_2013.vcxproj.filters +0 -23
  191. package/libusb/msvc/listdevs_2015.vcxproj +0 -86
  192. package/libusb/msvc/listdevs_2015.vcxproj.filters +0 -23
  193. package/libusb/msvc/listdevs_2017.vcxproj +0 -105
  194. package/libusb/msvc/listdevs_2017.vcxproj.filters +0 -23
  195. package/libusb/msvc/listdevs_2019.vcxproj +0 -105
  196. package/libusb/msvc/listdevs_2019.vcxproj.filters +0 -23
  197. package/libusb/msvc/sam3u_benchmark_2013.vcxproj +0 -87
  198. package/libusb/msvc/sam3u_benchmark_2013.vcxproj.filters +0 -26
  199. package/libusb/msvc/sam3u_benchmark_2015.vcxproj +0 -87
  200. package/libusb/msvc/sam3u_benchmark_2015.vcxproj.filters +0 -26
  201. package/libusb/msvc/sam3u_benchmark_2017.vcxproj +0 -106
  202. package/libusb/msvc/sam3u_benchmark_2017.vcxproj.filters +0 -26
  203. package/libusb/msvc/sam3u_benchmark_2019.vcxproj +0 -106
  204. package/libusb/msvc/sam3u_benchmark_2019.vcxproj.filters +0 -26
  205. package/libusb/msvc/stress_2013.vcxproj +0 -89
  206. package/libusb/msvc/stress_2013.vcxproj.filters +0 -32
  207. package/libusb/msvc/stress_2015.vcxproj +0 -89
  208. package/libusb/msvc/stress_2015.vcxproj.filters +0 -32
  209. package/libusb/msvc/stress_2017.vcxproj +0 -108
  210. package/libusb/msvc/stress_2017.vcxproj.filters +0 -32
  211. package/libusb/msvc/stress_2019.vcxproj +0 -108
  212. package/libusb/msvc/stress_2019.vcxproj.filters +0 -32
  213. package/libusb/msvc/testlibusb_2013.vcxproj +0 -86
  214. package/libusb/msvc/testlibusb_2013.vcxproj.filters +0 -23
  215. package/libusb/msvc/testlibusb_2015.vcxproj +0 -86
  216. package/libusb/msvc/testlibusb_2015.vcxproj.filters +0 -23
  217. package/libusb/msvc/testlibusb_2017.vcxproj +0 -105
  218. package/libusb/msvc/testlibusb_2017.vcxproj.filters +0 -23
  219. package/libusb/msvc/testlibusb_2019.vcxproj +0 -105
  220. package/libusb/msvc/testlibusb_2019.vcxproj.filters +0 -23
  221. package/libusb/msvc/xusb_2013.vcxproj +0 -86
  222. package/libusb/msvc/xusb_2013.vcxproj.filters +0 -23
  223. package/libusb/msvc/xusb_2015.vcxproj +0 -86
  224. package/libusb/msvc/xusb_2015.vcxproj.filters +0 -23
  225. package/libusb/msvc/xusb_2017.vcxproj +0 -105
  226. package/libusb/msvc/xusb_2017.vcxproj.filters +0 -23
  227. package/libusb/msvc/xusb_2019.vcxproj +0 -105
  228. package/libusb/msvc/xusb_2019.vcxproj.filters +0 -23
package/libusb/AUTHORS CHANGED
@@ -13,15 +13,18 @@ Copyright © 2013-2018 Chris Dickens <christopher.a.dickens@gmail.com>
13
13
  Other contributors:
14
14
  Aaron Luft
15
15
  Adam Korcz
16
+ Addison Crump
16
17
  Adrian Bunk
17
18
  Adrien Destugues
18
19
  Akshay Jaggi
19
20
  Alan Ott
20
21
  Alan Stern
21
22
  Aleksandr Mezin
23
+ Alexander Mot
22
24
  Alexander Pyhalov
23
25
  Alexander Schlarb
24
26
  Alexander Stein
27
+ Alex Feinman
25
28
  Alex Vatchenko
26
29
  Andrew Aldridge
27
30
  Andrew Fernandes
@@ -44,6 +47,7 @@ Bence Csokas
44
47
  Benjamin Berg
45
48
  Benjamin Dobell
46
49
  Bohdan Tymkiv
50
+ Brad Smith
47
51
  Brent Rector
48
52
  Bruno Harbulot
49
53
  Carl Karsten
@@ -59,7 +63,9 @@ David Moore
59
63
  Dmitry Fleytman
60
64
  Dmitry Kostjuchenko
61
65
  Dmitry Zakablukov
66
+ Dominik Boehi
62
67
  Doug Johnston
68
+ Edgar Fuß
63
69
  Evan Hunter
64
70
  Evan Miller
65
71
  Fabrice Fontaine
@@ -68,6 +74,7 @@ Felipe Balbi
68
74
  Florian Albrechtskirchinger
69
75
  Francesco Montorsi
70
76
  Francisco Facioni
77
+ Francis Hart
71
78
  Frank Li
72
79
  Frederik Carlier
73
80
  Freek Dijkstra
@@ -84,6 +91,7 @@ Ido Yariv
84
91
  Igor Anokhin
85
92
  Ihor Dutchak
86
93
  Ilya Konstantinov
94
+ Ingvar Stepanyan
87
95
  Jakub Klama
88
96
  James Hanko
89
97
  Jeffrey Nichols
@@ -98,6 +106,7 @@ Joost Muller
98
106
  Josh Gao
99
107
  Joshua Blake
100
108
  Joshua Hou
109
+ Joshua M. Clulow
101
110
  Juan Cruz Viotti
102
111
  Julian Scheel
103
112
  Justin Bischoff
@@ -112,11 +121,13 @@ Lars Wirzenius
112
121
  Lei Chen
113
122
  Léo Lam
114
123
  Liang Yunwang
124
+ Lonnie Abelbeck
115
125
  Luca Longinotti
116
126
  Luz Paz
117
127
  Mac Wang
118
128
  Marco Trevisan (Treviño)
119
129
  Marcus Meissner
130
+ Mario Kleiner
120
131
  Mark Kuo
121
132
  Markus Heidelberg
122
133
  Martin Ettl
@@ -136,20 +147,26 @@ Moritz Fischer
136
147
  Nancy Li
137
148
  Nia Alarie
138
149
  Nicholas Corgan
150
+ Niklas Gürtler
139
151
  Omri Iluz
152
+ Orhan aib Kavrakoglu
140
153
  Orin Eman
141
154
  Ozkan Sezer
155
+ Pablo Prietz
142
156
  Patrick Stewart
143
157
  Paul Cercueil
144
158
  Paul Fertser
145
159
  Paul Qureshi
146
160
  Pekka Nikander
161
+ Petr Pazourek
147
162
  Philémon Favrod
148
163
  Pino Toscano
149
164
  Rob Walker
150
165
  Romain Vimont
151
166
  Roman Kalashnikov
167
+ Rosen Penev
152
168
  Ryan Hileman
169
+ Ryan Metcalfe
153
170
  Ryan Schmidt
154
171
  Saleem Rashid
155
172
  Sameeh Jubran
@@ -158,6 +175,7 @@ Sebastian Pipping
158
175
  Sebastian von Ohr
159
176
  Sergey Serb
160
177
  Shawn Hoffman
178
+ Simon Chan
161
179
  Simon Haggett
162
180
  Simon Newton
163
181
  Slash Gordon
@@ -165,6 +183,7 @@ Stefan Agner
165
183
  Stefan Tauner
166
184
  Steinar H. Gunderson
167
185
  Stephen Groat
186
+ Sylvain Fasel
168
187
  Theo Buehler
169
188
  Thomas Röfer
170
189
  Tim Hutt
@@ -187,6 +206,7 @@ William Orr
187
206
  William Skellenger
188
207
  Xiaofan Chen
189
208
  Yegor Yefremov
209
+ Zeng Guang
190
210
  Zhiqiang Liu
191
211
  Zoltán Kovács
192
212
  Сергей Валерьевич
@@ -199,4 +219,6 @@ parafin
199
219
  RipleyTom
200
220
  Seneral
201
221
  saur0n
222
+ SomeAlphabetGuy
202
223
  winterrace
224
+ xloem
package/libusb/ChangeLog CHANGED
@@ -1,5 +1,22 @@
1
- For detailed information about the changes below, please see the git log or
2
- visit: http://log.libusb.info
1
+ For detailed information about the changes below, please see the git log
2
+ or visit: http://log.libusb.info
3
+
4
+ 2024-01-31: v1.0.27
5
+ * New libusb_init_context API to replace libusb_init
6
+ * New libusb_get_max_alt_packet_size API
7
+ * New libusb_get_platform_descriptor API (BOS)
8
+ * Allow setting log callback with libusb_set_option/libusb_init_context
9
+ * New WebAssembly + WebUSB backend using Emscripten
10
+ * Fix regression in libusb_set_interface_alt_setting
11
+ * Fix sync transfer completion race and use-after-free
12
+ * Fix hotplug exit ordering
13
+ * Linux: NO_DEVICE_DISCOVERY option set per context
14
+ * macOS: Fix missing device list cleanup locking
15
+ * macOS: Do not clear device data toggle for newer OS versions
16
+ * macOS: Fix running binaries on older OS than build host
17
+ * Windows: Allow claiming multiple associated interfaces
18
+ * Windows: Ignore non-configured devices instead of waiting
19
+ * Windows: Improved root hub detection
3
20
 
4
21
  2022-04-10: v1.0.26
5
22
  * Fix regression with transfer free's after closing device
package/libusb/HACKING ADDED
@@ -0,0 +1,25 @@
1
+ Contributing to libusb
2
+ **********************
3
+
4
+ For larger changes or API changes/extensions it may be wise to first
5
+ discuss on the mailing list or in the issue tracker before larger
6
+ coding efforts are initiated.
7
+
8
+ If you extend or change the API make sure documentation is updated.
9
+ Please run make -C doc and check for any Doxygen warnings.
10
+
11
+ Commit messages should be formatted to 72 chars width and have a
12
+ free-standing summary line. See for instance "Commit Guidelines" on
13
+ https://git-scm.com/book/en/v2/Distributed-Git-Contributing-to-a-Project
14
+ or https://cbea.ms/git-commit/ about how to make well-formed commit
15
+ messages.
16
+
17
+ Put detailed information in the commit message itself, which will end
18
+ up in the git history. On the other hand the description that you fill
19
+ in the GitHub pull request web page does not go anywhere.
20
+
21
+ For copyright reasons it is preferable to have your full name in the
22
+ commit author field. Do not update the AUTHOR file yourself, the
23
+ maintainers will update it as part of the release preparation.
24
+
25
+ Please don't touch version_nano.h in your patches or pull requests.
@@ -5,14 +5,15 @@ If you are compiling for MinGW or cygwin, please refer to the INSTALL file,
5
5
  which is automatically generated by autotools (e.g. running bootstrap.sh).
6
6
 
7
7
  If you are using Microsoft Visual Studio:
8
- - Open the relevant solution file in /msvc:
9
- libusb_2013.sln for Visual Studio 2013,
10
- libusb_2015.sln for Visual Studio 2015,
11
- libusb_2017.sln for Visual Studio 2017,
12
- libusb_2019.sln for Visual Studio 2019 or later.
8
+ - Using Visual Studio 2022, open /msvc/libusb.sln
13
9
  - If you want to debug the library, uncomment the ENABLE_DEBUG_LOGGING define
14
- in msvc\config.h
15
- - Select your configuration and compile the project
10
+ in msvc/config.h
11
+ - Select your configuration and compile the project.
12
+ - To target a specific toolset (previous version of Visual Studio), either
13
+ edit PlatformToolset in /msvc/Configuration.Base.props, or supply the value
14
+ to msbuild on the command line.
15
+ - For example, to build for VS2015 (from a different version):
16
+ msbuild -p:PlatformToolset=v140,Platform=x64,Configuration=Release libusb.sln
16
17
 
17
18
  Installing and building libusb via vcpkg
18
19
  ****************************************
@@ -32,9 +33,9 @@ or pull request (https://github.com/Microsoft/vcpkg) on the vcpkg repository.
32
33
  Destination directories
33
34
  ***********************
34
35
 
35
- The 32-bit binaries are placed in a Win32\ directory at the root of the
36
- library.
37
- The 64-bit binaries are placed in a x64\ directory.
36
+ The binaries are located at:
37
+ /build/<PlatformToolset>/<Platform>/<Configuration>/(lib|dll)/libusb-1.0.(lib|dll)
38
+ For example: /build/v143/x64/Release/dll/libusb-1.0.dll
38
39
 
39
40
  Troubleshooting
40
41
  ***************
package/libusb/NEWS CHANGED
@@ -1,2 +1,2 @@
1
- For the latest libusb news, please refer to the ChangeLog file, or visit:
2
- http://libusb.info
1
+ For the latest libusb news, please refer to the ChangeLog file, or visit:
2
+ https://libusb.info
package/libusb/README CHANGED
@@ -5,7 +5,8 @@
5
5
  [![Coverity Scan Build Status](https://scan.coverity.com/projects/2180/badge.svg)](https://scan.coverity.com/projects/libusb-libusb)
6
6
 
7
7
  libusb is a library for USB device access from Linux, macOS,
8
- Windows, OpenBSD/NetBSD, Haiku and Solaris userspace.
8
+ Windows, OpenBSD/NetBSD, Haiku, Solaris userspace, and WebAssembly
9
+ via WebUSB.
9
10
  It is written in C (Haiku backend in C++) and licensed under the GNU
10
11
  Lesser General Public License version 2.1 or, at your option, any later
11
12
  version (see [COPYING](COPYING)).
@@ -15,7 +16,7 @@ be ported to other operating systems. Please see the [PORTING](PORTING)
15
16
  file for more information.
16
17
 
17
18
  libusb homepage:
18
- http://libusb.info/
19
+ https://libusb.info/
19
20
 
20
21
  Developers will wish to consult the API documentation:
21
22
  http://api.libusb.info
package/libusb/README.git CHANGED
@@ -11,7 +11,7 @@ configure with a default set of options, and will therefore generate a Makefile,
11
11
  whereas the latter does not invoke configure at all. If using autogen.sh, note
12
12
  that you can also append options, that will be passed as is to configure.
13
13
 
14
- OS X-specific notes:
14
+ macOS-specific notes:
15
15
  -------------------
16
16
 
17
17
  Starting with Xcode 4.3, neither Xcode.app nor the Xcode 'command line tools'
@@ -1,7 +1,7 @@
1
1
  //
2
2
  // libusb Xcode configuration file
3
3
  // Copyright © 2012 Pete Batard <pete@akeo.ie>
4
- // For more information, please visit: <http://libusb.info>
4
+ // For more information, please visit: <https://libusb.info>
5
5
  //
6
6
  // This library is free software; you can redistribute it and/or
7
7
  // modify it under the terms of the GNU Lesser General Public
@@ -26,6 +26,13 @@ ALWAYS_SEARCH_USER_PATHS = NO
26
26
  // Enable weak references for Objective-C
27
27
  CLANG_ENABLE_OBJC_WEAK = YES
28
28
 
29
+ // Allocate even uninitialized global variables in the data section of the object file, rather than generating them as common blocks. This has the effect that if the same variable is declared (without 'extern') in two different compilations, you will get an error when you link them.
30
+ GCC_NO_COMMON_BLOCKS = YES
31
+
32
+ // Keep private symbols private. The first setting is -fvisibility=hidden, the second is -fvisibility-inlines-hidden.
33
+ GCC_SYMBOLS_PRIVATE_EXTERN = YES
34
+ GCC_INLINES_ARE_PRIVATE_EXTERN = YES
35
+
29
36
  // Compiler errors.
30
37
  GCC_TREAT_IMPLICIT_FUNCTION_DECLARATIONS_AS_ERRORS = YES
31
38
 
@@ -8,12 +8,6 @@
8
8
  /* Define to 1 to enable message logging. */
9
9
  #define ENABLE_LOGGING 1
10
10
 
11
- /* On 10.12 and later, use newly available clock_*() functions */
12
- #if MAC_OS_X_VERSION_MIN_REQUIRED >= 101200
13
- /* Define to 1 if you have the `clock_gettime' function. */
14
- #define HAVE_CLOCK_GETTIME 1
15
- #endif
16
-
17
11
  /* On 10.6 and later, use newly available pthread_threadid_np() function */
18
12
  #if MAC_OS_X_VERSION_MIN_REQUIRED >= 1060
19
13
  /* Define to 1 if you have the 'pthread_threadid_np' function. */
@@ -1,7 +1,7 @@
1
1
  //
2
2
  // libusb Xcode configuration file
3
3
  // Copyright © 2012 Pete Batard <pete@akeo.ie>
4
- // For more information, please visit: <http://libusb.info>
4
+ // For more information, please visit: <https://libusb.info>
5
5
  //
6
6
  // This library is free software; you can redistribute it and/or
7
7
  // modify it under the terms of the GNU Lesser General Public
@@ -27,3 +27,6 @@ GCC_OPTIMIZATION_LEVEL = 0
27
27
 
28
28
  //
29
29
  GCC_PREPROCESSOR_DEFINITIONS = $(inherited) DEBUG=1
30
+
31
+ // No need for Universal Binaries in debug.
32
+ ONLY_ACTIVE_ARCH = YES
@@ -1,7 +1,7 @@
1
1
  //
2
2
  // libusb Xcode configuration file
3
3
  // Copyright © 2012 Pete Batard <pete@akeo.ie>
4
- // For more information, please visit: <http://libusb.info>
4
+ // For more information, please visit: <https://libusb.info>
5
5
  //
6
6
  // This library is free software; you can redistribute it and/or
7
7
  // modify it under the terms of the GNU Lesser General Public
@@ -272,6 +272,36 @@
272
272
  1443EE8716417E63007E0579 /* libusb.xcconfig */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = text.xcconfig; path = libusb.xcconfig; sourceTree = SOURCE_ROOT; tabWidth = 4; usesTabs = 1; };
273
273
  1443EE8816417E63007E0579 /* release.xcconfig */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = text.xcconfig; path = release.xcconfig; sourceTree = SOURCE_ROOT; tabWidth = 4; usesTabs = 1; };
274
274
  1443EE8916417EA6007E0579 /* libusb_release.xcconfig */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = text.xcconfig; path = libusb_release.xcconfig; sourceTree = SOURCE_ROOT; tabWidth = 4; usesTabs = 1; };
275
+ 14EC13E12B3D5BA600CF9AD0 /* emscripten_webusb.cpp */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.cpp.cpp; path = emscripten_webusb.cpp; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
276
+ 14EC13E22B3D5BBE00CF9AD0 /* sunos_usb.h */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = sunos_usb.h; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
277
+ 14EC13E32B3D5BBE00CF9AD0 /* openbsd_usb.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = openbsd_usb.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
278
+ 14EC13E42B3D5BBE00CF9AD0 /* netbsd_usb.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = netbsd_usb.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
279
+ 14EC13E52B3D5BBE00CF9AD0 /* events_windows.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = events_windows.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
280
+ 14EC13E62B3D5BBE00CF9AD0 /* haiku_usb_raw.h */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = haiku_usb_raw.h; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
281
+ 14EC13E72B3D5BBE00CF9AD0 /* linux_netlink.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = linux_netlink.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
282
+ 14EC13E82B3D5BBE00CF9AD0 /* haiku_usb_backend.cpp */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.cpp.cpp; path = haiku_usb_backend.cpp; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
283
+ 14EC13E92B3D5BBE00CF9AD0 /* haiku_usb_raw.cpp */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.cpp.cpp; path = haiku_usb_raw.cpp; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
284
+ 14EC13EA2B3D5BBE00CF9AD0 /* linux_usbfs.h */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = linux_usbfs.h; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
285
+ 14EC13EB2B3D5BBE00CF9AD0 /* sunos_usb.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = sunos_usb.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
286
+ 14EC13EC2B3D5BBE00CF9AD0 /* linux_udev.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = linux_udev.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
287
+ 14EC13ED2B3D5BBE00CF9AD0 /* haiku_usb.h */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = haiku_usb.h; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
288
+ 14EC13EE2B3D5BBE00CF9AD0 /* events_windows.h */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = events_windows.h; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
289
+ 14EC13EF2B3D5BBE00CF9AD0 /* null_usb.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = null_usb.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
290
+ 14EC13F02B3D5BBE00CF9AD0 /* haiku_pollfs.cpp */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.cpp.cpp; path = haiku_pollfs.cpp; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
291
+ 14EC13F12B3D5BBE00CF9AD0 /* linux_usbfs.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = linux_usbfs.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
292
+ 14EC13F22B3D5BC800CF9AD0 /* windows_common.h */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = windows_common.h; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
293
+ 14EC13F32B3D5BC800CF9AD0 /* threads_windows.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = threads_windows.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
294
+ 14EC13F42B3D5BC800CF9AD0 /* windows_winusb.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = windows_winusb.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
295
+ 14EC13F52B3D5BC800CF9AD0 /* windows_common.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = windows_common.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
296
+ 14EC13F62B3D5BC800CF9AD0 /* windows_winusb.h */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = windows_winusb.h; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
297
+ 14EC13F72B3D5BC800CF9AD0 /* threads_windows.h */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = threads_windows.h; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
298
+ 14EC13F82B3D5BC800CF9AD0 /* windows_usbdk.h */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = windows_usbdk.h; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
299
+ 14EC13F92B3D5BC800CF9AD0 /* windows_usbdk.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = windows_usbdk.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
300
+ 1472E1592B43D66B00850BA3 /* init_context.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = init_context.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
301
+ 1472E15A2B43D68600850BA3 /* stress_mt.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = stress_mt.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
302
+ 1472E15D2B43D68600850BA3 /* macos.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = macos.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
303
+ 1472E15F2B43D68600850BA3 /* set_option.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = set_option.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
304
+ 1472E1602B43D69800850BA3 /* umockdev.c */ = {isa = PBXFileReference; indentWidth = 4; lastKnownFileType = sourcecode.c.c; path = umockdev.c; sourceTree = "<group>"; tabWidth = 4; usesTabs = 0; };
275
305
  2018D95E24E453BA001589B2 /* events_posix.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = events_posix.c; sourceTree = "<group>"; };
276
306
  2018D96024E453D0001589B2 /* events_posix.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = events_posix.h; sourceTree = "<group>"; };
277
307
  20468D67243298AE00650534 /* sam3u_benchmark */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = sam3u_benchmark; sourceTree = BUILT_PRODUCTS_DIR; };
@@ -371,9 +401,14 @@
371
401
  001B1F09236C836000F231DC /* tests */ = {
372
402
  isa = PBXGroup;
373
403
  children = (
404
+ 1472E1592B43D66B00850BA3 /* init_context.c */,
374
405
  008A23CA236C849A004854AA /* libusb_testlib.h */,
406
+ 1472E15D2B43D68600850BA3 /* macos.c */,
407
+ 1472E15F2B43D68600850BA3 /* set_option.c */,
408
+ 1472E15A2B43D68600850BA3 /* stress_mt.c */,
375
409
  008A23C6236C8445004854AA /* stress.c */,
376
410
  008A23CB236C849A004854AA /* testlib.c */,
411
+ 1472E1602B43D69800850BA3 /* umockdev.c */,
377
412
  );
378
413
  name = tests;
379
414
  path = ../tests;
@@ -433,10 +468,35 @@
433
468
  children = (
434
469
  008FBF6C1628B7E800BC5BE2 /* darwin_usb.c */,
435
470
  008FBF6D1628B7E800BC5BE2 /* darwin_usb.h */,
471
+ 14EC13E12B3D5BA600CF9AD0 /* emscripten_webusb.cpp */,
436
472
  2018D95E24E453BA001589B2 /* events_posix.c */,
437
473
  2018D96024E453D0001589B2 /* events_posix.h */,
474
+ 14EC13E52B3D5BBE00CF9AD0 /* events_windows.c */,
475
+ 14EC13EE2B3D5BBE00CF9AD0 /* events_windows.h */,
476
+ 14EC13F02B3D5BBE00CF9AD0 /* haiku_pollfs.cpp */,
477
+ 14EC13E82B3D5BBE00CF9AD0 /* haiku_usb_backend.cpp */,
478
+ 14EC13E92B3D5BBE00CF9AD0 /* haiku_usb_raw.cpp */,
479
+ 14EC13E62B3D5BBE00CF9AD0 /* haiku_usb_raw.h */,
480
+ 14EC13ED2B3D5BBE00CF9AD0 /* haiku_usb.h */,
481
+ 14EC13E72B3D5BBE00CF9AD0 /* linux_netlink.c */,
482
+ 14EC13EC2B3D5BBE00CF9AD0 /* linux_udev.c */,
483
+ 14EC13F12B3D5BBE00CF9AD0 /* linux_usbfs.c */,
484
+ 14EC13EA2B3D5BBE00CF9AD0 /* linux_usbfs.h */,
485
+ 14EC13E42B3D5BBE00CF9AD0 /* netbsd_usb.c */,
486
+ 14EC13EF2B3D5BBE00CF9AD0 /* null_usb.c */,
487
+ 14EC13E32B3D5BBE00CF9AD0 /* openbsd_usb.c */,
488
+ 14EC13EB2B3D5BBE00CF9AD0 /* sunos_usb.c */,
489
+ 14EC13E22B3D5BBE00CF9AD0 /* sunos_usb.h */,
438
490
  008FBF741628B7E800BC5BE2 /* threads_posix.c */,
439
491
  008FBF751628B7E800BC5BE2 /* threads_posix.h */,
492
+ 14EC13F32B3D5BC800CF9AD0 /* threads_windows.c */,
493
+ 14EC13F72B3D5BC800CF9AD0 /* threads_windows.h */,
494
+ 14EC13F52B3D5BC800CF9AD0 /* windows_common.c */,
495
+ 14EC13F22B3D5BC800CF9AD0 /* windows_common.h */,
496
+ 14EC13F92B3D5BC800CF9AD0 /* windows_usbdk.c */,
497
+ 14EC13F82B3D5BC800CF9AD0 /* windows_usbdk.h */,
498
+ 14EC13F42B3D5BC800CF9AD0 /* windows_winusb.c */,
499
+ 14EC13F62B3D5BC800CF9AD0 /* windows_winusb.h */,
440
500
  );
441
501
  path = os;
442
502
  sourceTree = "<group>";
@@ -1050,18 +1110,6 @@
1050
1110
  isa = XCBuildConfiguration;
1051
1111
  baseConfigurationReference = 1443EE8516417E63007E0579 /* debug.xcconfig */;
1052
1112
  buildSettings = {
1053
- CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
1054
- CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
1055
- CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
1056
- CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
1057
- CLANG_WARN_SUSPICIOUS_MOVE = YES;
1058
- CLANG_WARN_UNREACHABLE_CODE = YES;
1059
- CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
1060
- ENABLE_STRICT_OBJC_MSGSEND = YES;
1061
- ENABLE_TESTABILITY = YES;
1062
- GCC_NO_COMMON_BLOCKS = YES;
1063
- GCC_WARN_UNDECLARED_SELECTOR = YES;
1064
- ONLY_ACTIVE_ARCH = YES;
1065
1113
  };
1066
1114
  name = Debug;
1067
1115
  };
@@ -1069,16 +1117,6 @@
1069
1117
  isa = XCBuildConfiguration;
1070
1118
  baseConfigurationReference = 1443EE8816417E63007E0579 /* release.xcconfig */;
1071
1119
  buildSettings = {
1072
- CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
1073
- CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
1074
- CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
1075
- CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
1076
- CLANG_WARN_SUSPICIOUS_MOVE = YES;
1077
- CLANG_WARN_UNREACHABLE_CODE = YES;
1078
- CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
1079
- ENABLE_STRICT_OBJC_MSGSEND = YES;
1080
- GCC_NO_COMMON_BLOCKS = YES;
1081
- GCC_WARN_UNDECLARED_SELECTOR = YES;
1082
1120
  };
1083
1121
  name = Release;
1084
1122
  };
@@ -1086,10 +1124,6 @@
1086
1124
  isa = XCBuildConfiguration;
1087
1125
  baseConfigurationReference = 1443EE8616417E63007E0579 /* libusb_debug.xcconfig */;
1088
1126
  buildSettings = {
1089
- OTHER_CFLAGS = (
1090
- "-fvisibility=hidden",
1091
- "-pthread",
1092
- );
1093
1127
  };
1094
1128
  name = Debug;
1095
1129
  };
@@ -1097,10 +1131,6 @@
1097
1131
  isa = XCBuildConfiguration;
1098
1132
  baseConfigurationReference = 1443EE8916417EA6007E0579 /* libusb_release.xcconfig */;
1099
1133
  buildSettings = {
1100
- OTHER_CFLAGS = (
1101
- "-fvisibility=hidden",
1102
- "-pthread",
1103
- );
1104
1134
  };
1105
1135
  name = Release;
1106
1136
  };
@@ -1,7 +1,7 @@
1
1
  //
2
2
  // libusb Xcode configuration file
3
3
  // Copyright © 2012 Pete Batard <pete@akeo.ie>
4
- // For more information, please visit: <http://libusb.info>
4
+ // For more information, please visit: <https://libusb.info>
5
5
  //
6
6
  // This library is free software; you can redistribute it and/or
7
7
  // modify it under the terms of the GNU Lesser General Public
@@ -1,7 +1,7 @@
1
1
  //
2
2
  // libusb Xcode configuration file
3
3
  // Copyright © 2012 Pete Batard <pete@akeo.ie>
4
- // For more information, please visit: <http://libusb.info>
4
+ // For more information, please visit: <https://libusb.info>
5
5
  //
6
6
  // This library is free software; you can redistribute it and/or
7
7
  // modify it under the terms of the GNU Lesser General Public
@@ -1,7 +1,7 @@
1
1
  //
2
2
  // libusb Xcode configuration file
3
3
  // Copyright © 2012 Pete Batard <pete@akeo.ie>
4
- // For more information, please visit: <http://libusb.info>
4
+ // For more information, please visit: <https://libusb.info>
5
5
  //
6
6
  // This library is free software; you can redistribute it and/or
7
7
  // modify it under the terms of the GNU Lesser General Public
@@ -4,12 +4,15 @@ image:
4
4
  - Visual Studio 2015
5
5
  - Visual Studio 2017
6
6
  - Visual Studio 2019
7
+ - Visual Studio 2022
7
8
  platform:
8
9
  - Win32
9
10
  - x64
10
11
  configuration:
11
12
  - Debug
12
13
  - Release
14
+ environment:
15
+ toolset: UNK
13
16
  clone_depth: 1
14
17
  build:
15
18
  parallel: true
@@ -18,16 +21,20 @@ for:
18
21
  matrix:
19
22
  only:
20
23
  - image: Visual Studio 2013
24
+ environment:
25
+ toolset: v120
21
26
  build:
22
- project: msvc\libusb_2013.sln
27
+ project: msvc\libusb.sln
23
28
 
24
29
  -
25
30
  matrix:
26
31
  only:
27
32
  - image: Visual Studio 2015
28
33
  configuration: Debug
34
+ environment:
35
+ toolset: v140
29
36
  build:
30
- project: msvc\libusb_2015.sln
37
+ project: msvc\libusb.sln
31
38
 
32
39
  -
33
40
  matrix:
@@ -35,15 +42,17 @@ for:
35
42
  - image: Visual Studio 2015
36
43
  platform: Win32
37
44
  configuration: Release
45
+ environment:
46
+ toolset: v140
38
47
  install:
39
48
  - cmd: xcopy /S /I "%APPVEYOR_BUILD_FOLDER%" C:\msys64\home\appveyor\libusb
40
49
  - cmd: xcopy /S /I "%APPVEYOR_BUILD_FOLDER%" C:\cygwin\home\appveyor\libusb
41
50
  build_script:
42
- - cmd: msbuild "%APPVEYOR_BUILD_FOLDER%\msvc\libusb_2015.sln" /m /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
51
+ - cmd: msbuild "%APPVEYOR_BUILD_FOLDER%\msvc\libusb.sln" /m /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
43
52
  - cmd: C:\msys64\usr\bin\bash -l "%APPVEYOR_BUILD_FOLDER%\.private\appveyor_build.sh" MinGW
44
53
  - cmd: C:\cygwin\bin\bash -l "%APPVEYOR_BUILD_FOLDER%\.private\appveyor_build.sh" cygwin
45
54
  after_build:
46
- - cmd: 7z a "libusb-build_%APPVEYOR_BUILD_WORKER_IMAGE%_%PLATFORM%_%CONFIGURATION%.7z" tag_* README-build.txt %PLATFORM%\%CONFIGURATION%\dll\*.* %PLATFORM%\%CONFIGURATION%\lib\*.* %PLATFORM%\%CONFIGURATION%\examples\*.exe %PLATFORM%\%CONFIGURATION%\tests\*.exe C:\msys64\home\appveyor\libusb-MinGW-Win32 C:\cygwin\home\appveyor\libusb-cygwin-Win32
55
+ - cmd: 7z a "libusb-build_%APPVEYOR_BUILD_WORKER_IMAGE%_%PLATFORM%_%CONFIGURATION%.7z" tag_* README-build.txt build\%TOOLSET%\%PLATFORM%\%CONFIGURATION%\dll build\%TOOLSET%\%PLATFORM%\%CONFIGURATION%\lib build\%TOOLSET%\%PLATFORM%\%CONFIGURATION%\*.exe C:\msys64\home\appveyor\libusb-MinGW-Win32 C:\cygwin\home\appveyor\libusb-cygwin-Win32
47
56
 
48
57
  -
49
58
  matrix:
@@ -51,34 +60,49 @@ for:
51
60
  - image: Visual Studio 2015
52
61
  platform: x64
53
62
  configuration: Release
63
+ environment:
64
+ toolset: v140
54
65
  install:
55
66
  - cmd: xcopy /S /I "%APPVEYOR_BUILD_FOLDER%" C:\msys64\home\appveyor\libusb
56
67
  - cmd: xcopy /S /I "%APPVEYOR_BUILD_FOLDER%" C:\cygwin64\home\appveyor\libusb
57
68
  build_script:
58
- - cmd: msbuild "%APPVEYOR_BUILD_FOLDER%\msvc\libusb_2015.sln" /m /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
69
+ - cmd: msbuild "%APPVEYOR_BUILD_FOLDER%\msvc\libusb.sln" /m /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
59
70
  - cmd: C:\msys64\usr\bin\bash -l "%APPVEYOR_BUILD_FOLDER%\.private\appveyor_build.sh" MinGW
60
71
  - cmd: C:\cygwin64\bin\bash -l "%APPVEYOR_BUILD_FOLDER%\.private\appveyor_build.sh" cygwin
61
72
  after_build:
62
- - cmd: 7z a "libusb-build_%APPVEYOR_BUILD_WORKER_IMAGE%_%PLATFORM%_%CONFIGURATION%.7z" tag_* README-build.txt %PLATFORM%\%CONFIGURATION%\dll\*.* %PLATFORM%\%CONFIGURATION%\lib\*.* %PLATFORM%\%CONFIGURATION%\examples\*.exe %PLATFORM%\%CONFIGURATION%\tests\*.exe C:\msys64\home\appveyor\libusb-MinGW-x64 C:\cygwin64\home\appveyor\libusb-cygwin-x64
73
+ - cmd: 7z a "libusb-build_%APPVEYOR_BUILD_WORKER_IMAGE%_%PLATFORM%_%CONFIGURATION%.7z" tag_* README-build.txt build\%TOOLSET%\%PLATFORM%\%CONFIGURATION%\dll build\%TOOLSET%\%PLATFORM%\%CONFIGURATION%\lib build\%TOOLSET%\%PLATFORM%\%CONFIGURATION%\*.exe C:\msys64\home\appveyor\libusb-MinGW-x64 C:\cygwin64\home\appveyor\libusb-cygwin-x64
63
74
 
64
75
  -
65
76
  matrix:
66
77
  only:
67
78
  - image: Visual Studio 2017
79
+ environment:
80
+ toolset: v141
68
81
  build:
69
- project: msvc\libusb_2017.sln
82
+ project: msvc\libusb.sln
70
83
 
71
84
  -
72
85
  matrix:
73
86
  only:
74
87
  - image: Visual Studio 2019
88
+ environment:
89
+ toolset: v142
75
90
  build:
76
- project: msvc\libusb_2019.sln
91
+ project: msvc\libusb.sln
92
+
93
+ -
94
+ matrix:
95
+ only:
96
+ - image: Visual Studio 2022
97
+ environment:
98
+ toolset: v143
99
+ build:
100
+ project: msvc\libusb.sln
77
101
 
78
102
  after_build:
79
103
  - cmd: ECHO This was built by %APPVEYOR_BUILD_WORKER_IMAGE% from %APPVEYOR_REPO_NAME% commit %APPVEYOR_REPO_COMMIT% > README-build.txt
80
104
  - cmd: ECHO > tag_%APPVEYOR_REPO_TAG_NAME%_commit_%APPVEYOR_REPO_COMMIT%
81
- - cmd: 7z a "libusb-build_%APPVEYOR_BUILD_WORKER_IMAGE%_%PLATFORM%_%CONFIGURATION%.7z" tag_* README-build.txt %PLATFORM%\%CONFIGURATION%\dll\*.* %PLATFORM%\%CONFIGURATION%\lib\*.* %PLATFORM%\%CONFIGURATION%\examples\*.exe %PLATFORM%\%CONFIGURATION%\tests\*.exe
105
+ - cmd: 7z a "libusb-build_%APPVEYOR_BUILD_WORKER_IMAGE%_%PLATFORM%_%CONFIGURATION%.7z" tag_* README-build.txt build\%TOOLSET%\%PLATFORM%\%CONFIGURATION%\dll build\%TOOLSET%\%PLATFORM%\%CONFIGURATION%\lib build\%TOOLSET%\%PLATFORM%\%CONFIGURATION%\*.exe
82
106
 
83
107
  artifacts:
84
108
  - path: "libusb-build_%APPVEYOR_BUILD_WORKER_IMAGE%_%PLATFORM%_%CONFIGURATION%.7z"