BitBoxSwiss / bitbox-bridge

A bridge that connects web wallets like MyEtherWallet to BitBox02
Apache License 2.0
20 stars 14 forks source link

Installation & Launch issue on Mac with M1 #21

Open jstrnbrg opened 3 years ago

jstrnbrg commented 3 years ago

Issues

cc @x1ddos

NickeZ commented 3 years ago

It looks correctly installed. It runs in the background which explains why the port is already busy. Iirc there is a web address you can enter to see if it is running. Let me check

jstrnbrg commented 3 years ago

@NickeZ this link http://127.0.0.1:8178/?

Yeah after launching via right-click > open it's running, just didn't expect the terminal to show an error

NickeZ commented 3 years ago

It should be running even if you didn't "right-click -> open". It should be running in the background after the laptop has booted.

edit: yeah, that is the link to check if it is running

x1ddos commented 3 years ago

FTR I believe all these troubles are solved by producing signed and notarized binaries or macOS.

NickeZ commented 3 years ago

re-reading it I realized that this is a new ARM based macbook, so signing/notarizing wouldn't solve the issue. I thought M1 should be able to run x86 executables, but maybe not. We can compile it for M1, but I'll have a hard time testing. So we need to find a user willing to test for us.

x1ddos commented 3 years ago

signing/notarizing wouldn't solve the issue

why not? why would a CPU architecture affect signing and notarization?

M1 should be able to run x86 executables, but maybe not

it cannot run x86 natively but via their Rosetta 2 thing. but yes, we should compile the bridge for native M1 too and make it a universal binary that works for both architectures.

NickeZ commented 3 years ago

signing/notarizing wouldn't solve the issue

why not? why would a CPU architecture affect signing and notarization?

(Since I don't have apple aarch64 hardware I cannot replicate the issue, but I assume the issue "After installation there is a "bitbox-bridge can't be opened" error that keeps poping up." is unrelated to signing/notarization.

M1 should be able to run x86 executables, but maybe not

it cannot run x86 natively but via their Rosetta 2 thing. but yes, we should compile the bridge for native M1 too and make it a universal binary that works for both architectures.

Yeah, doesn't seem that hard to create a universal binary. The only problem I have is with testing it :/

x1ddos commented 3 years ago

On 4/12/21 3:09 PM, Niklas Dusenlund wrote:

signing/notarizing wouldn't solve the issue

why not? why would a CPU architecture affect signing and notarization?

(Since I don't have apple aarch64 hardware I cannot replicate the issue, but I assume the issue "After installation there is a "bitbox-bridge can't be opened" error that keeps poping up." is unrelated to signing/notarization.

I have access to a M1 mac mini here. A BitBoxApp built for x86 behaves in the same way. If unsigned or not notarized, I can't run it easily - need to right click > open first, same as here in this issue. When signed and notarized, I'm running it via the Rosetta 2 without issues.

M1 should be able to run x86 executables, but maybe not

it cannot run x86 natively but via their Rosetta 2 thing. but yes, we should compile the bridge for native M1 too and make it a universal binary that works for both architectures.

Yeah, doesn't seem that hard to create a universal binary. The only problem I have is with testing it :/

I have an M1. Maybe I should take this issue and send you some pull requests.

NickeZ commented 3 years ago

I have a WIP branch here that builds two executables, haven't tested the lipo and signing calls yet in package.sh

edit: made a PR https://github.com/digitalbitbox/bitbox-bridge/pull/23