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

Append crate to ELF file while deploying program #33849

Merged
merged 2 commits into from
Oct 25, 2023

Conversation

pgarg66
Copy link
Contributor

@pgarg66 pgarg66 commented Oct 24, 2023

Problem

The on-chain program cannot be decompiled into a crate file. So cargo-registry server cannot be used for fetching the crate.

Summary of Changes

This is a temporary solution.

  • Append the crate to ELF file (fixup the toml files and directory name in the package)
  • On cargo fetch, retrieve the program, and return the appended crate from it.

Fixes #

@pgarg66 pgarg66 marked this pull request as ready for review October 24, 2023 23:06
@codecov
Copy link

codecov bot commented Oct 24, 2023

Codecov Report

Merging #33849 (333f878) into master (9ffbe2a) will decrease coverage by 0.1%.
Report is 3 commits behind head on master.
The diff coverage is n/a.

@@            Coverage Diff            @@
##           master   #33849     +/-   ##
=========================================
- Coverage    81.9%    81.8%   -0.1%     
=========================================
  Files         809      809             
  Lines      217717   217717             
=========================================
- Hits       178345   178278     -67     
- Misses      39372    39439     +67     

Lichtso
Lichtso previously approved these changes Oct 25, 2023
@pgarg66 pgarg66 merged commit bdfb644 into solana-labs:master Oct 25, 2023
32 checks passed
@pgarg66 pgarg66 deleted the registry-crate branch October 25, 2023 16:04
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.

3 participants