Skip to content
This repository has been archived by the owner on Apr 7, 2023. It is now read-only.

feat(*) add support for openresty-patches #71

Merged
merged 1 commit into from
May 22, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 14 additions & 2 deletions Formula/openresty.rb
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
class Openresty < Formula
homepage "https://openresty.org/"
version = "1.13.6.1"
sha_sum = "d1246e6cfa81098eea56fb88693e980d3e6b8752afae686fab271519b81d696b"

stable do
url "https://openresty.org/download/openresty-1.13.6.1.tar.gz"
sha256 "d1246e6cfa81098eea56fb88693e980d3e6b8752afae686fab271519b81d696b"
url "https://openresty.org/download/openresty-#{version}.tar.gz"
sha256 sha_sum

resource "openresty-patches" do
url "https://github.com/Kong/openresty-patches.git", :using => :git, :shallow => false
end
end

depends_on "pcre"
Expand All @@ -12,6 +18,12 @@ class Openresty < Formula
option "with-debug", "Compile with support for debug logging but without proper gdb debugging symbols"

def install
resource("openresty-patches").stage do
Dir["#{pwd}/patches/#{version}/*.patch"].each do |f|
system "cd", buildpath/"bundle", "&&", "patch", "-p1", "<", f
end
end

args = [
"--prefix=#{prefix}",
"--with-ipv6",
Expand Down