diff options
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Formula/sysbench.rb | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/Library/Formula/sysbench.rb b/Library/Formula/sysbench.rb new file mode 100644 index 000000000..8cf8c2797 --- /dev/null +++ b/Library/Formula/sysbench.rb @@ -0,0 +1,24 @@ +require 'formula' + +class Sysbench < Formula + homepage 'http://sysbench.sourceforge.net/' + url 'http://downloads.sourceforge.net/project/sysbench/sysbench/0.4.12/sysbench-0.4.12.tar.gz' + sha1 '3f346e8b29b738711546970b027bbb7359d4672a' + + depends_on 'automake' + depends_on :mysql => :recommended + depends_on :postgresql => :optional + + def install + inreplace 'configure.ac', 'AC_PROG_LIBTOOL', 'AC_PROG_RANLIB' + + system "./autogen.sh" + + args = ["--prefix=#{prefix}"] + args << "--with-mysql" if build.with? 'mysql' + args << "--with-psql" if build.with? 'postgresql' + + system "./configure", *args + system "make install" + end +end |
