diff options
| author | Jack Nagel | 2012-08-13 16:04:47 -0500 |
|---|---|---|
| committer | Jack Nagel | 2012-08-13 16:04:47 -0500 |
| commit | 08214297cbd3ec18d2929dc23838b554f8c4f38e (patch) | |
| tree | 6743b0b14087374221eb02535317a76918babae0 /Library/Formula | |
| parent | 569c34d42b50f5d050b78e66d37b2d2bed58e4d4 (diff) | |
| download | homebrew-08214297cbd3ec18d2929dc23838b554f8c4f38e.tar.bz2 | |
nginx: use options DSL
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library/Formula')
| -rw-r--r-- | Library/Formula/nginx.rb | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/Library/Formula/nginx.rb b/Library/Formula/nginx.rb index d29259b53..b7623dadc 100644 --- a/Library/Formula/nginx.rb +++ b/Library/Formula/nginx.rb @@ -12,6 +12,9 @@ class Nginx < Formula depends_on 'pcre' + option 'with-passenger', 'Compile with support for Phusion Passenger module' + option 'with-webdav', 'Compile with support for WebDAV module' + skip_clean 'logs' # Changes default port to 8080 @@ -19,13 +22,6 @@ class Nginx < Formula DATA end - def options - [ - ['--with-passenger', "Compile with support for Phusion Passenger module"], - ['--with-webdav', "Compile with support for WebDAV module"] - ] - end - def passenger_config_args passenger_root = `passenger-config --root`.chomp @@ -50,8 +46,8 @@ class Nginx < Formula "--pid-path=#{var}/run/nginx.pid", "--lock-path=#{var}/nginx/nginx.lock"] - args << passenger_config_args if ARGV.include? '--with-passenger' - args << "--with-http_dav_module" if ARGV.include? '--with-webdav' + args << passenger_config_args if build.include? 'with-passenger' + args << "--with-http_dav_module" if build.include? 'with-webdav' system "./configure", *args system "make" |
