Troubles while building OpenOCD0.8.0 on ubuntu 14.04

Open source ARM Debugger

Moderator: phalanx

Post Reply
astrodreamer
Posts: 1
Joined: Mon May 19, 2014 12:46 am

Troubles while building OpenOCD0.8.0 on ubuntu 14.04

Post by astrodreamer » Mon May 19, 2014 1:11 am

I have problem then i try to build last stable version OpenOCD on kubuntu 14.04.

Then i configure project with j-link support, system returns error with libusb 0.1 and libusb 1.x, although this libraries installed.

May be anyone solved similar problem. Output of configure and dpkg as follows:

Code: Select all

~/openocd-0.8.0$ ./configure --enable-jlink

checking whether standard drivers can be built... yes
checking for LIBUSB1... no
configure: WARNING: libusb-1.x not found, trying legacy libusb-0.1 as a fallback; consider installing libusb-1.x instead
checking for LIBUSB0... no
checking for HIDAPI... no
checking for HIDAPI... no
checking for HIDAPI... no
configure: error: libusb-1.x or libusb-0.1 is required for the Segger J-Link JTAG Programmer

Code: Select all

~/openocd-0.8.0$ dpkg -l | grep libusb
ii  libgusb2:amd64                        0.1.6-5                               amd64        GLib wrapper around libusb1
ii  libusb-0.1-4:amd64                    2:0.1.12-23.3ubuntu1                  amd64        userspace USB programming library
ii  libusb-1.0-0:amd64                    2:1.0.17-1ubuntu2                     amd64        userspace USB programming library
ii  libusb-dev                            2:0.1.12-23.3ubuntu1                  amd64        userspace USB programming library development files
ii  libusbmuxd2                           1.0.8-2ubuntu1                        amd64        USB multiplexor daemon for iPhone and iPod Touch devices - library

hsutherl
Posts: 182
Joined: Sun Jun 07, 2009 6:24 am

Re: Troubles while building OpenOCD0.8.0 on ubuntu 14.04

Post by hsutherl » Sun May 25, 2014 5:13 am

Hello astrodreamer, did you solve this yet?

I've not built OpenOCD on Ubuntu yet, but on my (ARM) Ubuntu system there is a libusb-1.0-0.dev available as well as libusb.dev. You might check whether you have something similar on the amd64 platform.

mrbird
Posts: 3
Joined: Wed May 28, 2014 5:03 pm

Re: Troubles while building OpenOCD0.8.0 on ubuntu 14.04

Post by mrbird » Fri May 30, 2014 5:13 pm

hsuterl is right.

I have debian system but requirements are same, libusb-1.0-0-dev is required. libusb-dev is available but not installed in my system, libusb-1.0-0-dev is installed. I can compile openocd 0.8 in my system.

TzashiNorpu
Posts: 1
Joined: Wed Jun 18, 2014 7:45 pm

Re: Troubles while building OpenOCD0.8.0 on ubuntu 14.04

Post by TzashiNorpu » Wed Jun 18, 2014 8:15 pm

astrodreamer wrote:I have problem then i try to build last stable version OpenOCD on kubuntu 14.04.

Then i configure project with j-link support, system returns error with libusb 0.1 and libusb 1.x, although this libraries installed.

May be anyone solved similar problem. Output of configure and dpkg as follows:

Code: Select all

~/openocd-0.8.0$ ./configure --enable-jlink

checking whether standard drivers can be built... yes
checking for LIBUSB1... no
configure: WARNING: libusb-1.x not found, trying legacy libusb-0.1 as a fallback; consider installing libusb-1.x instead
checking for LIBUSB0... no
checking for HIDAPI... no
checking for HIDAPI... no
checking for HIDAPI... no
configure: error: libusb-1.x or libusb-0.1 is required for the Segger J-Link JTAG Programmer

Code: Select all

~/openocd-0.8.0$ dpkg -l | grep libusb
ii  libgusb2:amd64                        0.1.6-5                               amd64        GLib wrapper around libusb1
ii  libusb-0.1-4:amd64                    2:0.1.12-23.3ubuntu1                  amd64        userspace USB programming library
ii  libusb-1.0-0:amd64                    2:1.0.17-1ubuntu2                     amd64        userspace USB programming library
ii  libusb-dev                            2:0.1.12-23.3ubuntu1                  amd64        userspace USB programming library development files
ii  libusbmuxd2                           1.0.8-2ubuntu1                        amd64        USB multiplexor daemon for iPhone and iPod Touch devices - library

Did you solve the problem?If not,try to install libusb-devel and libusb1-devel

wynandmurray
Posts: 1
Joined: Wed Jul 09, 2014 5:01 am

Re: Troubles while building OpenOCD0.8.0 on ubuntu 14.04

Post by wynandmurray » Wed Jul 09, 2014 5:06 am

Hi guys,

I am facing the exact same problem:

"error: libusb-1.x or libusb-0.1 is required for the Segger J-Link JTAG Programmer"
I have run "sudo apt-get install libusb-1.0.0-dev".
When I run it again I get "libusv-1.0.0-dev is already the newest version."

Could anyone please help? I have been struggling for days now :(

Thank you in advance!

Landsdorfm
Posts: 1
Joined: Tue Jul 22, 2014 4:26 am

Re: Troubles while building OpenOCD0.8.0 on ubuntu 14.04

Post by Landsdorfm » Tue Jul 22, 2014 4:36 am

Hi guys,
I had also been spending some hours to get this running,
on my system (Debian 7.4) it was required to install the make, libtool and pkg-config package like it is recommended in the README.
After that the configure has found the usblib.

hope this will help you too

linuxdev
Posts: 6
Joined: Thu Sep 05, 2013 1:13 pm

Re: Troubles while building OpenOCD0.8.0 on ubuntu 14.04

Post by linuxdev » Sat Jul 26, 2014 4:12 pm

My only Ubuntu is 32 bit embedded, so I don't know if this will help or not. 64 bit libs tend to use /usr/lib64/, while 32 bit libs tend to use /usr/lib/. My 64 bit is fedora, so I can't really look this up, but perhaps something is looking specifically in 32 or 64 bit locations. strace with grep might help.

diogenes
Posts: 1
Joined: Wed Feb 18, 2015 2:42 am

Re: Troubles while building OpenOCD0.8.0 on ubuntu 14.04

Post by diogenes » Wed Feb 18, 2015 2:50 am

This is an oldish thread and the OP has probably solved the problem by now. But Google still has it high in the search results, so for the benefit of others:

You need the dev version of libusb1, which is not installed by default. Try

Code: Select all

sudo apt-get install libusb-1.0.0-dev
./configure --enable-maintainer-mode --enable-ftdi

Post Reply