Feature: CLI options for bundle directory and program name#284
Open
andria-dev wants to merge 4 commits intoJonathonReinhart:mainfrom
Open
Feature: CLI options for bundle directory and program name#284andria-dev wants to merge 4 commits intoJonathonReinhart:mainfrom
andria-dev wants to merge 4 commits intoJonathonReinhart:mainfrom
Conversation
…fixed prog name test
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements #282.
--bundle-dirwill determine where the bootloader extracts the archive to.--prog-namewill determine the name of the program within the archive. For example:Checklist
Testing
Testing done in
test/bundle-dir-prog-name.sh.$STATICX_BUNDLE_DIRis the same as--bundle-dir.basename $0is the same as--prog-name.CLI
--bundle-dirwith help message.--prog-namewith help message.Documentation
--bundle-dirand--prog-nameunder thedocs/usage.rst.--bundle-dirand--prog-name.get_symlink,move_bundle, andfile_exists.add_bundle_dir_symlink.Implementation
--prog-name--prog-namewhen specified instead of thebasenameof positional argumentprog.--bundle-dirUnfortunately, I don't have the C skills to have it extract directly to the new bundle directory, so my solution here is to extract to the
/tmp/staticx-XXXXXXand then move it to the new bundle directory, which is obviously not ideal. If anyone has any ideas about how to read the TAR archive to get the symlink before extracting please feel free to jump in.--bundle-dir.Ignore #283. I just had some branch name issues there that caused it to auto close.