Compile on os x error #130

Closed
DiskoGoth opened this Issue Feb 24, 2013 · 2 comments

Projects

None yet

3 participants

@DiskoGoth

Undefined symbols for architecture x86_64:
"_libusb_alloc_transfer", referenced from:
_stlink_open_usb in libstlink.a(libstlink_a-stlink-usb.o)
"_libusb_bulk_transfer", referenced from:
_get_usb_mass_storage_status in libstlink.a(libstlink_a-stlink-sg.o)
_send_usb_mass_storage_command in libstlink.a(libstlink_a-stlink-sg.o)
_get_sense in libstlink.a(libstlink_a-stlink-sg.o)
_stlink_q in libstlink.a(libstlink_a-stlink-sg.o)
_send_usb_data_only in libstlink.a(libstlink_a-stlink-sg.o)
"_libusb_claim_interface", referenced from:
_stlink_open_usb in libstlink.a(libstlink_a-stlink-usb.o)
_stlink_v1_open_inner in libstlink.a(libstlink_a-stlink-sg.o)
"_libusb_clear_halt", referenced from:
_get_usb_mass_storage_status in libstlink.a(libstlink_a-stlink-sg.o)
_send_usb_mass_storage_command in libstlink.a(libstlink_a-stlink-sg.o)
_get_sense in libstlink.a(libstlink_a-stlink-sg.o)
_stlink_q in libstlink.a(libstlink_a-stlink-sg.o)
_send_usb_data_only in libstlink.a(libstlink_a-stlink-sg.o)
"_libusb_close", referenced from:
__stlink_usb_close in libstlink.a(libstlink_a-stlink-usb.o)
__stlink_sg_close in libstlink.a(libstlink_a-stlink-sg.o)
_stlink_v1_open_inner in libstlink.a(libstlink_a-stlink-sg.o)
"_libusb_detach_kernel_driver", referenced from:
_stlink_open_usb in libstlink.a(libstlink_a-stlink-usb.o)
_stlink_v1_open_inner in libstlink.a(libstlink_a-stlink-sg.o)
"_libusb_exit", referenced from:
__stlink_usb_close in libstlink.a(libstlink_a-stlink-usb.o)
_stlink_open_usb in libstlink.a(libstlink_a-stlink-usb.o)
__stlink_sg_close in libstlink.a(libstlink_a-stlink-sg.o)
_stlink_v1_open_inner in libstlink.a(libstlink_a-stlink-sg.o)
"_libusb_free_transfer", referenced from:
__stlink_usb_close in libstlink.a(libstlink_a-stlink-usb.o)
"_libusb_get_configuration", referenced from:
_stlink_open_usb in libstlink.a(libstlink_a-stlink-usb.o)
_stlink_v1_open_inner in libstlink.a(libstlink_a-stlink-sg.o)
"_libusb_handle_events_timeout", referenced from:
_submit_wait in libstlink.a(libstlink_a-stlink-usb.o)
"_libusb_init", referenced from:
_stlink_open_usb in libstlink.a(libstlink_a-stlink-usb.o)
_stlink_v1_open_inner in libstlink.a(libstlink_a-stlink-sg.o)
"_libusb_kernel_driver_active", referenced from:
_stlink_open_usb in libstlink.a(libstlink_a-stlink-usb.o)
_stlink_v1_open_inner in libstlink.a(libstlink_a-stlink-sg.o)
"_libusb_open_device_with_vid_pid", referenced from:
_stlink_open_usb in libstlink.a(libstlink_a-stlink-usb.o)
_stlink_v1_open_inner in libstlink.a(libstlink_a-stlink-sg.o)
"_libusb_set_configuration", referenced from:
_stlink_open_usb in libstlink.a(libstlink_a-stlink-usb.o)
_stlink_v1_open_inner in libstlink.a(libstlink_a-stlink-sg.o)
"_libusb_set_debug", referenced from:
_stlink_v1_open_inner in libstlink.a(libstlink_a-stlink-sg.o)
"_libusb_submit_transfer", referenced from:
_submit_wait in libstlink.a(libstlink_a-stlink-usb.o)
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make: *** [st-flash] Error 1

@jsarenik

Is this still valid? Looks like your libusb is compiled for 32-bit and you are trying to link 64-bit stlink.

@xor-gate
Collaborator
xor-gate commented May 3, 2016

Please use latest master with cmake/libusb from homebrew on OSX. Should work as expected. Reopen when problem is still remaining.

@xor-gate xor-gate closed this May 3, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment