64 lines
2.3 KiB
Ruby
64 lines
2.3 KiB
Ruby
class Lasso < Formula
|
|
desc "Library for Liberty Alliance and SAML protocols"
|
|
homepage "https://lasso.entrouvert.org/"
|
|
url "https://dev.entrouvert.org/releases/lasso/lasso-2.6.1.tar.gz"
|
|
sha256 "f8a8dbce238802f6bb9c3b8bd528b4dce2a1dc44e2d34d8d839aa54fbc8ed1de"
|
|
license "GPL-2.0"
|
|
|
|
bottle do
|
|
cellar :any
|
|
sha256 "aecca2fc642d36e34cd455c69c22e9218c7189069cfebeeedace812308d3b09c" => :catalina
|
|
sha256 "aa800d43d4a10ef664f5cfbd323d1417bbafe5a59f6110814b74cd4eecfc51be" => :mojave
|
|
sha256 "ef80d2303bf630a7c077f404f948eaf0e960afb81b8dced7853cee50ccc2b7dc" => :high_sierra
|
|
end
|
|
|
|
depends_on "pkg-config" => :build
|
|
depends_on "python@3.8" => :build
|
|
depends_on "glib"
|
|
depends_on "libxmlsec1"
|
|
depends_on "openssl@1.1"
|
|
|
|
resource "six" do
|
|
url "https://files.pythonhosted.org/packages/21/9f/b251f7f8a76dec1d6651be194dfba8fb8d7781d10ab3987190de8391d08e/six-1.14.0.tar.gz"
|
|
sha256 "236bdbdce46e6e6a3d61a337c0f8b763ca1e8717c03b369e87a7ec7ce1319c0a"
|
|
end
|
|
|
|
def install
|
|
xy = Language::Python.major_minor_version "python3"
|
|
ENV.prepend_create_path "PYTHONPATH", libexec/"vendor/lib/python#{xy}/site-packages"
|
|
resources.each do |r|
|
|
r.stage do
|
|
system "python3", *Language::Python.setup_install_args(libexec/"vendor")
|
|
end
|
|
end
|
|
|
|
ENV.prepend_create_path "PYTHONPATH", libexec/"lib/python#{xy}/site-packages"
|
|
system "./configure", "--disable-dependency-tracking",
|
|
"--disable-silent-rules",
|
|
"--disable-java",
|
|
"--disable-perl",
|
|
"--disable-php5",
|
|
"--disable-python",
|
|
"--prefix=#{prefix}",
|
|
"--with-pkg-config=#{ENV["PKG_CONFIG_PATH"]}"
|
|
system "make", "install"
|
|
end
|
|
|
|
test do
|
|
(testpath/"test.c").write <<~EOS
|
|
#include <lasso/lasso.h>
|
|
|
|
int main() {
|
|
return lasso_init();
|
|
}
|
|
EOS
|
|
system ENV.cc, "test.c",
|
|
"-I#{Formula["glib"].include}/glib-2.0",
|
|
"-I#{Formula["glib"].lib}/glib-2.0/include",
|
|
"-I#{MacOS.sdk_path}/usr/include/libxml2",
|
|
"-I#{Formula["libxmlsec1"].include}/xmlsec1",
|
|
"-L#{lib}", "-llasso", "-o", "test"
|
|
system "./test"
|
|
end
|
|
end
|