Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prepare for LLVM 18, link to local repo for scripts and patches #27178

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions packages/conf-llvm-shared/conf-llvm-shared.18/opam
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
opam-version: "2.0"
maintainer: "Alan <[email protected]>"
authors: "The LLVM team"
homepage: "http://llvm.org"
bug-reports: "https://llvm.org/bugs/"
license: "MIT"
build: [
["bash" "configure.sh" version "shared"]
]
depends: [
"conf-bash" {build}
]
depexts: [
["llvm@18" "zstd"] {os-distribution = "homebrew" & os = "macos"}
["llvm-18"] {os-distribution = "macports" & os = "macos"}
["llvm-18-dev" "zlib1g-dev" "libzstd-dev"] {os-family = "debian"}
["llvm18-dev"] {os-distribution = "alpine"}
["llvm18"] {os-family = "arch"}
["llvm18-devel"] {os-family = "suse" | os-family = "opensuse"}
["llvm18-devel"] {os-distribution = "fedora" & os-version >= "41"}
["llvm-devel"] {os-distribution = "fedora" & os-version = "40"}
["llvm18-devel" "epel-release"] {os-distribution = "centos"}
["devel/llvm18"] {os = "freebsd"}
]
synopsis: "Virtual package relying on llvm shared library installation"
flags: conf
extra-source "configure.sh" {
src:
"https://raw.githubusercontent.com/ocaml/opam-source-archives/refs/heads/main/patches/conf-llvm-static/configure.sh.18"
checksum: [
"sha256=13b22f406b6aa4be03cf5c70a55a8513bdb9bd804877a99c66d79cf0d6b2fbd2"
"md5=a64daab3f3768dd671fcd046bd2c1a04"
]
}
34 changes: 34 additions & 0 deletions packages/conf-llvm-static/conf-llvm-static.18/opam
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
opam-version: "2.0"
maintainer: "Alan <[email protected]>"
authors: "The LLVM team"
homepage: "http://llvm.org"
bug-reports: "https://llvm.org/bugs/"
license: "MIT"
build: [
["bash" "configure.sh" version "static"]
]
depends: [
"conf-bash" {build}
]
depexts: [
["llvm@18" "zstd"] {os-distribution = "homebrew" & os = "macos"}
["llvm-18"] {os-distribution = "macports" & os = "macos"}
["llvm-18-dev" "zlib1g-dev" "libzstd-dev"] {os-family = "debian"}
["llvm18-dev"] {os-distribution = "alpine"}
["llvm18"] {os-family = "arch"}
["llvm18-devel"] {os-family = "suse" | os-family = "opensuse"}
["llvm18-devel"] {os-distribution = "fedora" & os-version >= "41"}
["llvm-devel"] {os-distribution = "fedora" & os-version = "40"}
["llvm18-devel" "epel-release"] {os-distribution = "centos"}
["devel/llvm18"] {os = "freebsd"}
]
synopsis: "Virtual package relying on llvm static library installation"
flags: conf
extra-source "configure.sh" {
src:
"https://raw.githubusercontent.com/ocaml/opam-source-archives/refs/heads/main/patches/conf-llvm-static/configure.sh.18"
checksum: [
"sha256=13b22f406b6aa4be03cf5c70a55a8513bdb9bd804877a99c66d79cf0d6b2fbd2"
"md5=a64daab3f3768dd671fcd046bd2c1a04"
]
}
52 changes: 52 additions & 0 deletions packages/llvm/llvm.18-shared/opam
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
opam-version: "2.0"
maintainer: "Alan <[email protected]>"
authors: [
"whitequark <[email protected]>"
"The LLVM team"
]
license: "MIT"
bug-reports: "http://llvm.org/bugs/"
dev-repo: "git+http://llvm.org/git/llvm.git"
doc: "http://llvm.org"
homepage: "http://llvm.org"
build: [
["bash" "-ex" "install.sh" "%{conf-llvm-shared:config}%" lib "%{conf-cmake:cmd}%" make "build" "shared"]
]
install: [
["bash" "-ex" "install.sh" "%{conf-llvm-shared:config}%" lib "%{conf-cmake:cmd}%" make "install" "shared"]
]
depends: [
"ocaml" {>= "4.00.0"}
"ctypes" {>= "0.4"}
"ocamlfind" {build}
"conf-llvm-shared" {build & = "18"}
"conf-cmake" {build}
]
patches: [
"AddOCaml.cmake.patch"
]
synopsis: "The OCaml bindings distributed with LLVM"
description: "Note: LLVM should be installed first."
url {
src: "https://github.com/llvm/llvm-project/releases/download/llvmorg-18.1.8/llvm-project-18.1.8.src.tar.xz"
checksum: [
"sha256=0b58557a6d32ceee97c8d533a59b9212d87e0fc4d2833924eb6c611247db2f2a"
"md5=81cd0be5ae6f1ad8961746116d426a96"
]
}
extra-source "install.sh" {
src:
"https://raw.githubusercontent.com/ocaml/opam-source-archives/main/patches/llvm/install.sh.18"
checksum: [
"sha256=91311c9a90258e6819adda4132f9f64df18f1f0b9df905e7f88be325ed18dce7"
"md5=70201a5ad01e104f7572e1fa0d498eaa"
]
}
extra-source "AddOCaml.cmake.patch" {
src:
"https://raw.githubusercontent.com/ocaml/opam-source-archives/main/patches/llvm/AddOCaml.cmake.patch.18"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"https://raw.githubusercontent.com/ocaml/opam-source-archives/main/patches/llvm/AddOCaml.cmake.patch.18"
"https://github.com/alan-j-hu/opam-source-archives/raw/e5d49c1c15149d3a239d237634f5fc85d903718d/patches/llvm/AddOCaml.cmake.patch.18"

to iterate on the patch and test it while you are working on it, this or any other remote location would be fine

checksum: [
"sha256=a4fac2d6ebfaa707906dc576b99f80efe42ee8857647eb881a07f8fb5ebcddd2"
"md5=5a6c39055106cfc700eef2ad0255cba6"
]
}
53 changes: 53 additions & 0 deletions packages/llvm/llvm.18-static/opam
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
opam-version: "2.0"
maintainer: "Alan <[email protected]>"
authors: [
"whitequark <[email protected]>"
"The LLVM team"
]
license: "MIT"
bug-reports: "http://llvm.org/bugs/"
dev-repo: "git+http://llvm.org/git/llvm.git"
doc: "http://llvm.org"
homepage: "http://llvm.org"
build: [
["bash" "-ex" "install.sh" "%{conf-llvm-static:config}%" lib "%{conf-cmake:cmd}%" make "build" "static"]
]
install: [
["bash" "-ex" "install.sh" "%{conf-llvm-static:config}%" lib "%{conf-cmake:cmd}%" make "install" "static"]
]
depends: [
"ocaml" {>= "4.00.0"}
"ctypes" {>= "0.4"}
"ocamlfind" {build}
"conf-llvm-static" {build & = "18"}
"conf-cmake" {build}
]
patches: [
"AddOCaml.cmake.patch"
]
synopsis: "The OCaml bindings distributed with LLVM"
description: "Note: LLVM should be installed first."
url {
src: "https://github.com/llvm/llvm-project/releases/download/llvmorg-18.1.8/llvm-project-18.1.8.src.tar.xz"
checksum: [
"sha256=0b58557a6d32ceee97c8d533a59b9212d87e0fc4d2833924eb6c611247db2f2a"
"md5=81cd0be5ae6f1ad8961746116d426a96"
]
}
extra-source "install.sh" {
src:
"https://raw.githubusercontent.com/ocaml/opam-source-archives/refs/heads/main/patches/llvm/install.sh.18"
checksum: [
"sha256=91311c9a90258e6819adda4132f9f64df18f1f0b9df905e7f88be325ed18dce7"
"md5=70201a5ad01e104f7572e1fa0d498eaa"
]
}
extra-source "AddOCaml.cmake.patch" {
src:
"https://raw.githubusercontent.com/ocaml/opam-source-archives/refs/heads/main/patches/llvm/AddOCaml.cmake.patch.18"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"https://raw.githubusercontent.com/ocaml/opam-source-archives/refs/heads/main/patches/llvm/AddOCaml.cmake.patch.18"
"https://github.com/alan-j-hu/opam-source-archives/raw/e5d49c1c15149d3a239d237634f5fc85d903718d/patches/llvm/AddOCaml.cmake.patch.18"

checksum: [
"sha256=3c9abe430b0868e5937e9944133d521f62677244e0a345e511f66cb9502e406a"
"md5=a9ef328c5a793812c25a5f8777316ad9"
]
}

Loading