Skip to content

Improve bootstrapping process - #68

Closed
Kha wants to merge 3 commits into
leanprover:masterfrom
Kha:reboot
Closed

Kha wants to merge 3 commits into
leanprover:masterfrom
Kha:reboot

Conversation

@Kha

@Kha Kha commented Nov 11, 2019 •

Copy link
Copy Markdown
Member

This PR changes src/ from being used to build both stage0 and stage1 lean, which was the major source of bootstrapping headaches. Instead a new top-level directory stage0/ contains a complete copy of src as well as the corresponding extracted library (the old src/stage0). This means it is now trivial to do C++ and Lean changes in parallel. The build interface itself is (mostly) unchanged.

@leodemoura I checked that update-stage0 and parallel changes indeed work, but I haven't used this change in practice yet. Please give it a try.

Comment thread stage0/library
@@ -0,0 +1 @@
../src/stage0 No newline at end of file

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

@leodemoura stage0/library and stage0/src are just symlinks here to avoid merge conflicts and huge diff lists; you should call update-stage0 before trying a parallel change, and after this commit is merged into master. Then we can remove src/stage0.

Comment thread src/CMakeLists.txt
if ((${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} GREATER 3.1) OR (${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} EQUAL 3.1))
cmake_policy(SET CMP0054 NEW)
endif()
include(ExternalProject)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

What is this?

@leodemoura

Copy link
Copy Markdown
Member

In the next Dev meeting, could you please go over these changes and describe how the new build system works?

@leodemoura

Copy link
Copy Markdown
Member

It worked for me, and I managed to update stage0 without problems.
I injected a bug at environment.cpp, and stage0 kept working as expected :)
I merged the PR, but I did not try to understand how it works.
I am hoping you will explain in the next dev meeting.

@leodemoura leodemoura closed this Nov 11, 2019
ChrisHughes24 pushed a commit to ChrisHughes24/lean4 that referenced this pull request Dec 2, 2022
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.

2 participants