Hi, I have same issue after some updates,
with those commands I’ve got this:
iMac-de-Jesus-2:old-StepFader mkII jesus$ file ~/.platformio/packages/tool-openocd/bin/openocd
/Users/jesus/.platformio/packages/tool-openocd/bin/openocd: Mach-O 64-bit executable x86_64
iMac-de-Jesus-2:old-StepFader mkII jesus$ otool -L ~/.platformio/packages/tool-openocd/bin/openocd
/Users/jesus/.platformio/packages/tool-openocd/bin/openocd:
@loader_path/../libexec/libftdi1.2.dylib (compatibility version 2.0.0, current version 2.5.0)
@loader_path/../libexec/libhidapi.0.dylib (compatibility version 1.0.0, current version 1.0.0)
@loader_path/../libexec/libusb-1.0.0.dylib (compatibility version 4.0.0, current version 4.0.0)
/usr/lib/libobjc.A.dylib (compatibility version 1.0.0, current version 228.0.0)
/System/Library/Frameworks/AppKit.framework/Versions/C/AppKit (compatibility version 45.0.0, current version 1671.10.106)
/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation (compatibility version 150.0.0, current version 1560.12.0)
/System/Library/Frameworks/IOKit.framework/Versions/A/IOKit (compatibility version 1.0.0, current version 275.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1252.200.5)
@loader_path/../libexec/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)
iMac-de-Jesus-2:old-StepFader mkII jesus$ otool -L ~/.platformio/packages/tool-openocd/libexec/libusb-1.0.0.dylib
/Users/jesus/.platformio/packages/tool-openocd/libexec/libusb-1.0.0.dylib:
/usr/local/opt/libusb/lib/libusb-1.0.0.dylib (compatibility version 4.0.0, current version 4.0.0)
/usr/lib/libobjc.A.dylib (compatibility version 1.0.0, current version 228.0.0)
/System/Library/Frameworks/IOKit.framework/Versions/A/IOKit (compatibility version 1.0.0, current version 275.0.0)
/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation (compatibility version 150.0.0, current version 1349.8.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1238.60.2)
I have no idea what’s going on, but looking at this I would say that the file has the right version:
@loader_path/…/libexec/libusb-1.0.0.dylib (compatibility version 4.0.0, current version 4.0.0)
and this is what I get when trying to upload:
Processing blackpill_f401cc (platform: ststm32; board: blackpill_f401cc; framework: arduino)
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/ststm32/blackpill_f401cc.html
PLATFORM: ST STM32 (15.1.0) > WeAct Studio BlackPill V2.0 (STM32F401CC)
HARDWARE: STM32F401CCU6 84MHz, 64KB RAM, 256KB Flash
DEBUG: Current (blackmagic) External (blackmagic, cmsis-dap, jlink, stlink)
PACKAGES:
- framework-arduinoststm32 4.20100.211028 (2.1.0)
- framework-cmsis 2.50700.210515 (5.7.0)
- tool-dfuutil 1.9.200310
- tool-openocd 2.1100.211028 (11.0)
- tool-stm32duino 1.0.1
- toolchain-gccarmnoneeabi 1.90201.191206 (9.2.1)
LDF: Library Dependency Finder -> https://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 11 compatible libraries
Scanning dependencies...
No dependencies
Building in release mode
Checking size .pio/build/blackpill_f401cc/firmware.elf
Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM: [ ] 1.3% (used 852 bytes from 65536 bytes)
Flash: [ ] 4.5% (used 11796 bytes from 262144 bytes)
Configuring upload protocol...
AVAILABLE: blackmagic, cmsis-dap, dfu, jlink, serial, stlink
CURRENT: upload_protocol = stlink
Uploading .pio/build/blackpill_f401cc/firmware.elf
dyld: Library not loaded: @loader_path/../libexec/libusb-1.0.0.dylib
Referenced from: /Users/jesus/.platformio/packages/tool-openocd/bin/openocd
Reason: Incompatible library version: openocd requires version 4.0.0 or later, but libusb-1.0.0.dylib provides version 3.0.0
*** [upload] Error -6
any help would be much appreciated, thanks in advance