Skip to content

Commit

Permalink
Universal prefix selection #407
Browse files Browse the repository at this point in the history
  • Loading branch information
denji authored Feb 22, 2023
1 parent eb3a903 commit fac9cb3
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions Formula/nginx-full.rb
Original file line number Diff line number Diff line change
Expand Up @@ -294,13 +294,9 @@ def install

# Install LuaJit
if build.with?("lua-module")
if(File.exist?('/usr/local/bin/brew'))
luajit_path = `/usr/local/bin/brew --prefix luajit`.chomp
else
luajit_path = `/opt/homebrew/bin/brew --prefix luajit`.chomp
end
ENV["LUAJIT_INC"] = "#{luajit_path}/include/luajit-2.1"
ENV["LUAJIT_LIB"] = "#{luajit_path}/lib"
luajit_version = Formula["pcre"].pkg_version.to_s.sub(/-\d+\.\d+$/, "")
ENV["LUAJIT_INC"] = "#{Formula["pcre"].opt_include}/luajit-#{luajit_version}"
ENV["LUAJIT_LIB"] = "#{Formula["pcre"].opt_lib}"
end

if build.head?
Expand Down

0 comments on commit fac9cb3

Please sign in to comment.