mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-02-14 00:40:50 +00:00
Add functions to detect project
Signed-off-by: Thomas Daubney <thomas.daubney@arm.com>
This commit is contained in:
parent
ecb39368df
commit
2f556400c3
@ -30,9 +30,15 @@ EOF
|
|||||||
|
|
||||||
set -eu
|
set -eu
|
||||||
|
|
||||||
# Repository detection
|
# Project detection
|
||||||
in_mbedtls_build_dir () {
|
PROJECT_NAME_FILE='./scripts/project_name.txt'
|
||||||
test -d library
|
if read -r PROJECT_NAME < "$PROJECT_NAME_FILE"; then :; else
|
||||||
|
echo "$PROJECT_NAME_FILE does not exist... Exiting..." >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
in_mbedtls_repo () {
|
||||||
|
test "$PROJECT_NAME" = "Mbed TLS"
|
||||||
}
|
}
|
||||||
|
|
||||||
# Collect stats and build a HTML report.
|
# Collect stats and build a HTML report.
|
||||||
|
@ -115,12 +115,19 @@ set -e -o pipefail -u
|
|||||||
# Enable ksh/bash extended file matching patterns
|
# Enable ksh/bash extended file matching patterns
|
||||||
shopt -s extglob
|
shopt -s extglob
|
||||||
|
|
||||||
|
# For project detection
|
||||||
|
PROJECT_NAME_FILE='./scripts/project_name.txt'
|
||||||
|
if read -r PROJECT_NAME < "$PROJECT_NAME_FILE"; then :; else
|
||||||
|
echo "$PROJECT_NAME_FILE does not exist... Exiting..." >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
in_mbedtls_repo () {
|
in_mbedtls_repo () {
|
||||||
test -d include -a -d library -a -d programs -a -d tests
|
test "$PROJECT_NAME" = "Mbed TLS"
|
||||||
}
|
}
|
||||||
|
|
||||||
in_tf_psa_crypto_repo () {
|
in_tf_psa_crypto_repo () {
|
||||||
test -d include -a -d core -a -d drivers -a -d programs -a -d tests
|
test "$PROJECT_NAME" = "TF-PSA-Crypto"
|
||||||
}
|
}
|
||||||
|
|
||||||
pre_check_environment () {
|
pre_check_environment () {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user