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

[berkeley] feat: fix scripts to use different paths if mina is a submodule of o1js #14239

Closed

Conversation

MartinMinkov
Copy link
Contributor

Explain your changes:
Fixes some of the scripts called by dune to use different absolute paths if we are building mina in the context of the o1js as mina being a submodule.

The issue occurs when we build o1js from the root directory with mina as a submodule. Dune will try to resolve some absolute paths from build scripts that will fail and not build o1js properly. To fix this, we conditionally check for submodule locations and change the paths if we have a mina submodule present, otherwise, we use the same build process. This lets us build mina the same way but also build o1js dependencies properly.

Explain how you tested your changes:
Built mina from the root directory to test normal building and built o1js using mina as a submodule successfully.

Addresses o1-labs/o1js#1096

@MartinMinkov MartinMinkov requested review from a team as code owners October 2, 2023 17:15
@MartinMinkov
Copy link
Contributor Author

!ci-build-me

@MartinMinkov MartinMinkov force-pushed the feat/o1js-add-mina-submodule-support-berkeley branch from 75d3a17 to 99de50f Compare October 3, 2023 20:31
@MartinMinkov
Copy link
Contributor Author

!ci-build-me

@MartinMinkov MartinMinkov force-pushed the feat/o1js-add-mina-submodule-support-berkeley branch 2 times, most recently from 795bf01 to a8e13d3 Compare October 4, 2023 21:12
@MartinMinkov MartinMinkov requested a review from a team as a code owner October 4, 2023 21:12
@MartinMinkov MartinMinkov force-pushed the feat/o1js-add-mina-submodule-support-berkeley branch from a8e13d3 to 4f20eb6 Compare October 11, 2023 17:55
@mergify
Copy link
Contributor

mergify bot commented Oct 11, 2023

⚠️ The sha of the head commit of this PR conflicts with #14229. Mergify cannot evaluate rules on this PR. ⚠️

@MartinMinkov
Copy link
Contributor Author

!ci-build-me

@mergify
Copy link
Contributor

mergify bot commented Oct 19, 2023

⚠️ The sha of the head commit of this PR conflicts with #14229. Mergify cannot evaluate rules on this PR. ⚠️

@MartinMinkov
Copy link
Contributor Author

!ci-build-me

Copy link
Member

@shimkiv shimkiv 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 but left quick question.

scripts/mina-local-network/mina-local-network.sh Outdated Show resolved Hide resolved
@MartinMinkov
Copy link
Contributor Author

!ci-build-me

@@ -1,7 +1,7 @@
(library
(name libp2p_ipc)
(public_name libp2p_ipc)
(flags -w -53)
(flags -w -53-55)
Copy link
Member

Choose a reason for hiding this comment

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

why is this needed?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fair question! Nix fails while building libnp2p_ipcs, ignoring warning 55 while building src/libp2p_ipcs/libp2p_ipcs_capnp.ml seems to fix it. See this internal discussion for more details.

@deepthiskumar
Copy link
Member

!ci-build-me

@MartinMinkov
Copy link
Contributor Author

Moved too #14782

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

Successfully merging this pull request may close these issues.

6 participants