dfb93058fb
Also get rid of the patch that no longer applies cleanly. It used to do two things. 1) Remove the -gstabs compiler argument because it wasn't supported on clang. This has been changed upstream to first check whether the argument is supported or not. 2) Remove the ccache wrapper. There's an environment variable to control this behaviour, so use this instead of patching. Closes Homebrew/homebrew#19727. Signed-off-by: Adam Vandenberg <flangy@gmail.com>
51 lines
1.4 KiB
Ruby
51 lines
1.4 KiB
Ruby
require 'formula'
|
|
|
|
class OpenOcd < Formula
|
|
homepage 'http://sourceforge.net/projects/openocd/'
|
|
url 'http://downloads.sourceforge.net/project/openocd/openocd/0.7.0/openocd-0.7.0.tar.bz2'
|
|
sha1 '40fa518af4fae273f24478249fc03aa6fcce9176'
|
|
|
|
option 'enable-ft2232_libftdi', 'Enable building support for FT2232 based devices with libftdi driver'
|
|
option 'enable-ft2232_ftd2xx', 'Enable building support for FT2232 based devices with FTD2XX driver'
|
|
|
|
depends_on 'libusb-compat'
|
|
depends_on 'libftdi' if build.include? 'enable-ft2232_libftdi'
|
|
|
|
def install
|
|
# default options that don't imply additional dependencies
|
|
args = %W[
|
|
--enable-ftdi
|
|
--enable-arm-jtag-ew
|
|
--enable-jlink
|
|
--enable-rlink
|
|
--enable-stlink
|
|
--enable-ulink
|
|
--enable-usbprog
|
|
--enable-vsllink
|
|
--enable-ep93xx
|
|
--enable-at91rm9200
|
|
--enable-ecosboard
|
|
--enable-opendous
|
|
--enable-osbdm
|
|
--enable-buspirate
|
|
]
|
|
|
|
if build.include? "enable-ft2232_libftdi"
|
|
args << "--enable-ft2232_libftdi"
|
|
args << "--enable-presto_libftdi"
|
|
args << "--enable-usb_blaster_libftdi"
|
|
end
|
|
|
|
if build.include? "enable-ft2232_ftd2xx"
|
|
args << "--enable-ft2232_ftd2xx"
|
|
args << "--enable-presto_ftd2xx"
|
|
end
|
|
|
|
ENV['CCACHE'] = 'none'
|
|
|
|
system "./configure", "--disable-dependency-tracking",
|
|
"--prefix=#{prefix}",
|
|
*args
|
|
system "make install"
|
|
end
|
|
end
|