86 lines
2.4 KiB
Ruby
86 lines
2.4 KiB
Ruby
class ShibbolethSp < Formula
|
|
desc "Shibboleth 2 Service Provider daemon"
|
|
homepage "https://wiki.shibboleth.net/confluence/display/SHIB2"
|
|
url "https://shibboleth.net/downloads/service-provider/3.0.4/shibboleth-sp-3.0.4.tar.bz2"
|
|
sha256 "f5dc0fd028b74db4aaae76b59ec98e8a719c38cfe0f1d722feb2d5e0b9880cff"
|
|
revision 1
|
|
|
|
bottle do
|
|
rebuild 1
|
|
sha256 "8a09632277ead38ae04cb9fd0bf036cc3511d06e6a7a85745847dffee849927b" => :catalina
|
|
sha256 "0955fcb426b32fcbe3875c106681d69bcc6ecdddf25f19c1ef585b1168aeeaae" => :mojave
|
|
sha256 "09bec26e3cdfd3dbcb15c851589a223b5b7907771eca4ad96b9ed6b51587e37d" => :high_sierra
|
|
end
|
|
|
|
depends_on "apr" => :build
|
|
depends_on "apr-util" => :build
|
|
depends_on "pkg-config" => :build
|
|
depends_on "boost"
|
|
depends_on "httpd" if MacOS.version >= :high_sierra
|
|
depends_on "log4shib"
|
|
depends_on :macos => :yosemite
|
|
depends_on "opensaml"
|
|
depends_on "openssl@1.1"
|
|
depends_on "unixodbc"
|
|
depends_on "xerces-c"
|
|
depends_on "xml-security-c"
|
|
depends_on "xml-tooling-c"
|
|
|
|
def install
|
|
ENV.cxx11
|
|
args = %W[
|
|
--disable-debug
|
|
--disable-dependency-tracking
|
|
--disable-silent-rules
|
|
--prefix=#{prefix}
|
|
--localstatedir=#{var}
|
|
--sysconfdir=#{etc}
|
|
--with-xmltooling=#{Formula["xml-tooling-c"].opt_prefix}
|
|
--with-saml=#{Formula["opensaml"].opt_prefix}
|
|
--enable-apache-24
|
|
DYLD_LIBRARY_PATH=#{lib}
|
|
]
|
|
|
|
if MacOS.version >= :high_sierra
|
|
args << "--with-apxs24=#{Formula["httpd"].opt_bin}/apxs"
|
|
end
|
|
|
|
system "./configure", *args
|
|
system "make", "install"
|
|
end
|
|
|
|
def post_install
|
|
(var/"run/shibboleth/").mkpath
|
|
(var/"cache/shibboleth").mkpath
|
|
end
|
|
|
|
plist_options :startup => true, :manual => "shibd"
|
|
|
|
def plist; <<~EOS
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
<plist version="1.0">
|
|
<dict>
|
|
<key>Label</key>
|
|
<string>#{plist_name}</string>
|
|
<key>ProgramArguments</key>
|
|
<array>
|
|
<string>#{opt_sbin}/shibd</string>
|
|
<string>-F</string>
|
|
<string>-f</string>
|
|
<string>-p</string>
|
|
<string>#{var}/run/shibboleth/shibd.pid</string>
|
|
</array>
|
|
<key>RunAtLoad</key>
|
|
<true/>
|
|
<key>KeepAlive</key>
|
|
<true/>
|
|
</dict>
|
|
</plist>
|
|
EOS
|
|
end
|
|
|
|
test do
|
|
system sbin/"shibd", "-t"
|
|
end
|
|
end
|