aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorNicolas Cavigneaux2013-01-02 13:58:18 +0100
committerAdam Vandenberg2013-01-04 14:46:18 -0800
commit41efc09628eb770a4a842f4bd869592770412ca1 (patch)
treefa4e2daf69d13c0105c29ba4cad5958752c8f9b3 /Library
parentbae57839c48eeb0832c45e58f2cdd9d406bf0f45 (diff)
downloadhomebrew-41efc09628eb770a4a842f4bd869592770412ca1.tar.bz2
sphinx: fix --mysql when PgSQL and MySQL are both installed
"brew install sphinx --mysql" now really add the "--with-mysql" to the configure options even if PG is installed. Closes #16840. Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library')
-rw-r--r--Library/Formula/sphinx.rb7
1 files changed, 6 insertions, 1 deletions
diff --git a/Library/Formula/sphinx.rb b/Library/Formula/sphinx.rb
index 843d65959..fb9178ba1 100644
--- a/Library/Formula/sphinx.rb
+++ b/Library/Formula/sphinx.rb
@@ -42,9 +42,14 @@ class Sphinx < Formula
args << "--with-libstemmer"
# configure script won't auto-select PostgreSQL
+ if build.include?('mysql') || which('mysql_config')
+ args << "--with-mysql"
+ else
+ args << "--without-mysql"
+ end
+
args << "--with-pgsql" if build.include?('pgsql') || which('pg_config')
args << "--enable-id64" if build.include?('id64')
- args << "--without-mysql" unless build.include?('mysql') || which('mysql_config')
system "./configure", *args
system "make install"