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

Error related to Rosetta on Macbook M1 Pro in Docker #99

Open
Mauladen opened this issue May 24, 2024 · 3 comments
Open

Error related to Rosetta on Macbook M1 Pro in Docker #99

Mauladen opened this issue May 24, 2024 · 3 comments

Comments

@Mauladen
Copy link

Good afternoon, I use your tool as part of lost-pixel, but there is a nuance - this is the use of Docker, I use an ARM64 Playwright image into which I copy the project to run lost-pixel

Screenshots are taken stably and do not cause errors, and when diff is launched, the error rosetta error: failed to open elf at /lib64/ld-linux-x86-64.so.2 appears

I most likely understand why this happens after studying postinstall.js, since diff defines the target system as linux

For information, the AMD64 image does not have this problem, but it runs slower, just by running the odiff --help command in the Docker container I get the same error

Maybe you will have ideas on how to fix this?

@dmtrKovalenko
Copy link
Owner

I don’t think that we provide Linux arm binary. OCaml has very hard relationships with cross compilation 😔

In your case I would try to:

  1. Manually run postinstall script from the odiff directory like cd node_modules/odiff && yarn postinstall

  2. It might not work so you will need to remove some directories

  3. If it doesn’t help reinstall odiff after mounting / unmounting the volume

@Mauladen
Copy link
Author

I don’t think that we provide Linux arm binary. OCaml has very hard relationships with cross compilation 😔

In your case I would try to:

1. Manually run postinstall script from the odiff directory like cd node_modules/odiff && yarn postinstall

2. It might not work so you will need to remove some directories

3. If it doesn’t help reinstall odiff after mounting / unmounting the volume

Thank you for your answer, I will try your options and give you an answer later

@Mauladen
Copy link
Author

Good afternoon, I found a solution and that's what helped me to launch your application

RUN apt-get install -y libc6-amd64-cross
RUN ln -s /usr/x86_64-linux-gnu/lib64/ /lib64
ENV LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/lib64:/usr/x86_64-linux-gnu/lib"

It may be worth specifying this information somewhere, but this is at your discretion

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants