Skip to content

Fix: make build for Apple Silicon#2550

Merged
mergify[bot] merged 5 commits intoethereum-optimism:developfrom
DanieleSalatti:patch-1
May 23, 2022
Merged

Fix: make build for Apple Silicon#2550
mergify[bot] merged 5 commits intoethereum-optimism:developfrom
DanieleSalatti:patch-1

Conversation

@DanieleSalatti
Copy link
Contributor

Description
Fixing the build process on Mac with Apple Silicon.

Additional context
Building on M1 macs fails because of missing dependencies.

Metadata

I had the same issue as #2429, adding `eudev-dev` and `build-base` fixes it.
@changeset-bot
Copy link

changeset-bot bot commented May 8, 2022

⚠️ No Changeset found

Latest commit: f37c385

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@mergify mergify bot requested review from Inphi and tuxcanfly May 8, 2022 23:49
@tynes
Copy link
Contributor

tynes commented May 9, 2022

Does anybody have an m1 to test this out?

@tuxcanfly
Copy link
Contributor

This fixes the issue with yarn install. But there's something else that's failing and I'm not sure if it's just me 😕

 => ERROR [base 17/17] RUN yarn build                                                                                                                                                                  17.9s
------
 > [base 17/17] RUN yarn build:
#21 0.782 yarn run v1.22.18
#21 0.812 $ yarn lerna run build
#21 1.043 $ /opt/optimism/node_modules/.bin/lerna run build
#21 1.454 lerna notice cli v4.0.0
#21 1.456 lerna info versioning independent
#21 1.504 lerna info Executing command in 9 packages: "yarn run build"
#21 6.684 lerna info run Ran npm script 'build' in '@eth-optimism/core-utils' in 5.2s:
#21 6.684 $ tsc -p tsconfig.build.json
#21 12.11 lerna info run Ran npm script 'build' in '@eth-optimism/common-ts' in 5.4s:
#21 12.11 $ tsc -p tsconfig.build.json
#21 17.00 lerna ERR! yarn run build exited 2 in '@eth-optimism/replica-healthcheck'
#21 17.00 lerna ERR! yarn run build stdout:
#21 17.00 $ tsc -p tsconfig.build.json
#21 17.00 src/service.ts(3,3): error TS2724: '"@eth-optimism/common-ts"' has no exported member named 'BaseServiceV2'. Did you mean 'BaseService'?
#21 17.00 src/service.ts(4,3): error TS2305: Module '"@eth-optimism/common-ts"' has no exported member 'Counter'.
#21 17.00 src/service.ts(5,3): error TS2305: Module '"@eth-optimism/common-ts"' has no exported member 'Gauge'.
#21 17.00 src/service.ts(6,3): error TS2305: Module '"@eth-optimism/common-ts"' has no exported member 'validators'.
#21 17.00 src/service.ts(90,33): error TS2339: Property 'options' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(93,14): error TS2339: Property 'logger' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(94,14): error TS2339: Property 'metrics' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(104,36): error TS2339: Property 'options' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(109,14): error TS2339: Property 'logger' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(110,14): error TS2339: Property 'metrics' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(122,10): error TS2339: Property 'metrics' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(123,10): error TS2339: Property 'metrics' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(124,10): error TS2339: Property 'metrics' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(126,10): error TS2339: Property 'logger' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(133,34): error TS2339: Property 'options' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(136,12): error TS2339: Property 'logger' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(142,31): error TS2339: Property 'options' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(145,12): error TS2339: Property 'logger' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(156,12): error TS2339: Property 'logger' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(164,12): error TS2339: Property 'logger' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(170,14): error TS2339: Property 'logger' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(171,35): error TS2339: Property 'options' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(172,35): error TS2339: Property 'options' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(181,12): error TS2339: Property 'logger' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(182,12): error TS2339: Property 'metrics' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(183,12): error TS2339: Property 'metrics' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(189,24): error TS2339: Property 'options' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(193,10): error TS2339: Property 'logger' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(198,10): error TS2339: Property 'metrics' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(199,10): error TS2339: Property 'metrics' does not exist on type 'HealthcheckService'.
#21 17.00 src/service.ts(205,11): error TS2339: Property 'run' does not exist on type 'HealthcheckService'.
#21 17.00 info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
#21 17.00 lerna ERR! yarn run build stderr:
#21 17.00 error Command failed with exit code 2.
#21 17.00 lerna ERR! yarn run build exited 2 in '@eth-optimism/replica-healthcheck'
#21 17.00 lerna WARN complete Waiting for 1 child process to exit. CTRL-C to exit immediately.
#21 17.21 error Command failed with exit code 2.
#21 17.21 info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
#21 17.39 error Command failed with exit code 2.
#21 17.39 info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
------
executor failed running [/bin/sh -c yarn build]: exit code: 2
ERROR: Service 'deployer' failed to build : Build failed

@DanieleSalatti
Copy link
Contributor Author

@tuxcanfly I did not get that one.

Which commit are you on? I can take a look.

@tuxcanfly
Copy link
Contributor

@DanieleSalatti I think it's something silly like outdated dependencies on my local.

@smartcontracts Any idea why this happens? I think I have a pretty clean build and I'm trying to yarn build in the replica-healthcheck package but seeing this:

yarn run v1.22.18
$ tsc -p tsconfig.build.json
src/service.ts:3:3 - error TS2724: '"@eth-optimism/common-ts"' has no exported member named 'BaseServiceV2'. Did you mean 'BaseService'?

3   BaseServiceV2,
    ~~~~~~~~~~~~~

  ../common-ts/dist/base-service.d.ts:13:22
    13 export declare class BaseService<T> {
                            ~~~~~~~~~~~
    'BaseService' is declared here.

src/service.ts:4:3 - error TS2305: Module '"@eth-optimism/common-ts"' has no exported member 'Counter'.

@DanieleSalatti
Copy link
Contributor Author

@tuxcanfly I might have some time today to try this again from a clean clone, I will report back if I hit the same issue you are having and I'll try to look into it

Copy link
Contributor

@Inphi Inphi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. The build-base package already contains the libev headers, so you can remove the evdev-dev dep.

@mergify mergify bot requested a review from Inphi May 16, 2022 15:57
@smartcontracts
Copy link
Contributor

@DanieleSalatti I think it's something silly like outdated dependencies on my local.

@smartcontracts Any idea why this happens? I think I have a pretty clean build and I'm trying to yarn build in the replica-healthcheck package but seeing this:

yarn run v1.22.18
$ tsc -p tsconfig.build.json
src/service.ts:3:3 - error TS2724: '"@eth-optimism/common-ts"' has no exported member named 'BaseServiceV2'. Did you mean 'BaseService'?

3   BaseServiceV2,
    ~~~~~~~~~~~~~

  ../common-ts/dist/base-service.d.ts:13:22
    13 export declare class BaseService<T> {
                            ~~~~~~~~~~~
    'BaseService' is declared here.

src/service.ts:4:3 - error TS2305: Module '"@eth-optimism/common-ts"' has no exported member 'Counter'.

Can you try:

yarn clean
yarn build
cd ops
docker-compose build

@tuxcanfly
Copy link
Contributor

@smartcontracts That worked! Sorry for holding up this PR, it was probably unrelated.

@DanieleSalatti
Copy link
Contributor Author

Looks good. The build-base package already contains the libev headers, so you can remove the evdev-dev dep.

Done :)

@DanieleSalatti
Copy link
Contributor Author

Merging from development

@DanieleSalatti
Copy link
Contributor Author

@tuxcanfly @Inphi - quick ping for approval :)

Copy link
Contributor

@Inphi Inphi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks!

@mergify
Copy link
Contributor

mergify bot commented May 23, 2022

This PR has been added to the merge queue, and will be merged soon.

@mergify mergify bot requested a review from Inphi May 23, 2022 01:53
@mergify
Copy link
Contributor

mergify bot commented May 23, 2022

This PR is next in line to be merged, and will be merged as soon as checks pass.

@mergify mergify bot merged commit 262b0db into ethereum-optimism:develop May 23, 2022
@DanieleSalatti DanieleSalatti deleted the patch-1 branch May 24, 2022 15:21
theochap pushed a commit that referenced this pull request Dec 10, 2025
### Description

Release artifacts for the `kona-node` release `v0.1.1`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-ops Area: ops

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Building Optimistic Ethereum locally fails

6 participants