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

Hermetic builds #30011

Merged
merged 22 commits into from Nov 25, 2021
Merged

Hermetic builds #30011

merged 22 commits into from Nov 25, 2021

Conversation

alexey-milovidov
Copy link
Member

@alexey-milovidov alexey-milovidov commented Oct 12, 2021

Changelog category (leave one):

  • Build/Testing/Packaging Improvement

Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):
Hermetic builds: use fixed version of libc and make sure that no source or binary files from the host OS are using during build. This closes #27133. This closes #21435. This closes #30462.

Detailed description / Documentation draft:
See also #24371 and #22113.

@robot-clickhouse robot-clickhouse added the pr-build Pull request with build/testing/packaging improvement label Oct 12, 2021
@azat
Copy link
Collaborator

azat commented Oct 12, 2021

Great! So now #29594 can be reverted. @alexey-milovidov can you also revert it within this PR?

@alexey-milovidov
Copy link
Member Author

alexey-milovidov commented Oct 12, 2021

Ok, will do.

To finish this PR:

  • figure out how to disable hermetic builds for gcc and for shared build;
  • maybe remove the issue that protobuf is compiled twice;
  • look at the strange result of the compatibility check.

@robot-ch-test-poll2 robot-ch-test-poll2 added the submodule changed At least one submodule changed in this PR. label Nov 24, 2021
@alexey-milovidov alexey-milovidov merged commit e1c2e62 into master Nov 25, 2021
@alexey-milovidov alexey-milovidov deleted the hermetic-builds branch November 25, 2021 02:27
@alexey-milovidov alexey-milovidov self-assigned this Nov 25, 2021
azat added a commit to azat/ClickHouse that referenced this pull request Jan 24, 2022
…bundled libc)

This patch reverts glibc compatibility (via .symver) ClickHouse#29594,
in favor of hermetic build (that provides bundled libc version) ClickHouse#30011

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
@pkit
Copy link
Contributor

pkit commented Nov 24, 2022

@alexey-milovidov
Err, doesn't close #30462 at all.
Still fails to build on glibc 2.35 using current master 6531ff7
See #43633

@Algunenano
Copy link
Member

Still fails to build on glibc 2.35 using current master 6531ff7

Are you sure it's the same problem? The hermetic build works fine for me with an even newer glibc:

$ pacman -Q glibc
glibc 2.36-6

@alexey-milovidov
Copy link
Member Author

We don't access the system's libc during build time. So, the build is hermetic in this regard.
But the built binary still has to access the target machine's libc library at runtime.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr-build Pull request with build/testing/packaging improvement submodule changed At least one submodule changed in this PR.
Projects
None yet
6 participants