-
-
Notifications
You must be signed in to change notification settings - Fork 12.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #154837 from cho-m/ocaml-5.1.0
ocaml 5.1.0; ocaml@4 4.14.1 (new formula); ledit 2.06
- Loading branch information
Showing
13 changed files
with
249 additions
and
165 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../Formula/o/ocaml.rb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,54 @@ | ||
class Coccinelle < Formula | ||
desc "Program matching and transformation engine for C code" | ||
homepage "https://coccinelle.lip6.fr/" | ||
url "https://github.com/coccinelle/coccinelle.git", | ||
tag: "1.1.1", | ||
revision: "5444e14106ff17404e63d7824b9eba3c0e7139ba" | ||
license "GPL-2.0-only" | ||
revision 1 | ||
head "https://github.com/coccinelle/coccinelle.git", branch: "master" | ||
|
||
stable do | ||
url "https://github.com/coccinelle/coccinelle.git", | ||
tag: "1.1.1", | ||
revision: "5444e14106ff17404e63d7824b9eba3c0e7139ba" | ||
|
||
# Backport compatibility with OCaml 5. Remove in the next release. | ||
patch do | ||
url "https://github.com/coccinelle/coccinelle/commit/f13b03aa20a08e5187ce36bfd5e606f18acd2888.patch?full_index=1" | ||
sha256 "84f06551652d9fcee63451fe8d3bce3845c01fe054087cde50bb3b8308014445" | ||
end | ||
patch do | ||
url "https://github.com/coccinelle/coccinelle/commit/1d0733a27006b06eef712f541000a8bf10246804.patch?full_index=1" | ||
sha256 "391ee079fc18ac4727af089fdf686cd41d4b2ba7847c4bcf2b3b04caf5b6d457" | ||
end | ||
|
||
# Backport usage of non-bundled packages to allow versions installed by opam | ||
patch do | ||
url "https://github.com/coccinelle/coccinelle/commit/3f54340c8ac907e528dbe1475a4a7141e77b9cdd.patch?full_index=1" | ||
sha256 "94b23b53c023270368601bc5debefc918a99f87b7489e25acddf9c967ddb4486" | ||
end | ||
patch do | ||
url "https://github.com/coccinelle/coccinelle/commit/2afa9f669b565badf17104176cc4850a2dff67f6.patch?full_index=1" | ||
sha256 "882fe080f7fbce4b0f08b8854a5b02212c17efbc2a62c145eae562842d8e2337" | ||
end | ||
patch do | ||
url "https://github.com/coccinelle/coccinelle/commit/d9ce82a556e313684af74912cf204bb902e04436.patch?full_index=1" | ||
sha256 "4b27d81d27363efb1a83064abba1df1c09a1f1f064c81cc621ca61b79f58d83e" | ||
end | ||
end | ||
|
||
livecheck do | ||
url :stable | ||
regex(/^v?(\d+(?:\.\d+)+)$/i) | ||
end | ||
|
||
bottle do | ||
sha256 arm64_ventura: "c36d64915f8f1fb1d3f1b11affa180d87cce7c2fab525ca5d43e000d6552ac84" | ||
sha256 arm64_monterey: "6d709b2576f84260edf15ed3a6c4e4b4e0cc73bde3819f9d9085f964c761b155" | ||
sha256 arm64_big_sur: "43e22010b8b1f3bf93817d161e2d0e96d907f4a38972d27f91d0231042f70860" | ||
sha256 ventura: "7d44848e93251045e263c647aa95c2fd7639ab2918dcdea672ea12115c0f922d" | ||
sha256 monterey: "9e00a25cc6afe398d4a5ae42300bacd883bf1f570e6c1523ffb43bd3d330ae30" | ||
sha256 big_sur: "270fe7690278277362ebf04707665ae41e3831c21e33d945408f2e7d9737669e" | ||
sha256 catalina: "27b442146b362f44848997fa840389ff9df05317e915147d289a74e1ef4c5a68" | ||
sha256 x86_64_linux: "29a0aeaeb102990cac27cdc3ecc713f2af6366f38c5d3cefb520ef70dcd2fa84" | ||
rebuild 1 | ||
sha256 arm64_sonoma: "ca6145d84ac088d6a9af56409383ee95fcdfc019d565f57a16ab6571b468df10" | ||
sha256 arm64_ventura: "cb7b2f3f20840b99f22efba6538fd4e7a6fa3868aa9f934c5722e26a968dc753" | ||
sha256 arm64_monterey: "368b32215f0409f8686364f2d5f9fa6d6ef3896ae1baddba37ad34abc2021a8a" | ||
sha256 sonoma: "6e9fcb9482970a2459a8e6bc4b319cd06d555dbfcd6501ad5cae9d9fc8dad61b" | ||
sha256 ventura: "60b09a4b123954c6a206cfa471c8653622f9567f786eb183241b1cd55f412128" | ||
sha256 monterey: "108f9640319df581d2feb12d6f52540d7f30876d24f48547e2a901ddda474aed" | ||
sha256 x86_64_linux: "1d24df746aee06ce03219fb78ff208b30b7b14c666195e30623c9012c9f825ea" | ||
end | ||
|
||
depends_on "autoconf" => :build | ||
|
@@ -30,42 +57,28 @@ class Coccinelle < Formula | |
depends_on "ocaml-findlib" => :build | ||
depends_on "opam" => :build | ||
depends_on "pkg-config" => :build | ||
depends_on "[email protected]" => :build | ||
depends_on "ocaml" | ||
depends_on "pcre" | ||
|
||
uses_from_macos "unzip" => :build | ||
|
||
# Bootstrap resource for Ocaml 4.12 compatibility. | ||
# Remove when Coccinelle supports Ocaml 4.12 natively | ||
resource "stdcompat" do | ||
url "https://github.com/thierry-martinez/stdcompat/releases/download/v15/stdcompat-15.tar.gz" | ||
sha256 "5e746f68ffe451e7dabe9d961efeef36516b451f35a96e174b8f929a44599cf5" | ||
end | ||
|
||
def install | ||
resource("stdcompat").stage do | ||
system "./configure", "--prefix=#{buildpath}/bootstrap" | ||
ENV.deparallelize { system "make" } | ||
system "make", "install" | ||
end | ||
ENV.prepend_path "OCAMLPATH", buildpath/"bootstrap/lib" | ||
|
||
Dir.mktmpdir("opamroot") do |opamroot| | ||
ENV["OPAMROOT"] = opamroot | ||
ENV["OPAMYES"] = "1" | ||
ENV["OPAMVERBOSE"] = "1" | ||
system "opam", "init", "--no-setup", "--disable-sandboxing" | ||
system "opam", "exec", "--", "opam", "install", ".", "--deps-only", "-y", "--no-depexts" | ||
system "./autogen" | ||
system "opam", "config", "exec", "--", "./configure", | ||
"--disable-dependency-tracking", | ||
"--enable-release", | ||
"--enable-ocaml", | ||
"--enable-opt", | ||
"--with-pdflatex=no", | ||
"--prefix=#{prefix}", | ||
"--libdir=#{lib}" | ||
system "opam", "exec", "--", "./configure", *std_configure_args, | ||
"--disable-silent-rules", | ||
"--enable-ocaml", | ||
"--enable-opt", | ||
"--without-pdflatex", | ||
"--with-bash-completion=#{bash_completion}" | ||
ENV.deparallelize | ||
system "opam", "config", "exec", "--", "make" | ||
system "opam", "exec", "--", "make" | ||
system "make", "install" | ||
end | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.