Hello, I'm attempting to use emerge to build openocd-0.7.0 so that it is configured for the ftdi interface. Specifying ftdi as the use flag, produces an executable that supports fd2232, which is an older, less reliable interface. Build logs are attached. Thank you. Reproducible: Always Steps to Reproduce: 1. echo dev-embedded/openocd ftdi -ftd2xx > /etc/portage/package.use/openocd 2. emerge openocd 3. openocd -c "interface list" Actual Results: Running command: openocd -c "interface list" produces: Open On-Chip Debugger 0.7.0 (2013-06-07-16:57) Licensed under GNU GPL v2 For bug reports, read http://openocd.sourceforge.net/doc/doxygen/bugs.html Error: The specified debug interface was not found (list) The following debug interfaces are available: 1: ft2232 2: amt_jtagaccel 3: gw16012 4: usbprog 5: jlink 6: vsllink 7: rlink 8: ulink 9: arm-jtag-ew 10: buspirate 11: hla 12: osbdm 13: opendous in procedure 'interface' Expected Results: With the manually configured and built executable, running command: openocd -c "interface list" produces: Open On-Chip Debugger 0.7.0 (2013-06-04-23:47) Licensed under GNU GPL v2 For bug reports, read http://openocd.sourceforge.net/doc/doxygen/bugs.html Error: The specified debug interface was not found (list) The following debug interfaces are available: 1: ftdi in procedure 'interface' Hello, I'm attempting to use emerge to build openocd-0.7.0 so that it is configured for the ftdi interface. In /etc/portage/package.use/openocd, I have: dev-embedded/openocd ftdi -ftd2xx After running "emerge openocd", I run command openocd -c "interface list" The output is: root@osage bugzilla.d # openocd -c "interface list" Open On-Chip Debugger 0.7.0 (2013-06-07-16:57) Licensed under GNU GPL v2 For bug reports, read http://openocd.sourceforge.net/doc/doxygen/bugs.html Error: The specified debug interface was not found (list) The following debug interfaces are available: 1: ft2232 2: amt_jtagaccel 3: gw16012 4: usbprog 5: jlink 6: vsllink 7: rlink 8: ulink 9: arm-jtag-ew 10: buspirate 11: hla 12: osbdm 13: opendous in procedure 'interface' Alternatively, I can manually unpack the tarball, run "./configure --enable-ftdi" and get what I want. Building this way, the output of the above command is: Open On-Chip Debugger 0.7.0 (2013-06-04-23:47) Licensed under GNU GPL v2 For bug reports, read http://openocd.sourceforge.net/doc/doxygen/bugs.html Error: The specified debug interface was not found (list) The following debug interfaces are available: 1: ftdi in procedure 'interface'
Created attachment 350358 [details] output of emerge --info
Created attachment 350360 [details] output of emerge -pqv
Created attachment 350362 [details] build log
It is not clear to me what exactly do you ask in this bug
The ebuild has an "ftdi" use flag. When specified, the executable that is built should support the ftdi interface. Command 'openocd -c "interface list"' lists the interfaces supported by openocd. When use flag 'ftdi' is specified, 'ftdi' should appear in the interface list, but it does not. In order to use the ftdi interface (which is an upgrade/fix of the ft2232 interface), specifying "ftdi" as a use flag should result in an executable that supports ftdi.
alright let me have a look.
I stumbled across this problem when trying to build the live git ebuild of OpenOCD. The fix; ./configure needs to be ran with --enable-ftdi. This can be achieved by simply adding it to the econf line: stuartl@vk4msl-mb /tmp $ diff -u openocd-9999.ebuild.old openocd-9999.ebuild --- openocd-9999.ebuild.old 2013-05-25 08:31:07.000000000 +1000 +++ openocd-9999.ebuild 2013-06-11 22:03:27.929000046 +1000 @@ -99,6 +99,7 @@ econf \ $(use_enable dummy) \ $(use_enable ftdi ft2232_libftdi) \ + $(use_enable ftdi ftdi) \ $(use_enable ftd2xx ft2232_ftd2xx) \ $(use_enable minidriver minidriver-dummy) \ $(use_enable parport) \ Then you get both ft2232 and ftdi drivers. There is the suggestion on the OpenOCD list that perhaps the former should be a separate flag, but the above better preserves the existing behaviour of the ebuild. (And yes, looking at that, I see the 'ftdi ftdi' is redundant; since 'use_enable ftdi' is equivalent.) http://www.mail-archive.com/openocd-devel@lists.sourceforge.net/msg04103.html suggests the old ft2232 driver could be removed, or at least relegated to legacy status.
(In reply to Stuart Longland from comment #7) > I stumbled across this problem when trying to build the live git ebuild of > OpenOCD. > > The fix; ./configure needs to be ran with --enable-ftdi. This can be > achieved by simply adding it to the econf line: > > stuartl@vk4msl-mb /tmp $ diff -u openocd-9999.ebuild.old openocd-9999.ebuild > --- openocd-9999.ebuild.old 2013-05-25 08:31:07.000000000 +1000 > +++ openocd-9999.ebuild 2013-06-11 22:03:27.929000046 +1000 > @@ -99,6 +99,7 @@ > econf \ > $(use_enable dummy) \ > $(use_enable ftdi ft2232_libftdi) \ > + $(use_enable ftdi ftdi) \ This can be replaced with $(use_enable ftdi) committed. Thanks +*openocd-0.7.0-r1 (11 Jun 2013) + + 11 Jun 2013; Markos Chandras <hwoarang@gentoo.org> +openocd-0.7.0-r1.ebuild, + -openocd-0.7.0.ebuild, openocd-0.6.1.ebuild, openocd-9999.ebuild: + Enable the new ftdi interface when using the ftdi useflag. Bug #472622 thanks + to Stuart Longland + http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/dev-embedded/openocd/openocd-0.7.0-r1.ebuild?revision=1.1&view=markup http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/dev-embedded/openocd/openocd-9999.ebuild?r1=1.30&r2=1.31