## Specifies the out-variable that will contain the extracted location.
##
## This should be set to `SOURCE_PATH` by convention.
##
## ### REPO
## The organization or user plus the repository name on the Gitlab instance.
##
## ### REF
## A stable git commit-ish (ideally a tag) that will not change contents. **This should not be a branch.**
##
## For repositories without official releases, this can be set to the full commit id of the current latest master.
##
## If `REF` is specified, `SHA512` must also be specified.
##
## ### SHA512
## The SHA512 hash that should match the archive (${GITLAB_URL}/${REPO}/-/archive/${REF}/${REPO_NAME}-${REF}.tar.gz).
## The REPO_NAME variable is parsed from the value of REPO.
##
## This is most easily determined by first setting it to `1`, then trying to build the port. The error message will contain the full hash, which can be copied back into the portfile.
##
## ### HEAD_REF
## The unstable git commit-ish (ideally a branch) to pull for `--head` builds.
##
## For most projects, this should be `master`. The chosen branch should be one that is expected to be always buildable on all supported platforms.
##
## ## Notes:
## At least one of `REF` and `HEAD_REF` must be specified, however it is preferable for both to be present.
##
## This exports the `VCPKG_HEAD_VERSION` variable during head builds.
message(FATAL_ERROR"At least one of REF and HEAD_REF must be specified.")
endif()
string(REGEXREPLACE".*/"""REPO_NAME${_vdud_REPO})
string(REGEXREPLACE"/.*"""ORG_NAME${_vdud_REPO})
macro(set_TEMP_SOURCE_PATHBASE)
file(GLOB_ARCHIVE_FILES"${BASE}/${REPO_NAME}*")
foreach(dir${_ARCHIVE_FILES})
if(IS_DIRECTORY${dir})
list(APPEND_ARCHIVE_DIRS"${dir}")
endif()
endforeach()
list(LENGTH_ARCHIVE_DIRS_NUM_ARCHIVE_DIRS)
if(NOT1EQUAL${_NUM_ARCHIVE_DIRS})
message(FATAL_ERROR"Could not determine source path: There were ${_NUM_ARCHIVE_DIRS} directories extracted from the archive that start with the repo name.")