mirror of
https://github.com/livebook-dev/livebook.git
synced 2025-10-09 21:16:26 +08:00
Update Mac build scripts (#1198)
This commit is contained in:
parent
3cf20e521f
commit
cf587e7115
3 changed files with 4 additions and 19 deletions
4
.github/scripts/app/bootstrap_mac.sh
vendored
4
.github/scripts/app/bootstrap_mac.sh
vendored
|
@ -5,8 +5,8 @@ main() {
|
||||||
export MAKEFLAGS=-j$(getconf _NPROCESSORS_ONLN)
|
export MAKEFLAGS=-j$(getconf _NPROCESSORS_ONLN)
|
||||||
|
|
||||||
wxwidgets_vsn="3.1.5"
|
wxwidgets_vsn="3.1.5"
|
||||||
otp_vsn="24.2"
|
otp_vsn="25.0"
|
||||||
elixir_vsn="1.13.2"
|
elixir_vsn="1.13.4"
|
||||||
|
|
||||||
target=$(target)
|
target=$(target)
|
||||||
|
|
||||||
|
|
2
.github/scripts/app/build_mac.sh
vendored
2
.github/scripts/app/build_mac.sh
vendored
|
@ -9,7 +9,7 @@
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
sh .github/scripts/app/bootstrap_mac.sh
|
sh .github/scripts/app/bootstrap_mac.sh
|
||||||
. tmp/bootstrap_env.sh
|
sh tmp/bootstrap_env.sh
|
||||||
|
|
||||||
# If CODESIGN_IDENITY is set, let's build the .dmg which would also notarize it.
|
# If CODESIGN_IDENITY is set, let's build the .dmg which would also notarize it.
|
||||||
# Otherwise, let's build just the .app.
|
# Otherwise, let's build just the .app.
|
||||||
|
|
|
@ -72,7 +72,7 @@ defmodule Standalone do
|
||||||
end
|
end
|
||||||
|
|
||||||
defp download_elixir_at_destination(destination, version) do
|
defp download_elixir_at_destination(destination, version) do
|
||||||
url = "https://github.com/elixir-lang/elixir/releases/download/v#{version}/Precompiled.zip"
|
url = "https://repo.hex.pm/builds/elixir/v#{version}-otp-#{System.otp_release()}.zip"
|
||||||
path = Path.join(System.tmp_dir!(), "elixir_#{version}.zip")
|
path = Path.join(System.tmp_dir!(), "elixir_#{version}.zip")
|
||||||
|
|
||||||
unless File.exists?(path) do
|
unless File.exists?(path) do
|
||||||
|
@ -115,19 +115,4 @@ defmodule Standalone do
|
||||||
defp cp_r!(source, destination) do
|
defp cp_r!(source, destination) do
|
||||||
File.cp_r!(source, destination, fn _, _ -> false end)
|
File.cp_r!(source, destination, fn _, _ -> false end)
|
||||||
end
|
end
|
||||||
|
|
||||||
# From https://github.com/fishcakez/dialyze/blob/6698ae582c77940ee10b4babe4adeff22f1b7779/lib/mix/tasks/dialyze.ex#L168
|
|
||||||
defp otp_version do
|
|
||||||
major = :erlang.system_info(:otp_release) |> List.to_string()
|
|
||||||
vsn_file = Path.join([:code.root_dir(), "releases", major, "OTP_VERSION"])
|
|
||||||
|
|
||||||
try do
|
|
||||||
vsn_file |> File.read!() |> String.split("\n", trim: true)
|
|
||||||
else
|
|
||||||
[full] -> full
|
|
||||||
_ -> major
|
|
||||||
catch
|
|
||||||
:error, _ -> major
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Reference in a new issue