metanorma / homebrew-metanorma

Homebrew formula for Metanorma
1 stars 0 forks source link

linux brew shall consider os flavor and architecture #88

Open maxirmx opened 4 weeks ago

maxirmx commented 4 weeks ago

For linux plaform we produce three tebako packages -- linux-gnu-x86_64, linux-gnu-aarch64, linux-musl-x86_64
Probably we can also create linux-musl-aarch64

Metanorma brew always attemps to install linux-gnu-x86_64 binary and it makes it not very friendly. I think it needs at least reject installation if binary does not match or install appropriate binary as macos version does now

CAMOBAP commented 1 week ago

We may have to use

if Hardware::CPU.intel?
  url "https://example.com/software-x86_64.tar.gz"
  sha256 "sha256-for-x86_64"
elsif Hardware::CPU.arm?
  url "https://example.com/software-aarch64.tar.gz"
  sha256 "sha256-for-aarch64"
end

for x86_64 and aarch64 but no known solution for linux-musl-x86_64 yet