66 lines
1.7 KiB
Ruby
66 lines
1.7 KiB
Ruby
class Openldap < Formula
|
|
desc "Open source suite of directory software"
|
|
homepage "https://www.openldap.org/software/"
|
|
url "https://www.openldap.org/software/download/OpenLDAP/openldap-release/openldap-2.4.55.tgz"
|
|
sha256 "97357bd6ba8ff73d204c1f8208c5e6ab97d60c9e779f989057aa1229bbe98434"
|
|
license "OLDAP-2.8"
|
|
|
|
livecheck do
|
|
url "https://www.openldap.org/software/download/OpenLDAP/openldap-release/"
|
|
regex(/href=.*?openldap[._-]v?(\d+(?:\.\d+)*)\.t/i)
|
|
end
|
|
|
|
bottle do
|
|
sha256 "7907819195a6937a8aad85ed171a5225f0ad898ec6fda6003490ca42caff41e9" => :catalina
|
|
sha256 "8ee5a4f33f0f31006d95cca80196adc2ba2fba7be278639e6e2c6e3a91df46f1" => :mojave
|
|
sha256 "fa8c14efccfda49e2b2d5f8d5e0b46391453da835fc039a7950bff2aa3558950" => :high_sierra
|
|
end
|
|
|
|
keg_only :provided_by_macos
|
|
|
|
depends_on "openssl@1.1"
|
|
|
|
on_linux do
|
|
depends_on "util-linux"
|
|
end
|
|
|
|
def install
|
|
args = %W[
|
|
--disable-dependency-tracking
|
|
--prefix=#{prefix}
|
|
--sysconfdir=#{etc}
|
|
--localstatedir=#{var}
|
|
--enable-accesslog
|
|
--enable-auditlog
|
|
--enable-bdb=no
|
|
--enable-constraint
|
|
--enable-dds
|
|
--enable-deref
|
|
--enable-dyngroup
|
|
--enable-dynlist
|
|
--enable-hdb=no
|
|
--enable-memberof
|
|
--enable-ppolicy
|
|
--enable-proxycache
|
|
--enable-refint
|
|
--enable-retcode
|
|
--enable-seqmod
|
|
--enable-translucent
|
|
--enable-unique
|
|
--enable-valsort
|
|
]
|
|
|
|
system "./configure", *args
|
|
system "make", "install"
|
|
(var/"run").mkpath
|
|
|
|
# https://github.com/Homebrew/homebrew-dupes/pull/452
|
|
chmod 0755, Dir[etc/"openldap/*"]
|
|
chmod 0755, Dir[etc/"openldap/schema/*"]
|
|
end
|
|
|
|
test do
|
|
system sbin/"slappasswd", "-s", "test"
|
|
end
|
|
end
|