libemu: use new dsl
This commit is contained in:
parent
1a9f5bd8ed
commit
37bfac48f9
1 changed files with 8 additions and 13 deletions
|
@ -1,19 +1,12 @@
|
|||
require 'formula'
|
||||
|
||||
def use_python?
|
||||
ARGV.include? '--enable-python-bindings'
|
||||
end
|
||||
|
||||
class Libemu < Formula
|
||||
head 'http://git.carnivore.it/libemu.git'
|
||||
homepage 'http://libemu.carnivore.it/'
|
||||
|
||||
option "enable-python-bindings", "Compile bindings for Python"
|
||||
|
||||
depends_on 'pkg-config' => :build
|
||||
|
||||
def options
|
||||
[["--enable-python-bindings", "Compile bindings for Python"]]
|
||||
end
|
||||
|
||||
depends_on :automake
|
||||
depends_on :libtool
|
||||
|
||||
|
@ -22,10 +15,12 @@ class Libemu < Formula
|
|||
# Need to fix the static location of pkgconfigpath
|
||||
s.gsub! '/usr/lib/pkgconfig/', "#{lib}/pkgconfig/"
|
||||
end
|
||||
args = ["--disable-debug",
|
||||
"--disable-dependency-tracking",
|
||||
"--prefix=#{prefix}"]
|
||||
args << "--enable-python-bindings" if use_python?
|
||||
args = %W[
|
||||
--disable-debug
|
||||
--disable-dependency-tracking
|
||||
--prefix=#{prefix}
|
||||
]
|
||||
args << "--enable-python-bindings" if build.include? 'enable-python-bindings'
|
||||
|
||||
system "autoreconf -v -i"
|
||||
system "./configure", *args
|
||||
|
|
Loading…
Reference in a new issue