Commit a409dbb
macOS: Fix for libusb_get_port_numbers on macOS 26+
macOS 26 has changed port number property name:
```
% diff -u
/Library/Developer/CommandLineTools/SDKs/MacOSX15.sdk/System/Library/
Frameworks/IOKit.framework/Headers/usb/IOUSBHostFamilyDefinitions.h
/Library/Developer/CommandLineTools/SDKs/MacOSX26.sdk/System/Library/
Frameworks/IOKit.framework/Headers/usb/IOUSBHostFamilyDefinitions.h
...
-#define kUSBHostPortPropertyPortNumber "port"
+#define kUSBHostPortPropertyPortNumber "usb-port-number"
...
```
Unfortunately, we cannot just use constant `kUSBHostPortPropertyPortNumber`
in libusb code because it would mean that the same binary that works on
macOS 15 will not work on macOS 26.
Solution is to use appropriate string for port number property depending
on running OS version.
Closes libusb#1700
References libusb#16611 parent c9f02b2 commit a409dbb
2 files changed
+10
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1309 | 1309 | | |
1310 | 1310 | | |
1311 | 1311 | | |
1312 | | - | |
| 1312 | + | |
| 1313 | + | |
| 1314 | + | |
| 1315 | + | |
| 1316 | + | |
| 1317 | + | |
| 1318 | + | |
| 1319 | + | |
| 1320 | + | |
1313 | 1321 | | |
1314 | 1322 | | |
1315 | 1323 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
0 commit comments