Skip to content

Commit

Permalink
[TMP]
Browse files Browse the repository at this point in the history
  • Loading branch information
krendelhoff2 committed Dec 1, 2024
1 parent ed5df9d commit ee468fb
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 10 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build-bottles.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ { id: macos-13, name: "ventura" } ]
os: [ { id: macos-14, name: "sonoma" } ]
# we don't bottle meta-formulas that contain only services
formula: [tezos-smart-rollup-wasm-debugger]
formula: [tezos-client]
steps:
- name: Checkout
uses: actions/checkout@v4
Expand Down
8 changes: 4 additions & 4 deletions Formula/tezos-client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class << self

version "v21.0-1"

build_dependencies = %w[pkg-config coreutils autoconf rsync wget rustup-init cmake opam opam]
build_dependencies = %w[pkg-config coreutils autoconf rsync wget rustup cmake opam]
build_dependencies.each do |dependency|
depends_on dependency => :build
end
Expand All @@ -30,7 +30,6 @@ class << self

def make_deps
ENV.deparallelize
ENV["CARGO_HOME"]="./.cargo"
# Disable usage of instructions from the ADX extension to avoid incompatibility
# with old CPUs, see https://gitlab.com/dannywillems/ocaml-bls12-381/-/merge_requests/135/
ENV["BLST_PORTABLE"]="yes"
Expand All @@ -39,9 +38,10 @@ def make_deps
ENV["LDFLAGS"] = "-L#{HOMEBREW_PREFIX}/lib"
# Here is the workaround to use opam 2.0.9 because Tezos is currently not compatible with opam 2.1.0 and newer
arch = RUBY_PLATFORM.include?("arm64") ? "arm64" : "x86_64"
system "rustup-init", "--default-toolchain", "1.78.0", "-y"
system "rustup", "install", "1.78.0"
system "opam", "init", "--bare", "--debug", "--auto-setup", "--disable-sandboxing"
system ["source .cargo/env", "make build-deps"].join(" && ")
system "make build-deps"
system ["eval $(opam env)", "dune build -p octez-rust-deps"].join(" && ")
end

def install_template(dune_path, exec_path, name)
Expand Down
8 changes: 5 additions & 3 deletions Formula/tezos-node.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class << self

version "v21.0-1"

build_dependencies = %w[pkg-config coreutils autoconf rsync wget rustup-init cmake opam]
build_dependencies = %w[pkg-config coreutils autoconf rsync rustup wget cmake opam]
build_dependencies.each do |dependency|
depends_on dependency => :build
end
Expand All @@ -39,9 +39,11 @@ def make_deps
ENV["LDFLAGS"] = "-L#{HOMEBREW_PREFIX}/lib"
# Here is the workaround to use opam 2.0.9 because Tezos is currently not compatible with opam 2.1.0 and newer
arch = RUBY_PLATFORM.include?("arm64") ? "arm64" : "x86_64"
system "rustup-init", "--default-toolchain", "1.78.0", "-y"
system "sed -i \"s/cargo build/cargo build --quiet/\" src/rust_deps/build.sh"
system "opam", "init", "--bare", "--debug", "--auto-setup", "--disable-sandboxing"
system ["source .cargo/env", "make build-deps"].join(" && ")
system "rustup install 1.78.0"
system "make build-deps"
system "opam exec -- dune build -p octez-rust-deps"
end

def install_template(dune_path, exec_path, name)
Expand Down
2 changes: 1 addition & 1 deletion Formula/tezos-smart-rollup-wasm-debugger.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ def make_deps
def install_template(dune_path, exec_path, name)
bin.mkpath
self.class.all_bins << name
system ["source .cargo/env", "eval $(opam env)", "dune build #{dune_path}", "cp #{exec_path} #{name}"].join(" && ")
system ["eval $(opam env)", "dune build #{dune_path}", "cp #{exec_path} #{name}"].join(" && ")
bin.install name
ln_sf "#{bin}/#{name}", "#{bin}/#{name.gsub("octez", "tezos")}"
end
Expand Down

0 comments on commit ee468fb

Please sign in to comment.