-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
buildsystem: support get handlers (archive, file, git) #2529
Conversation
scripts/get
Outdated
echo "ERROR: get handler \"${get_handler}\" is not supported, unable to get package $1 - aborting!" | ||
exit 1 | ||
else | ||
get_handler="./scripts/get_${get_handler}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
get_handler="${SCRIPTS}/get_${get_handler}"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, updated.
@ToKe79 a couple of extra commits have been added after testing from @HiassofT - these should only affect Also, using This could also be useful for git repositories created by If Default excludes (ie. I don't think these changes should have any affect on your git repositories, but can you test/confirm? |
@MilhouseVH Review: Looking at the changes of |
I confirm that above changes have no conflicts with the git handler. I added some enhancements to For git clones I am not using STAMPS but I am checking URL / commit / branch directly from the cloned folder before downloading ( I also modified the checking of existing folders in Before I reset the head to specific commit I test if such commit exists in the history on the current branch to not reset the head to a commit on different local branch. I also suppressed the output of the |
Added |
Merge me? |
also add support for custom tar opt, eg to exclude files or directories when copying This can be set eg with PKG_TAR_COPY_OPTS="--exclude=.git"
packages can override that by setting PKG_TAR_COPY_OPTS. If this is set to an empty value everything will be copied.
…lean local changes in cloned repo - enhance branch handling - add commit checking on the branch
Is there something preventing a merge? |
This is a feature that came out of #2517.
It adds support for packages file formats that may be of more use to developers (file/directory), and other distributions (git).
The
get_archive
handler implements current tar archive download functionality.The
get_file
handler supports files and directories usingfile://<path>
urls. If the file is a tar archive then it will be unpacked directly into the build directory (if not a tar archive it will be copied, but the build will most likely fail). Directories will be copied directly into the build directory.The
get_git
handler supports git repositories using eithergit://
urls, or urls that end in.git
. Repositories will be cloned into a directory in $SOURCES, and from there copied into the build directory.The distro option
GET_HANDLER_SUPPORT
will determine which handlers are supported. By default LibreELEC will support only the "archive" handler. Add "file" or "git" to to enable additional handlers, using either$HOME/.libreelec/options
for local development, or the relevant distro options file.Thanks to @ToKe79 for
get_git
.